SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Member
    Join Date
    May 2012
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Want to remove pmsession from inner page URLs when home page is first loaded

    Hello,

    I have a one question for php.

    One of my client websites is made in php along CMS. Whenever the site (home page) is first loaded, it shows pmsession in the inner page URLs. After that it is disappeared.

    Example of inner page URL:
    http://www.xyz.com/keyword-keyword?p...88160dd405d692

    I want to disappear it (i.e. http://www.xya.com/keyword-keyword) when the site (i.e. http://www.xya.com) is first loaded. I have found the below mentioned solutions for this problem.

    1. In your config.php file, put the following code:

    <?php

    ini_set('session.use_trans_sid', 0);

    ini_set(‘session.use_only_cookies’, 1);

    ?>

    2. In your .htaccess file, use the code below:

    php_flag session.use_trans_sid off

    php_flag session.use_only_cookies on

    Is it appropriate to use one of them?

    If you have other suggestion, please suggest here.

  2. #2
    Keeper of the SFL StarLion's Avatar
    Join Date
    Feb 2006
    Location
    Atlanta, GA, USA
    Posts
    3,748
    Mentioned
    71 Post(s)
    Tagged
    0 Thread(s)
    Welcome to SitePoint Forums

    Well you could adjust php.ini directly if you have access to it, which would fix it as well (perminantly for all pages on that server. Call this Method 3).

    But yes, basically what these two (now 3) methods are doing is the same thing, but on different levels: 1: The individual site (Runtime setting), 2: the whole server (Runtime setting), and 3: the whole server (Configuration setting).
    Very few sites actually use trans_SID's anymore, as cookies have become accepted and not just treated as spam objects.
    Never grow up. The instant you do, you lose all ability to imagine great things, for fear of reality crashing in.

  3. #3
    SitePoint Member
    Join Date
    May 2012
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by StarLion View Post
    Well you could adjust php.ini directly if you have access to it, which would fix it as well (perminantly for all pages on that server. Call this Method 3).
    Would I need to add or modify something in php.ini to solve this issue ?

  4. #4
    Keeper of the SFL StarLion's Avatar
    Join Date
    Feb 2006
    Location
    Atlanta, GA, USA
    Posts
    3,748
    Mentioned
    71 Post(s)
    Tagged
    0 Thread(s)
    the settings should be in there - look for session.use_trans_sid and session.use_only_cookies
    Never grow up. The instant you do, you lose all ability to imagine great things, for fear of reality crashing in.

  5. #5
    SitePoint Member
    Join Date
    May 2012
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Starlion,

    Thanks for your support. let me check in it.


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
  •