SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Evangelist
    Join Date
    Nov 2003
    Location
    England
    Posts
    540
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    PHPSESSID on my urls all of a sudden..

    Hey all,

    All of a sudden, out of the blue i've got ?PHPSESSID=blarp on all of the links on my sites, i've always used sessions but its never done it like that before.

    I thought php added that to the querystring if it cannot use cookies to store the id? i've not changed any settings and i've tried it on multiple computers around the office.

    Or could it be that my hosts have changed a setting? or upgraded php and newer ones put the session id in the url by default?

    Does anybody know how to get rid of it, without breaking sessions?

    Thanks,
    Matt.

  2. #2
    SitePoint Enthusiast Zeldinha's Avatar
    Join Date
    Sep 2004
    Location
    Barcelona [Spain]
    Posts
    89
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hm, check the value of the php.ini setting session.use_trans_sid. Should be 0 so the session id won't be passed on URLs.

    I guess you can modify it with ini_set() function or maybe some other way.

    Hope it helps.

    Z.

  3. #3
    SitePoint Zealot kamm's Avatar
    Join Date
    Nov 2003
    Location
    Espaņa
    Posts
    162
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    As Zeldinha said - probably the value of session.use_trans_sid has been changed to On - check with phpinfo().

    You can also turn it off with the following line of code below in an .htaccess file (without breaking your sessions)...

    Code:
    php_flag session.use_trans_sid off


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •