?
avatar sneadm
sneadm
31 Oct 2016

Steps to reproduce the issue

Create a redirect link for http://www.mysite.com/page to go to http://www.mysite.com/mypage.
Enter a URL of http://www.mysite.com/page, successful redirect to http://www.mysite.com/mypage.
Enter a URL of http://www.mysite.com/Page , returns 404.
Attempt to create a redirect link for http://www.mysite.com/Page in the redirect component, returns the message "Source URL must be unique".

Expected result

either both urls http://www.mysite.com/Page and . . . /page would successfully redirect
OR
allow entry of redirect for both source URLS /Page and /page.

I think first would be preferred.screen shot 2016-10-31 at 14 10 12

Actual result

System information (as much as possible)

See attached screenshot of system info display.

Additional comments

Votes

# of Users Experiencing Issue
2/2
Average Importance Score
4.00

avatar sneadm sneadm - open - 31 Oct 2016
avatar tonypartridge
tonypartridge - comment - 4 Dec 2016

Is this a Joomla! Issue? What happens if you access a live page then capitalise one letter?

Traditionally the urls are case sensitive unless a module has been installed on the server to stop case sensitivity on urls.

avatar dmurphy779
dmurphy779 - comment - 31 Jan 2017

I have the same problem. According to the (forum)[https://forum.joomla.org/viewtopic.php?t=932554], other people are having the same issue also.

  1. Create URL redirect with source url in lower case (e.g. http://mysite.com/test
  2. Type in a capital version of the url in the browser (e.g. http://mysite.com/Test

Result: 404 page

Expected Result: redirect to destination url


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/12666.

avatar dmurphy779
dmurphy779 - comment - 31 Jan 2017

To answer tonypartridge, changing case on an existing page does not result in 404. Only fails if redirect source urls have incorrect case.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/12666.

avatar dmurphy779
dmurphy779 - comment - 1 Feb 2017

I would love to help code a solution if someone can just point me in the right direction.

I believe that the problem is:

  1. A redirect source url is created http://mysite.com/test
  2. Visitor enters http://mysite.com/Test in the browser (uppercase used)
  3. The database is queried for a matching redirect using a case sensitive parameter (fails)
  4. The page is redirected to a 404 page because the redirect plugin did not find a matching redirect source url

I believe the solution is to correct the visitor's query to match a non-case sensitive redirect source url.

My question: What file controls the visitor's query to check if the source redirect exists?

Would it be plugins/system/redirect/redirect.php?

Thanks!

Note: using Joomla 3.6.5


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/12666.

avatar dmurphy779
dmurphy779 - comment - 1 Feb 2017

Nope - scratch that. I queried the database using both uppercase and lowercase and still retrieves the set. The collation is set to utf8mb4_unicode_ci so the row is case insensitive (_ci). I don't know... Maybe something with the url mapping?


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/12666.

avatar tonypartridge
tonypartridge - comment - 2 Feb 2017

@dmurphy779 leave it with me, It's in the plugin but I need to validate my fix before submitted a PR.

avatar zero-24
zero-24 - comment - 4 Feb 2017

PR is: #13853

avatar zero-24 zero-24 - change - 4 Feb 2017
Status New Closed
Closed_Date 0000-00-00 00:00:00 2017-02-04 21:25:45
Closed_By zero-24
avatar zero-24 zero-24 - close - 4 Feb 2017
avatar dmurphy779
dmurphy779 - comment - 9 Feb 2017

Thanks Tony!

Add a Comment

Login with GitHub to post a comment