Forum Moderators: coopster
example : http://example.com/index.php?PHPSESSID=65e9cc7bf996...
To avoid this we have the following ways
1. If the web server uses apache handler, and the php config settings are manageable thru' .htaccess file:
simply add the following lines to your .htaccess file
php_value session.use_only_cookies 1
php_value session.use_trans_sid 0
2. Alternatively, if your web server uses CGI handler, and the php config settings are overridden only by local php.ini files, then create a local copy of php.ini file in the required directory and add modify the following directives as:
session.use_only_cookies = 1
session.use_trans_sid = 0
3. If permitted, you can also modify the php.ini settings from within the page using the following code snippet
ini_set('session.use_trans_sid', false);
ini_set('session.use_only_cookies', true);
Regards
Miltan
RewriteCond %{QUERY_STRING} [b]&?[/b]sessionid=([^&]+)[b]&?[/b] [NC]
RewriteRule (.*) http://www.example.com/$1? [R=301,L]