[wp-hackers] Fix for SSL
Matt Kennedy
matt at bootsnall.com
Thu Apr 28 04:02:08 GMT 2005
Hi, I'm a newbie to this list, but since patches seem to be on people's
brain's here are these two modifications I made to get ssl working
properly:
in wp-admin/install.php
#$guessurl = str_replace('/wp-admin/install.php?step=2', '', 'http://'
. $_SERVER['HTTP_HOST'] .dirname($_SERVER['PHP_SELF']) );
$scheme = "http";
if ($_SERVER['HTTPS'] == "on")
{
$scheme = $scheme."s";
}
$guessurl = str_replace('/wp-admin/install.php?step=2', '',
$scheme.'://'.$_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) );
and in wp-admin/upgrade-schema.php
#$guessurl = preg_replace('|/wp-admin/.*|i', '', 'http://' .
$_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']);
$scheme = "http";
if ($_SERVER['HTTPS'] == "on")
{
$scheme = $scheme."s";
}
$guessurl = preg_replace('|/wp-admin/.*|i', '',
$scheme.'://'.$_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']);
Hope these are useful.
PS. List moderator, my apologies, I'm such a newbie I initially posted
this message with an address that was not subscribed to the list.
More information about the wp-hackers
mailing list