View previous topic :: View next topic |
Author |
Message |
easytec -
Joined: 17 Aug 2007 Posts: 55
|
Posted: Tue Sep 18, 2007 3:26 pm Post subject: I was thinking of making my MediaWiki URL work like... |
|
|
Wikipedia's, how can I do this AND make it work normal for the other applications.
I DO NOT KNOW THE FIRST THING ABOUT URL REWRITING, I JUST DISCOVERED IT TODAY.
I want this for my 'MediaWiki' URL:
(I have no domain name by the way).
http://127.0.0.1/wiki/index.php?title=Main_Page
... to look like this:
http://127.0.0.1/wiki/Main_Page
Please help! |
|
Back to top |
|
|
aprelium -
Joined: 22 Mar 2002 Posts: 6800
|
Posted: Wed Sep 19, 2007 12:56 am Post subject: Re: I was thinking of making my MediaWiki URL work like... |
|
|
easytec,
Create a URL rewriting rule as follows:
Virtual path regular expression: ^/wiki/(.*)$
If rule matches: Perform an internal redirection
Redirect to: /wiki/$1 _________________ Support Team
Aprelium - http://www.aprelium.com |
|
Back to top |
|
|
easytec -
Joined: 17 Aug 2007 Posts: 55
|
Posted: Wed Sep 19, 2007 6:44 pm Post subject: |
|
|
Didn't work, still error page, does MediaWiki need this setup? |
|
Back to top |
|
|
aprelium -
Joined: 22 Mar 2002 Posts: 6800
|
Posted: Thu Sep 20, 2007 12:48 pm Post subject: Re: I was thinking of making my MediaWiki URL work like... |
|
|
easytec,
Sorry there were missing conditions. The whole URL rewriting rule should be:
Virtual path regular expression: ^/wiki/(.*)$
Condition 1: REQUEST_FILENAME Is Not File
Condition 2: REQUEST_FILENAME Is Not Directory
If rule matches: Perform an internal redirection
Redirect to: /wiki/index.php?title=$1 _________________ Support Team
Aprelium - http://www.aprelium.com |
|
Back to top |
|
|
easytec -
Joined: 17 Aug 2007 Posts: 55
|
Posted: Fri Sep 21, 2007 1:47 pm Post subject: |
|
|
That didn't work so I tried:
^/wiki/(.*)?title=$
... to redirect fromL
/wiki/$
But the URL looks like: /wiki/?Main_Page but won't work as /wiki/Main_Page, which I want. |
|
Back to top |
|
|
Moxxnixx -
Joined: 21 Jun 2003 Posts: 1226 Location: Florida
|
Posted: Fri Sep 21, 2007 7:23 pm Post subject: |
|
|
easytec,
Use Aprelium's settings in his last post, except change the redirect to: to...
/wiki/index.php?title=$1 |
|
Back to top |
|
|
admin Site Admin
Joined: 03 Mar 2002 Posts: 1300
|
Posted: Fri Sep 21, 2007 11:48 pm Post subject: |
|
|
Moxxnixx wrote: | /wiki/index.php?title=$1 |
Thanks for fixing that. It was a second mistake. Sorry easytec. Hopefully the fixed rule will work fine now. _________________ Follow @abyssws on Twitter
Subscribe to our newsletter
_________________
Forum Administrator
Aprelium - https://aprelium.com |
|
Back to top |
|
|
|