content disposition rfc
[squirrelmail.git] / functions / html.php
index 747d68ede2c347859388d01c56cbd45242efb329..f575572480eb5fac7d25313a43e31a799d01ca2a 100644 (file)
@@ -3,7 +3,7 @@
 /**
  * html.php
  *
- * Copyright (c) 1999-2004 The SquirrelMail Project Team
+ * Copyright (c) 1999-2005 The SquirrelMail Project Team
  * Licensed under the GNU GPL. For full terms see the file COPYING.
  *
  * The idea is to inlcude here some functions to make easier
@@ -81,9 +81,9 @@ function html_tag( $tag,                // Tag to output
         }
 
         if ( $val <> '' ) {
-            $ret .= ">$val</$tag>";
+            $ret .= ">$val</$tag>\n";
         } else {
-            $ret .= '>';
+            $ret .= '>'. "\n";
         }
 
         return( $ret );
@@ -137,6 +137,9 @@ function html_tag( $tag,                // Tag to output
             } else {
                 $rpl = '';
             }
+            if( substr($v,-1)=='&' ) {
+                $rpl .= '&';
+            }
             $pat = "/$k=$v/";
             $url = preg_replace($pat,$rpl,$url);
         }