|
Posted by Kentor on 12/15/06 18:26
Oh but this only works if I remove these previous lines I had for all
my other normal redirects...
Options +FollowSymLinks
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
once i put them back with your lines, it shows the main page even with
http://monteal.mysite.com or just montreal.mysite.com =/
ok i put everything back except for RewriteCond %{REQUEST_FILENAME} !-d
and it still works... so its that line thats messing everything up...
but i had this line for my normal redirects... whats the purpose of
this -d ? do i really need it?
Rik wrote:
> Kentor wrote:
> > Ok this is really strange... =/ nothing works.
> >
> > If i use the 3 lines you gave me:
> >
> > RewriteCond %{HTTP_HOST} ^([^.]+\).mywebsitehere.com
> > RewriteCond %{HTTP_HOST} !^www\.
> > RewriteRule ^(.*)$ searchForm.php?location=%1&foo=$1 [L,QSA]
> >
> > then my whole website is dead and i get this everywhere:
>
> Internal Server Error is usually a syntax problem.
>
> Let's try:
>
> RewriteEngine On
> RewriteBase /
> RewriteCond %{HTTP_HOST} ^([^.]+)\.
> RewriteCond %{HTTP_HOST} !^www\.
> RewriteRule ^(.*)$ searchForm.php?location=%1&foo=$1 [L,QSA]
>
> It works here, using http://text.localhost/text.ext (which points to
> http://blaat.localhost/:
> ---searchForm.php---
> <?php var_dump($_REQUEST); ?>
> --------------------
> Output:
>
> array(2) { ["location"]=> string(4) "test" ["foo"]=> string(8) "test.ext" }
>
> Grtz,
> --
> Rik Wasmus
Navigation:
[Reply to this message]
|