]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Extended profile - linkify related URLs added by the user
authorZach Copley <zach@status.net>
Wed, 16 Mar 2011 08:23:47 +0000 (01:23 -0700)
committerZach Copley <zach@status.net>
Wed, 16 Mar 2011 08:23:47 +0000 (01:23 -0700)
plugins/ExtendedProfile/extendedprofilewidget.php

index 622beff32f1bddf9992bffdbf74b10240ce5a690..d4a3f21a525bbbdf781382ea35b3ba38a392209d 100644 (file)
@@ -79,7 +79,7 @@ class ExtendedProfileWidget extends Form
     {
         // For JQuery UI modal dialog
         $this->out->elementStart(
-            'div', 
+            'div',
             array('id' => 'confirm-dialog', 'title' => 'Confirmation Required')
         );
         $this->out->text('Really delete this entry?');
@@ -180,7 +180,19 @@ class ExtendedProfileWidget extends Form
     protected function showWebsite($name, $field)
     {
         $this->out->elementStart('div', array('class' => 'website-display'));
-        $this->out->text($field['value']);
+
+        $url = $field['value'];
+
+        $this->out->element(
+            "a",
+            array(
+                'href'   => $url,
+                'class'  => 'extended-profile-link',
+                'target' => "_blank"
+            ),
+            $url
+        );
+
         if (!empty($field['rel'])) {
             $this->out->text(' (' . $field['rel'] . ')');
         }