From: Tara S. <te...@cl...> - 2001-11-15 22:06:47
|
I've successfully set up http://spirolattic.net/wiki/ to point to my=20 wiki (but as you've understood from my previous posts, I'm not satisfied=20 with that). Sorry if I'm repeating myself, btw (I hope I'm not rambling too much, I=20 got a bit of a concussion this morning). I would like http://spirolattic.net/ to point to the wiki, and=20 http://spirolattic.net/RecentChanges to point to RecentChanges... you=20 get the idea. So, armed with mod_rewrite and a lot of courage, I produced this: RewriteRule ^([^wiki]+)$ wiki/$1 which of course fails miserably. http://spirolattic.net/ takes us nowhere, and=20 http://spirolattic.net/RecentChanges drops us on the HomePage. Is anybody out there inspired? Thanks if you can help :) Tara PS- tell me if I'm straying too far away from WikiThings --=20 Je r=E9ponds au mieux de mes connaissances Climb to the Stars! - http://climbtothestars.org/ SpiroLattic - http://climbtothestars.org/spiro/ Pompeurs Associ=E9s - http://pompage.net/ |
From: Adam S. <ad...@pe...> - 2001-11-15 23:09:21
|
> I would like http://spirolattic.net/ to point to the wiki, and > http://spirolattic.net/RecentChanges to point to RecentChanges... you > get the idea. rather then mod_rewrite it why not just move all the wiki source files up one directory so they actually live at http://spirolattic.net/ ? > So, armed with mod_rewrite and a lot of courage, I produced this: if you want the rewritten rule to show up in the users browser you need to have mod_proxy enabled as well and have these options at the end of rule [P,L] for example here's a mod_rewrite rule i used to do to make a friends web site which he wanted to show up on my site to where it was actually hosted on uswest: RewriteRule ^/(.*) http://www.users.uswest.net/~nift/$1 [P,L] > RewriteRule ^([^wiki]+)$ wiki/$1 i think you want something more like this (assuming that there are not other non-wiki pages on spirolattic.net ... if there are then you're gonna have to figure out a way to tell what's a wiki page adn what isn't): RewriteRule ^/(.*) http://spirolattic.net/wiki/$1 [P,L] > which of course fails miserably. if i remember my regex's correctly what you're doing is creating a character class with the []'s so rather then matching "wiki" plus stuff you're matching one or more w's, i's or k's. adam. |
From: Tara S. <te...@cl...> - 2001-11-16 09:46:43
|
Adam Shand wrote: >>I would like http://spirolattic.net/ to point to the wiki, and >>http://spirolattic.net/RecentChanges to point to RecentChanges... you >>get the idea. >> >=20 > rather then mod_rewrite it why not just move all the wiki source files = up > one directory so they actually live at http://spirolattic.net/ ? For complicated Tara-reasons, it's not possible (the wiki is accessible=20 through two domain names, so the mapping is a little delicate). > if you want the rewritten rule to show up in the users browser you need= to > have mod_proxy enabled as well and have these options at the end of rul= e > [P,L] for example here's a mod_rewrite rule i used to do to make a frie= nds > web site which he wanted to show up on my site to where it was actually > hosted on uswest: >=20 > RewriteRule ^/(.*) http://www.users.uswest.net/~nift/$1 [P,L] Tried this: RewriteRule ^/(.*) http://climbtothestars.org/outside_wiki/$1 [P,L] doesn't seem to work for me. Actually, I don't want the re-written rule to show up in the browser. I=20 want http://spirolattic.net/RecentChanges to stay in the browser, even=20 if the "real" place of the thing is=20 http://spirolattic.net/wiki/RecentChanges. >>RewriteRule ^([^wiki]+)$ wiki/$1 >> >=20 > i think you want something more like this (assuming that there are not > other non-wiki pages on spirolattic.net ... if there are then you're go= nna > have to figure out a way to tell what's a wiki page adn what isn't): >=20 > RewriteRule ^/(.*) http://spirolattic.net/wiki/$1 [P,L] the problem with something like this is that it will rewrite the=20 rewritten uri -> hence ^/([^wiki]*) to prevent it from matching a uri=20 with "wiki" in it. >>which of course fails miserably. >> >=20 > if i remember my regex's correctly what you're doing is creating a > character class with the []'s so rather then matching "wiki" plus stuff > you're matching one or more w's, i's or k's. I'm actually trying to match "non-wiki-stuff". When you're matching=20 "positive", I think (well, that's what works in the other rewrite rules=20 I have running at the moment) that (india|logbook) will match either=20 "india" or "logbook". So I tried doing this: [^(wiki)] - but it doesn't=20 work either. *sigh* if anybody else has other ideas for this, I'll be glad to hear them -=20 but please don't lose any time on it. :) Tara --=20 Je r=E9ponds au mieux de mes connaissances Climb to the Stars! - http://climbtothestars.org/ SpiroLattic - http://climbtothestars.org/spiro/ Pompeurs Associ=E9s - http://pompage.net/ |
From: Jeff D. <da...@da...> - 2001-11-16 17:34:00
|
On Fri, 16 Nov 2001 10:42:50 +0100 "Tara Star" <te...@cl...> wrote: > Adam Shand wrote: > > >>I would like http://spirolattic.net/ to point to the wiki, and > >>http://spirolattic.net/RecentChanges to point to RecentChanges... you > >>get the idea. Try: (I'm assuming this is going in a .htaccess file, if it's going into the server config file, you need to handle/expect leading /'s in the URLs. I'm also assuming you've copied index.php to 'wiki'.) RewriteEngine On RewriteRule ^wiki - [L] RewriteRule ^wiki/.* - [L] RewriteRule ^(.*) wiki/$1 [L] I think you'll also have to manually define VIRTUAL_PATH to the empty string, in 'wiki' (assuming 'wiki' is your index.php.) |