---LocalSettings.php snippet--- $wgScriptPath = ""; $wgScript = "$wgScriptPath/index.php"; $wgRedirectScript = "$wgScriptPath/redirect.php"; ---End snippet---
[snip]
RewriteRule ^(.*)$ cmw/$1 [L] ---End snippet---
Won't this cause all the /index.php.* to be rewritten to /cmw/index.php.* internally?
Brion Vibber and other MediaWiki gurus--
I don't think it works quite that way, but it's possible. The subdomain cmw.buzdor.org has a root which is mapped (by this .htaccess) to the physical server path cmw/ relative to the root of the service package. It's my understanding that this rule maps the url http://cmw.buzdor.org/index.php?title=Main_page to the *filesystem* path /cmw/index.php and passes the same query string. I thought the abstraction from the URL layer to the filesystem layer was transparent to the PHP software, since no one (and I mean no one) runs their website from their TRUE root / on their *nix server. I did not know that this would be an issue for the wiki software, since it can (and should) make all URLs (and client redirect headers) relative to the root of cmw.buzdor.org, and it should never issue a URL containing the path /cmw/. It was my supposition (having installed SquirrelMail, PhpBB, and other PHP programs the same way) that the software would take me at my word when I said it was at the root for URL purposes. Perhaps there's an obscure, oversensitive server variable that no other program uses to determine request URL that MediaWiki is dependent upon, and I could switch that to the traditional one in my copy of the code.
This could produce a mismatch between the defined $wgScript and the path the wiki sees itself at internally when checking that raw pages are being loaded from the canonical URL.
Would you recommend I write a temporary index.php dumping server variables to the user, so we can diagnose whether some variable the server is passing to the Wiki is confusing it? What server or request variable is suspect?
This is a fascinating problem through which I'll probably learn quite a bit about Apache, and even more about MediaWiki. Thanks for your time!
--N. Buzdor
On Jan 12, 2005, at 8:28 AM, N. M. Buzdor wrote:
RewriteRule ^(.*)$ cmw/$1 [L] ---End snippet---
Won't this cause all the /index.php.* to be rewritten to /cmw/index.php.* internally?
I don't think it works quite that way, but it's possible. The subdomain cmw.buzdor.org has a root which is mapped (by this .htaccess) to the physical server path cmw/ relative to the root of the service package. It's my understanding that this rule maps the url http://cmw.buzdor.org/index.php?title=Main_page to the *filesystem* path /cmw/index.php and passes the same query string.
No, that's an URL rewrite which passes the new URL (eg /cmw/index.php) internally to the final request.
If you want to map the physical path directly, normally you'd use a DocumentRoot directive in the virtual host configuration.
Perhaps there's an obscure, oversensitive server variable that no other program uses to determine request URL that MediaWiki is dependent upon, and I could switch that to the traditional one in my copy of the code.
Yes, the wiki is making sure that you're not exploiting an Internet Explorer security hole as explained in another thread.
-- brion vibber (brion @ pobox.com)
mediawiki-l@lists.wikimedia.org