One thing that is bugging me about not getting the rewrite rules
working is that the instructions for the LocalSettings.php file don't
seem to match what mine looks like (in Beta 5). Do I need to change
them? Below is what they look like now.
Thanks,
kerim
$wgSitename = "KerimWiki";
$wgScriptPath = "";
$wgScript = "$wgScriptPath/index.php";
$wgRedirectScript = "$wgScriptPath/redirect.php";
## If using PHP as a CGI module, use the ugly URLs
$wgArticlePath = "$wgScript/$1";
# $wgArticlePath = "$wgScript?title=$1";
$wgStylePath = "$wgScriptPath/stylesheets";
$wgStyleDirectory = "$IP/stylesheets";
$wgLogo = "$wgStylePath/images/wiki.png";
$wgUploadPath = "$wgScriptPath/images";
$wgUploadDirectory = "$IP/images";
On Jul 27, 2004, at 4:15 PM, Alisson Sellaro wrote:
P. Kerim friedman wrote:
I really hope I can get this working, as it is the only thing holding
up making my site go live! Thanks again to anyone who can clear up
the confusion!
That setup was used when MusicWiki was in a different server (under
/wiki directory). My actuall configuration follows (Wiki at
http://www.music-wiki.org for .htaccess or httpd.conf):
RewriteEngine on
RewriteCond %{QUERY_STRING} ^$
RewriteCond %{REQUEST_URI} ^/$
RewriteRule ^(.*) /index.php?tile=Main_Page [L]
# Don't rewrite requests for files in MediaWiki subdirectories,
# MediaWiki PHP files, HTTP error documents, favicon.ico, or robots.txt
RewriteCond %{REQUEST_URI} !^/stylesheets/
RewriteCond %{REQUEST_URI} !^/(redirect|texvc|index).php
RewriteCond %{REQUEST_URI} !^/error/(40(1|3|4)|500).html
RewriteCond %{REQUEST_URI} !^/favicon.ico
RewriteCond %{REQUEST_URI} !^/robots.txt
# Make sure there is no query string (Unless user is making a search)
RewriteCond %{QUERY_STRING} ^$ [OR]
RewriteCond %{REQUEST_URI} ^/Special:Search
# Rewrite
http://wiki.domain.tld/article properly, this is the main
rule
RewriteRule ^/(.*) /index.php/$1 [L]
I think the following configuration will fit your needs (changing
http://something.org to
http://some.org and doing URL
"beautification"):
RewriteEngine on
# Change
http://something.org to
http://some.org
RewriteCond %{REQIEST_URI} ^something.org
RewriteRule ^(.*) some.org$1
# Main_Page not specified
RewriteCond %{QUERY_STRING} ^$
RewriteCond %{REQUEST_URI} ^/$
RewriteRule ^(.*) /index.php?tile=Main_Page [L]
# Don't rewrite requests for files in MediaWiki subdirectories,
# MediaWiki PHP files, HTTP error documents, favicon.ico, or robots.txt
RewriteCond %{REQUEST_URI} !^/stylesheets/
RewriteCond %{REQUEST_URI} !^/(redirect|texvc|index).php
RewriteCond %{REQUEST_URI} !^/error/(40(1|3|4)|500).html
RewriteCond %{REQUEST_URI} !^/favicon.ico
RewriteCond %{REQUEST_URI} !^/robots.txt
# Make sure there is no query string (Unless user is making a search)
RewriteCond %{QUERY_STRING} ^$ [OR]
RewriteCond %{REQUEST_URI} ^/Special:Search
# Rewrite
http://wiki.domain.tld/article properly, this is the main
rule
RewriteRule ^/(.*) /index.php/$1 [L]
Hope it helps.
--
Alisson Sellaro
MusicWiki ::
http://www.music-wiki.org
Plug It In! ::
http://www.plugitin.com.br
AIM : sellaropelucio
ICQ : 150658836
Jabber: sellaro(a)jabber.linux.it
MSN : alissonsellaro(a)hotmail.com
_______________________________________________
MediaWiki-l mailing list
MediaWiki-l(a)Wikimedia.org
http://mail.wikipedia.org/mailman/listinfo/mediawiki-l