17452 Posts in 4473 Topics by 1971 members
|Go to End|
15 October 2008 at 10:53pm Last edited: 15 October 2008 10:54pm
How do I take care of permanent page-redirects after converting an old static site to a silverstripe site? I want to redirect the old pages to the silverstripe counterparts. That is, on the old site I had a page with the url:
which on the new site correspondes to:
Normally I would just add rows in .htaccess to handle this, like:
redirect 301 /pages/pathvand/marockov1.html http://www.pathfindertravels.se/vandring-i-atlasbergen-marocko/
But this doesn't work. (Well it partly works, since the new rewritten url is http://www.pathfindertravels.se/vandring-i-atlasbergen-marocko/?url=/pages/pathvand/marockov1.html)
Should I be using Director::redirectPerm instead? And if so, how do I do that? Other ideas?
Thanks in advance,
16 October 2008 at 12:24am Last edited: 16 October 2008 12:24am
Found a discussion about this in an old thread, sorry. But following the advices in that thread, I still can't get it to work.
If I use the suggested RewriteRule, nothing happens. And if I use the redirect, the URI is rewritten, but I still get the old one attached at the end, with "?url=old_url".
Any other suggestions?
16 October 2008 at 4:11am Last edited: 30 October 2008 8:09am
Ok, I must have mixed a few things up. Anyway, this works for me now:
RewriteRule pages/english.html http://www.pathfindertravels.se/welcome-to-the-world-of-pathfinder-travels/ [R=301,L]
Case closed I guess.
17 October 2008 at 11:59am
I did file in the htaccess redirects
I feel sorry for my bad English.
|Go to Top|