Support

Admin Tools

#9819 URL Redirection Not Working

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 Thursday, 07 April 2011 01:07 CDT

savvygroup
Hello,

Joomla 1.5.22
Admin Tools 2.0.2
No other htaccess rules (besides AT) an no SEF URL components.

I am trying to use the URL redirection feature and a screenshot of my config can be seen as attached. For some reason, this redirect is not working. Any suggestions? Am I missing something?

I want this http://joomlasite.org/mothersday to go to http://joomlasite.org/index.php?option=com_chronocontact&Itemid=125

For now, I have to do these custom though the htaccess but I would love to utilize this feature in the future.

nicholas
Akeeba Staff
Manager
Swap the existing URL with the new URL and you're good to go :)

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!

savvygroup
You are right.

I swear I tried that :-)

nicholas
Akeeba Staff
Manager
You're welcome!

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!

savvygroup
Nicholas, the redirect is working but I didn't notice this before.

When it redirects (using those settings) it redirects to a URL like this (see how it is repeated)

http://poshusa.org/index.php?option=com_chronocontact&Itemid=124?option=com_chronocontact&Itemid=124

Any suggestions?

For the time being I am just doing an htaccess redirect like so:
redirect 301 /mothersday https://poshusa.org/index.php?option=com_chronocontact&Itemid=124

Secondly, I have put in this content into the Force SSL box.
index.php?option=com_chronocontact&Itemid=124
index.php?option=com_chronocontact&Itemid=125
I also tried with the full URL and with a / at the beginning

I want these pages to be SSL but it is not forcing it. Suggestions for this?

Here is what the htaccess looks like:
### ===========================================================================
### Security Enhanced & Highly Optimized .htaccess File for Joomla!
### automatically generated by Admin Tools 2.0.2 on 2011-04-06 17:18:09 GMT
### ===========================================================================
###
### The contents of this file are based on the same author's work "Master
### .htaccess", published on http://snipt.net/nikosdion/the-master-htaccess
###
### Admin Tools is Free Software, distributed under the terms of the GNU
### General Public License version 3 or, at your option, any later version
### published by the Free Software Foundation.
###
### !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! IMPORTANT !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
### !!                                                                       !!
### !!  If you get an Internal Server Error 500 or a blank page when trying  !!
### !!  to access your site, remove this file and try tweaking its settings  !!
### !!  in the back-end of the Admin Tools component.                        !!
### !!                                                                       !!
### !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
###

##### RewriteEngine enabled - BEGIN
RewriteEngine On
##### RewriteEngine enabled - END

##### RewriteBase set - BEGIN
RewriteBase /
##### RewriteBase set - END

##### Custom Rules (Top of File) -- BEGIN
redirect 301 /mothersday https://poshusa.org/index.php?option=com_chronocontact&Itemid=124
redirect 301 /diadelasmadres https://poshusa.org/index.php?option=com_chronocontact&Itemid=125
##### Custom Rules (Top of File) -- END

##### File execution order -- BEGIN
DirectoryIndex index.php index.html
##### File execution order -- END

##### No directory listings -- BEGIN
IndexIgnore *
Options All -Indexes
##### No directory listings -- END

##### Redirect index.php to / -- BEGIN
# Method #1 - Most servers
RewriteCond %{THE_REQUEST} ^.*/index\.php$
RewriteRule ^index\.php$ http://poshusa.org/ [R,L]
##### Redirect index.php to / -- END

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

##### Force HTTPS for certain pages -- BEGIN
RewriteCond %{HTTPS} ^off$ [NC]
RewriteRule ^http:\/\/poshusa\.org\/index\.php\?option=com_chronocontact&Itemid=124$ https://poshusa.org/http://poshusa.org/index.php?option=com_chronocontact&Itemid=124 [L,R]
RewriteCond %{HTTPS} ^off$ [NC]
RewriteRule ^http:\/\/poshusa\.org\/index\.php\?option=com_chronocontact&Itemid=125$ https://poshusa.org/http://poshusa.org/index.php?option=com_chronocontact&Itemid=125 [L,R]
##### Force HTTPS for certain pages -- END

##### Rewrite rules to block out some common exploits -- BEGIN
RewriteCond %{QUERY_STRING} proc/self/environ [OR]
RewriteCond %{QUERY_STRING} mosConfig_[a-zA-Z_]{1,21}(=|\%3D) [OR]
RewriteCond %{QUERY_STRING} base64_encode.*\(.*\) [OR]
RewriteCond %{QUERY_STRING} base64_decode.*\(.*\) [OR]
RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]
RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\[0-9A-Z]{0,2}) [OR]
RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\[0-9A-Z]{0,2})
RewriteRule ^(.*)$ index.php [F,L]
##### Rewrite rules to block out some common exploits -- END

##### File injection protection -- BEGIN
RewriteCond %{REQUEST_METHOD} GET
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]\=http:\/\/(.*) [OR]
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]\=(\.\.\/{1,2}){1,}(.*) [OR]
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]\=\/([a-zA-Z0-9_.]\/{1,2}){1,}(.*)
RewriteRule ^(.*)$ - [F,L]
##### File injection protection -- END

##### Advanced server protection rules exceptions -- BEGIN
RewriteRule ^(components\/com_uddeim\/captcha15\.php) $1 [L]
RewriteRule ^(components\/com_virtuemart\/fetchscript\.php) $1 [L]
RewriteRule ^(administrator\/components\/com_extplorer\/fetchscript\.php) $1 [L]
RewriteRule ^(plugins\/system\/GoogleGears\/gears-manifest\.php) $1 [L]
RewriteRule ^(plugins\/content\/jw_allvideos\/includes\/jw_allvideos_scripts\.php) $1 [L]
RewriteRule ^(administrator\/components\/com_akeeba\/restore\.php) $1 [L]
RewriteRule ^(administrator\/components\/com_admintools\/restore\.php) $1 [L]
RewriteCond %{REQUEST_FILENAME} !(\.php)$
RewriteRule ^(components\/com_agora\/img\/members/.*) $1 [L]
##### Advanced server protection rules exceptions -- END

##### Advanced server protection -- BEGIN

## Referrer filtering for common media files
RewriteRule ^(images/stories/.*\.(jpe|jpg|jpeg|jp2|jpe2|png|gif|bmp|css|js|swf|html|html))$ $1 [L]
RewriteCond %{REQUEST_FILENAME} -f
RewriteCond %{HTTP_REFERER} !^(http://poshusa\.org|https://poshusa\.org) [NC]
RewriteRule \.(jpe|jpg|jpeg|jp2|jpe2|png|gif|bmp|css|js|swf|html|html)$ - [F,L]
## Disallow PHP Easter Eggs
RewriteCond %{QUERY_STRING} =PHP[a-z0-9]{8}-[a-z0-9]{4}-[a-z0-9]{4}-[a-z0-9]{4}-[a-z0-9]{12} [NC]
RewriteRule ^(.*)$ - [F,L]
## Explicitly allow access only to XML-RPC's xmlrpc/index.php or plain xmlrpc/ directory
RewriteRule ^(xmlrpc/index\.php)$ $1 [L]
RewriteRule ^xmlrpc/(.*)$ - [F,L]
## Disallow access to htaccess.txt and configuration.php-dist
RewriteRule ^(htaccess\.txt|configuration\.php-dist)$ - [F,L]
##### Advanced server protection -- END

##### Joomla! core SEF Section -- BEGIN
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteCond %{REQUEST_URI} !^/index.php
RewriteCond %{REQUEST_URI} (/|\.php|\.html|\.htm|\.feed|\.pdf|\.raw|\.ini|\.zip|\.json|/[^.]*)$  [NC]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.*) index.php [L]
##### Joomla! core SEF Section -- END

nicholas
Akeeba Staff
Manager
The redirection issue is a bug with our custom router. I am fixing that for 2.0.3 which is due for release today.

The HTTPS issue is due to the way .htaccess works. It doesn't allow you to redirect URLs with queries. AFAIK, it only works with SEF URLs turned on.

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!