[Pmwiki-users] problem with url construction when using non-standard port
Jonathan Scott Duff
duff at pobox.com
Thu Jun 5 10:38:08 CDT 2003
On Thu, Jun 05, 2003 at 11:07:19AM -0400, Bob Dively wrote:
> I've got pmwiki 0.4.26 running on a Win2K server with Apache
> 2.0.45 and PHP 4.3.1. Apache is listening on port 81. When I
> go to http://example.com:81/pmwiki/pmwiki.php all of the
> links on that page have the port doubled, e.g.,
> http://example.com:81:81/pmwiki/pmwiki.php?action=search&text=HomePage. I
> corrected this behavior by commenting out lines 33 & 34 in
> pmwiki.php, which are:
>
> if ($HTTP_SERVER_VARS['SERVER_PORT'] != "80")
> $ScriptUrl .= ':'.$HTTP_SERVER_VARS['SERVER_PORT'];
>
> I haven't tried to replicate this behavior on a different OS
> so I can't tell if it's Windows-specific.
If anything it's probably an Apache bug. 2.0.45 *still* doesn't set
many of its environment variables correctly, so perhaps one of them is
HTTP_HOST (which is where $ScriptUrl comes from).
Though I'm sure Pm can make it work even on broken Apaches ;-)
-Scott
--
Jonathan Scott Duff
duff at cbi.tamucc.edu
More information about the pmwiki-users
mailing list