Forum Moderators: coopster

Message Too Old, No Replies

PHP session use_trans_id

why cant I disable?

         

MelWe

1:34 pm on Apr 22, 2003 (gmt 0)

10+ Year Member



I try to disable PHP's session use_trans_sid. The phpinfo() shows it is set "on". PHP version is 4.3.0

ini_set('session.use_trans_sid', 0); nor
ini_set('session.use_trans_sid', false); does work.

My pages end up with double PHPSESSID=... what can I do?

DrDoc

7:31 pm on Apr 22, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You can disable it in your .htaccess file...

<IfModule mod_php4.c>
php_value session.use_trans_sid 0
</IfModule>

grahamstewart

10:33 pm on Apr 22, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Look at the manual page for ini_set.
Here it tells you that session.use_trans_sid can only be set in PHP_INI_SYSTEM¦PHP_INI_PERDIR.

A little further down it explains what these mean:

PHP_INI_USER....Entry can be set in user scripts  
PHP_INI_PERDIR..Entry can be set in .htaccess and VHost directives in httpd.conf.
PHP_INI_SYSTEM..Entry can be set in php.ini or httpd.conf (but not in VHost blocks in httpd.conf).
PHP_INI_ALL.....Entry can be set anywhere

So this value cannot be changed by the ini_set() function.
But you can specify it in .htaccess (as shown above) in php.ini or in httpd.conf

[edited by: jatar_k at 2:22 pm (utc) on April 24, 2003]
[edit reason] sidescroll [/edit]

MelWe

2:13 pm on Apr 24, 2003 (gmt 0)

10+ Year Member



I disabled it in the .htaccess file and that works fine.

Many thanks!

Giacomo

10:00 pm on May 28, 2003 (gmt 0)

10+ Year Member Top Contributors Of The Month



<bump>

grahamstewart, including

ini_set("session.use_trans_sid", 0);
in my PHP scripts before any calls to
session_start()
seems to work for me (tested with PHP 4.1.1, 4.2.3 and 4.3.1).