From: Dormilich at netscape dot net Operating system: Linux PHP version: 5.2.11 PHP Bug Type: Session related Bug description: session id not appended properly for empty anchor tags
Description: ------------ I created a Suckerfish Dropdown Menu via XSLT, which contains empty anchor elements (<a href=" "/>). If Cookies are disabled the Session ID should be appended at the end of the href attribute value (URL) but it is appended after the closing slash of the element, rendering the XHTML invalid. However, "normal" hyperlinks (<a href=" ">link text</a>) are not affected. Configure Command: './configure' '--prefix=/usr/local/php5' '--with-config-file- path=/etc/php5' '--with-openssl' '--with-xsl' '--with-xmlrpc' '-- enable-mbstring' '--enable-mbregex' '--enable-wddx' '--with- gettext=/usr' '--with-mysql=/usr/local/mysql' '--with- mysqli=/usr/local/mysql/bin/mysql_config' '--with-mcrypt=/usr/lib64/' '--with-apache=../apache_current/' '--with-freetype-dir=/usr/local' '- -with-t1lib=/usr/local' '--with-gd' '--enable-gd-native-ttf' '--with- jpeg-dir=/usr/local' '--enable-exif' '--with-png-dir=/usr/local/lib' '--with-zlib' '--with-curl' '--enable-bcmath' '--enable-calendar' '-- enable-discard-path' '--enable-shared' '--enable-force-cgi-redirect' '--with-pdo-mysql=/usr/local/mysql' '--enable-soap' Reproduce code: --------------- <a href="site.php?id=this"/> Expected result: ---------------- <a href="site.php?id=this&PHPSESSID=3d d4"/> Actual result: -------------- <a href="site.php?id=this"/&PHPSESSID=3d d4> -- Edit bug report at http://bugs.php.net/?id=50308&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=50308&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=50308&r=trysnapshot53 Try a snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=50308&r=trysnapshot60 Fixed in SVN: http://bugs.php.net/fix.php?id=50308&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=50308&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=50308&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=50308&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=50308&r=needscript Try newer version: http://bugs.php.net/fix.php?id=50308&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=50308&r=support Expected behavior: http://bugs.php.net/fix.php?id=50308&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=50308&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=50308&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=50308&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=50308&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=50308&r=dst IIS Stability: http://bugs.php.net/fix.php?id=50308&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=50308&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=50308&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=50308&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=50308&r=mysqlcfg