|
Posted by Stephen Kay on 11/18/46 11:43
in article C04F1F23.5AE27%sk@karma-lab.nospam.com, Stephen Kay at
sk@karma-lab.nospam.com wrote on 3/28/06 5:16 PM:
>> What server are you using?
>> If you are using apache then you can use RewriteRule ... It will do exactly
>> what you are after.
>>
>> RewriteRule ^([^/]+)/([^/]+).html$ /dopage.php?p=$1 [L]
>>
>> Then you can worry about what dopage.php actually does.
I said:
> Hi Simon,
> I've been fooling around with this, and it shows signs of working for things
> like:
>
> www.mysite.com/folder/somepage.html
> However, it doesn't work for something that is in the root html folder,
> www.mysite.com/somepage.html
> Since I don't understand the syntax (yet), any suggestions?
I see, it's something like:
RewriteRule ^([^/]+)/([^/]+).html$ /dopage.php?p=$1
RewriteRule ^/([^/]+).html$ /dopage.php?p=$1 [L]
But the problem I'm having with this is that, if I rewrite all URLs and send
them to dopage.php, and then in dopage.php I'm calling curl to open a page
of my website, at that point it gets redirected the same way and there's an
infinite loop.
--
Stephen Kay
Karma-Lab sk@karma-lab.NOSPAM.com
^^^^^^^
Navigation:
[Reply to this message]
|