[Pmwiki-users] installing pmwiki2 - scripturl

Knut Alboldt mailing
Sat Sep 18 04:36:48 CDT 2004

Ok, found a solution by myself:

I'm simply setting


before including pmwiki.php.

I'm not calling pmwiki.php directly, cause I'm using wiki farms.


At 00:13 18.09.2004, you wrote:
>I started to install pmwiki 2.0.devel5 with:
>- win2000
>- apache 1.3.27
>- php 4.3.5 as CGI invoked by
>   Action application/x-httpd-php  "/phpbin/php.exe"
>   where /phpbin/ is defined with ScriptAlias to the local directory
>without modifications (just unzipping and calling pmwiki.php), the vars 
>set in pmwiki.php
>   $ScriptUrl = 'http://'.$_SERVER['HTTP_HOST'].$_SERVER['SCRIPT_NAME'];
>   $PubDirUrl = preg_replace('#/[^/]*$#','/pub',$ScriptUrl,1);
>are set to a wrong value in my environment, cause $_SERVER['SCRIPT_name'] 
>is the name of the php-executable (/phpbin/php.exe) and not the name of 
>the php-script (/wiki2/pmwiki.php).
>To fix this I'm setting
>   $ScriptUrl = $_SERVER['PATH_INFO'];
>in local/config.php.
>But then I've to set
>    $PubDirUrl = preg_replace('#/[^/]*$#','/pub',$ScriptUrl,1);
>in local/config.php as well.
>Isn't there a better way to fix this ? e.g. setting $ScriptUrl before 
>calling pmwiki.php (but than pmwiki.php has to use SDV to set $ScriptUrl)
>Pmwiki-users mailing list
>Pmwiki-users at pmichaud.com

More information about the pmwiki-users mailing list