2.5 Redirects versus 1.5
- BillyS
- Topic Author
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 1
11 years 8 months ago #6915
by BillyS
Emir -
Trying to figure out if what I'm seeing is correct or if there is a fix...
On the existing site (Joomla 1.5), when I use the SEF Advance's redirect it seems to be case insensitive. For example, if I set up the redirect for :
/This/Old-Page/
to:
/This/New-Page/
Even if the url is:
/this/old-page/
it redirects to:
/This/New-Page/
I just purchased SEF 2011 for 2.5 and I'm testing on localhost...
using the same process:
/This/Old-Page/
redirects to:
/This/New-Page/
However,
/this/old-page/
Give me a 404
Of course I have thousands of hard coded mixed case urls because I used title in Joomla 1.5. Of course 2.5 doesn't like them, so all the new urls will be lower case.
If I leave the mixed case redirect in, then all of the external links will redirect correctly in 2.5. But if I change the on-site urls to lowercase, if there are any that used to redirect, they will now give a 404.
Any suggestions? Is the above case correct?
Your help is always apprecaited.
Bill
Trying to figure out if what I'm seeing is correct or if there is a fix...
On the existing site (Joomla 1.5), when I use the SEF Advance's redirect it seems to be case insensitive. For example, if I set up the redirect for :
/This/Old-Page/
to:
/This/New-Page/
Even if the url is:
/this/old-page/
it redirects to:
/This/New-Page/
I just purchased SEF 2011 for 2.5 and I'm testing on localhost...
using the same process:
/This/Old-Page/
redirects to:
/This/New-Page/
However,
/this/old-page/
Give me a 404
Of course I have thousands of hard coded mixed case urls because I used title in Joomla 1.5. Of course 2.5 doesn't like them, so all the new urls will be lower case.
If I leave the mixed case redirect in, then all of the external links will redirect correctly in 2.5. But if I change the on-site urls to lowercase, if there are any that used to redirect, they will now give a 404.
Any suggestions? Is the above case correct?
Your help is always apprecaited.
Bill
Please Log in or Create an account to join the conversation.
- BillyS
- Topic Author
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 1
11 years 8 months ago #6918
by BillyS
I think I've solved this one...
The basic problem is to standardize on lowercase URI. Prior versions of Joomla (and Mambo) allowed for mixed case. Starting with 2.5, lowercase is now mandatory. (I understand there are ways around this, but that requires hacking files, which is a nightmare to maintain.)
I'm want to take advantage of Apache's capabilities, so I'm adding to the httpd.conf:
RewriteEngine On
RewriteMap lc int:tolower
Then adding this right after RewriteEngine On in .htaccess:
RewriteCond %{REQUEST_URI} [A-Z]
RewriteRule (.*) ${lc:$1} [R=301,L]
The above should take any request that has an uppercase letter and rewrite it in all lowercase.
Next I have to take any of the mixed case redirects I've created in SEF Advance and make them all lowercase since SEF Advance will only see the URI after Apache has converted to lowercase.
Any concerns with the above?
Bill
The basic problem is to standardize on lowercase URI. Prior versions of Joomla (and Mambo) allowed for mixed case. Starting with 2.5, lowercase is now mandatory. (I understand there are ways around this, but that requires hacking files, which is a nightmare to maintain.)
I'm want to take advantage of Apache's capabilities, so I'm adding to the httpd.conf:
RewriteEngine On
RewriteMap lc int:tolower
Then adding this right after RewriteEngine On in .htaccess:
RewriteCond %{REQUEST_URI} [A-Z]
RewriteRule (.*) ${lc:$1} [R=301,L]
The above should take any request that has an uppercase letter and rewrite it in all lowercase.
Next I have to take any of the mixed case redirects I've created in SEF Advance and make them all lowercase since SEF Advance will only see the URI after Apache has converted to lowercase.
Any concerns with the above?
Bill
Please Log in or Create an account to join the conversation.