Remove HTML from provider_uri and name; also fix default provider_uri when on plugin...
authorpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Mon, 15 Jan 2007 08:27:10 +0000 (08:27 +0000)
committerpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Mon, 15 Jan 2007 08:27:10 +0000 (08:27 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@12135 7612ce4b-ef26-0410-bec9-ea0150e637f0

ChangeLog
functions/page_header.php
templates/default/page_header.tpl

index b779179..b286b0a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -177,6 +177,7 @@ Version 1.5.2 - SVN
     configuring plugin. Thanks to Peter Steiner.
   - Fixed HttpOnly cookies again.
   - Update for switch from CVS to Subversion.
+  - Default provider URI link fixed (was broken when on plugin options pages, etc)
 
 Version 1.5.1 (branched on 2006-02-12)
 --------------------------------------
index b21d13d..1f8b6cc 100644 (file)
@@ -240,14 +240,12 @@ function displayPageHeader($color, $mailbox, $sHeaderJs='', $sBodyTagJs = '') {
 
     $sm_attributes = '';
     if (!$hide_sm_attributions) {
-        $sm_attributes .= '<td class="sqm_providerInfo">' ."\n";
         if (empty($provider_uri)) {
-            $sm_attributes .= '   <a href="about.php">SquirrelMail</a>';
+            $sm_attributes .= create_hyperlink($base_uri . 'src/about.php', 'SquirrelMail');
         } else {
-            if (empty($provider_name)) $provider_name= 'SquirrelMail';
-            $sm_attributes .= '   <a href="'.$provider_uri.'" target="_blank">'.$provider_name.'</a>'."\n";
+            if (empty($provider_name)) $provider_name = 'SquirrelMail';
+            $sm_attributes .= create_hyperlink($provider_uri, $provider_name, '_blank');
         }
-        $sm_attributes .= "  </td>\n";
     }
 
     $oTemplate->assign('body_tag_js', $sBodyTagJs);
index 4b76877..88c6aeb 100644 (file)
@@ -83,7 +83,10 @@ $help_link           = makeInternalLink ('src/help.php', $help_str);
    <?php echo $help_link; ?>&nbsp;&nbsp;
    <?php /* FIXME: no hooks in templates!! */ global $null; do_hook('menuline', $null); ?>
   </td>
-  <?php echo $sm_attribute_str."\n"; ?>
+  <?php if (!empty($sm_attribute_str))
+            echo '<td class="sqm_providerInfo">'
+               . $sm_attribute_str
+               . "</td>\n"; ?>
  </tr>
 </table>
 </div>