[wp-trac] [WordPress Trac] #10458: lighttpd/1.4.22 does not populate _REQUEST['action'] for wp-login.php
WordPress Trac
wp-trac at lists.automattic.com
Tue Jul 21 14:10:36 UTC 2009
#10458: lighttpd/1.4.22 does not populate _REQUEST['action'] for wp-login.php
--------------------------+-------------------------------------------------
Reporter: myrond | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Unassigned
Component: General | Version: 2.8
Severity: normal | Keywords:
--------------------------+-------------------------------------------------
lighttpd/1.4.22 does not populate _REQUEST['action'] for wp-login.php,
this in turn disabled any action in the switch statement breaking the
ability to logout.
Symtoms of this bug are: clicking logout in wordpress 2.8 and going to the
login page but not really logging out. Clicking logout in wordpress 2.3
and being redirected right back to the /wp-admin page.
adding this code to wp-login.php, fixes the behavior and re-enables all
features in wp-login.php.
I don't know the wordpress code but if there is a section which deals with
idiosyncrasies of web servers that lighttpd be detected and this code be
run to deal with it.
//
// Main
//
if (strpos($_SERVER['SERVER_SOFTWARE'], 'lighttpd') !== false)
{
$_lighty_url = $base_url.$_SERVER['REQUEST_URI'];
$_lighty_url = @parse_url($_lighty_url);
$_SERVER['QUERY_STRING'] = $_lighty_url['query'];
parse_str($_lighty_url['query'], $_lighty_query);
foreach ($_lighty_query as $key => $val)
$_GET[$key] = $_REQUEST[$key] = $val;
}
--
Ticket URL: <http://core.trac.wordpress.org/ticket/10458>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list