Support

Admin Tools

#15527 Redirection help for https to http

Posted in ‘Admin Tools for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Admin Tools version
n/a

Latest post by sandstorm871 on Wednesday, 20 March 2013 07:23 CDT

sandstorm871

Mandatory information about my setup:

Have I read the related troubleshooter articles above before posting (which pages?)? Yes, nothing on redirection
Have I searched the tickets before posting? Yes
Have I read the documentation before posting (which pages?)? Yes AT, redirection stuff
Joomla! version: 2.5.9
PHP version: 5.3.15
MySQL version: 5.0.96
Host: Dedicated Server
Admin Tools version: 2.5.3

Description of my issue:

Swapped my website over from J1.5 to J2.5 a couple of weeks ago.

We have SSL on the site and wasnt configured properly when the site went live and now Google has got hold of 2 links (probably our 2 most important) and has them recorded as https://www.mysite.com/link1 instead of normal HTTP:// links.

I have researched how to get rid of these via google and other sources from around the web & as they are not needed as https links and a  301 redirect seems the safest option.

I have tried to set this up in AT URL Redirection, but this doesnt seem to work.

Will the URL redirection tool in AT only handle redirects after the mysite.com/ ?

I also use SH404SEF and can't set up a 301 Alias there either.

 

Thanks in advance,

Andy

nicholas
Akeeba Staff
Manager

Hello Andy,

This is not possible. You need some complex .htaccess rule to do that but that's beyond the scope of the support I can offer. That said, I believe that you need to add a .htaccess rule like this for each link (please note, that's untested and out of the top of my head):

RewriteCond %{SERVER_PORT} ^443$
## Alternatively, comment the above line and uncomment the following line:
# RewriteCond %{HTTPS} ^on$ [NC]
RewriteRule ^link1\.html$ https://www.example.com/link1.html [R=301,L]

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

sandstorm871

Thanks Nic!

I thought so but wanted to check with you. I also appreciate the .htaccess stuff is beyond teh support for Admin Tools, so thanks for taking the time to let me knwo that. I'll try it in a while.

I tried some similar .htaccess rules earlier, but they didnt work well - different to yours though. So I'll come back here and let you know if it works in case it helps anyone else out in the future too!

sandstorm871

Tried both ways and it didnt work.

Just tried this though and thsi seems to work OK for one of the URLS.

RewriteCond %{SERVER_PORT} ^443$
RewriteCond %{REQUEST_URI} !^/category/page
RewriteRule ^(.*)$ http://www.mysite.com/category/page [R=301,L]

nicholas
Akeeba Staff
Manager

All right, that would be the third thing I'd try :)

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

sandstorm871

My code only works for 1 link :o(When 2 are needed the 2nd link redirects to the firts one?

Back to the drawing board!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!