Support

Admin Tools

#15609 .htaccess forced www exception

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 nicholas on Tuesday, 02 April 2013 03:24 CDT

mhilliard
Mandatory information about my setup:

Have I read the related troubleshooter articles above before posting (which pages?)? Yes
Have I searched the tickets before posting? Yes
Have I read the documentation before posting (which pages?)? Yes
Joomla! version: 2.5.9
PHP version: 5.3.13
MySQL version: 5.0.96
Host: (optional, but it helps us help you)
Admin Tools version: 2.5.3

Description of my issue: First, thanks for programming such outstanding tools – you've saved us hours with Admin Tools and Backup!

We have a site that requires all addresses to add WWW to each URL and we've configured the .htaccess Maker to reflect that. However, we also have a specific URL that cannot have the WWW prefix in the address and every test we've tried to redirect the page to a non-WWW URL results in errors.

Is there a simple redirect that would change http://www.mydomain.com/component/users/?view=registration (either with or without the WWW) to just http://mydomain.com/component/users/?view=registration without the WWW, but still honor these rules?

##### Redirect non-www to www -- BEGIN
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]
##### Redirect non-www to www -- END

nicholas
Akeeba Staff
Manager
I honestly have no idea how you can satisfy both conflicting requirements with .htaccess.

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!

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!