Changeset 2006

Show
Ignore:
Timestamp:
05/11/07 22:07:47 (6 years ago)
Author:
rub
Message:

Issue 0000619: bad result of cookie_path() function

After discussion with Radu of an other case, PATH_INFO is re-introduce with news conditions.

Location:
trunk
Files:
4 modified

Legend:

Unmodified
Added
Removed
  • trunk

    • Property svn:ignore
      •  

        old new  
        33feed.xml 
        44testmail 
         5phpmv2 
  • trunk/include/functions_cookie.inc.php

    r2004 r2006  
    4040    // mod_rewrite is activated for upper level directories. we must set the 
    4141    // cookie to the path shown in the browser otherwise it will be discarded. 
    42     $scr = $_SERVER['REDIRECT_URL']; 
     42    if  
     43      (  
     44        isset($_SERVER['PATH_INFO']) and !empty($_SERVER['PATH_INFO']) and 
     45        ($_SERVER['REDIRECT_URL'] !== $_SERVER['PATH_INFO']) and 
     46        (substr($_SERVER['REDIRECT_URL'],-strlen($_SERVER['PATH_INFO'])) 
     47            == $_SERVER['PATH_INFO']) 
     48      ) 
     49    { 
     50      $scr = substr($_SERVER['REDIRECT_URL'], 0,  
     51        strlen($_SERVER['REDIRECT_URL'])-strlen($_SERVER['PATH_INFO'])); 
     52    } 
     53    else 
     54    { 
     55      $scr = $_SERVER['REDIRECT_URL']; 
     56    } 
    4357  } 
    4458  else 
  • trunk/plugins

    • Property svn:ignore
      •  

        old new  
        11text_integrator 
         2phpmv 
  • trunk/template/yoga/theme

    • Property svn:ignore
      •  

        old new  
        1111hk-darkblue-left 
        1212minimalus 
         13exftb