I think the following code: (bin/wiki.pm, line 166, Dec2001 release)
# initialize $urlHost and $scriptUrlPath
if( ( $theUrl ) && ( $theUrl =~ /^([^\:]*\:\/\/[^\/]*)(.*)\/.*$/ ) && ( $2 ) ) {
$urlHost = $1;
$scriptUrlPath = $2;
is false. The red line setting the $scriptUrlPath can be fooled in many occasions where the web server redirects from another URL, and I dont see a case where it could be useful.
I guess this code may at some time allowed TWiki web sites to be copied elsewhere and still work without touching the wikicfg.pm, but it seems really not worth the trouble to me.
Better edit the wikicfg.pm rather than risking annoying bugs.
So I propose we just
remove the line:
$scriptUrlPath = $2;
related topics:
RefreshEditPage,
SCRIPTURLNotSetCorrectly
--
ColasNahaboo - 20 Apr 2001
The reason for getting the URL path from the environment is for installations where the URL is different, depending on the invocation. I.e. direct access or via proxy server.
The latest version has now a
$doGetScriptUrlFromCgi flag in TWiki.cfg where youcan control one or the other behaviour.
--
PeterThoeny - 25 Aug 2001