In-Portal Issue Tracker - In-Portal CMS
Viewing Issue Advanced Details
548 [In-Portal CMS] Front End bug report always 2010-01-19 08:30 2010-07-22 15:06
alex  
alex  
normal  
closed 5.0.2  
fixed  
 
none 5.1.0-B1  
http://groups.google.com/group/in-portal-dev/browse_thread/thread/4657b3af9de8f9d8
0
0000548: Automatic mod-rewrite redirecting
1. I propose we redirect with 301 code (moved permanently) in case if user visits non-rewrited url, when mod-rewrite is currently enabled.
2. Also we could redirect to "index" template (maybe with same code) in case if user just types site url without concrete page.

This will make google analytics statistics more readable and google will be happy to automatically update it's search index.
related to 0000252closed  (5.1.0)alex Add ability to specify custom HTTP response code along with redirect header 
parent of 0000828closed  (5.1.1)alex Auto-redirect from non-mod-rewrite url becomes very unstable 
related to 0000454closed  (5.1.0)alex Customizable URL Endings for Mod-rewrite 
patch 548-Automatic_mod_rewrite_redirecting-Dmitry-20100129-v1.patch (1,556) 2010-01-29 19:06
http://tracker.in-portal.org/file_download.php?file_id=257&type=bug
patch mod_rewrite_redirecting_proper_alex.patch (1,769) 2010-02-03 14:18
http://tracker.in-portal.org/file_download.php?file_id=272&type=bug
patch mod_rewrite_redirecting_proper_alex_v2.patch (1,769) 2010-04-27 09:16
http://tracker.in-portal.org/file_download.php?file_id=490&type=bug
patch no_redirect_on_home_page.patch (885) 2010-05-05 02:19
http://tracker.in-portal.org/file_download.php?file_id=520&type=bug
Issue History
2010-08-21 10:59 alex Relationship added parent of 0000828
2010-07-22 15:06 alex Note Added: 0002532
2010-07-22 15:06 alex Status resolved => closed
2010-05-05 11:15 alex Note Added: 0002065
2010-05-05 11:15 alex Status reviewed and tested => resolved
2010-05-05 11:15 alex Resolution reopened => fixed
2010-05-05 11:15 alex Changeset attached 5.1.x r13490
2010-05-05 08:48 Dmitry Note Added: 0002061
2010-05-05 08:48 Dmitry Assigned To !COMMUNITY => alex
2010-05-05 08:48 Dmitry Status needs testing => reviewed and tested
2010-05-05 02:19 alex Note Added: 0002059
2010-05-05 02:19 alex Assigned To alex => !COMMUNITY
2010-05-05 02:19 alex Developer Dmitry => alex
2010-05-05 02:19 alex Status needs feedback => needs testing
2010-05-05 02:19 alex File Added: no_redirect_on_home_page.patch
2010-05-02 12:02 Dmitry Status active => needs feedback
2010-05-02 12:02 Dmitry Note Added: 0002047
2010-05-02 12:02 Dmitry Assigned To Dmitry => alex
2010-05-02 12:02 Dmitry Status needs feedback => active
2010-05-02 11:28 alex Assigned To alex => Dmitry
2010-05-02 11:28 alex Note Added: 0002046
2010-05-02 10:59 Dmitry Note Added: 0002044
2010-05-02 10:59 Dmitry Status resolved => needs feedback
2010-05-02 10:59 Dmitry Resolution fixed => reopened
2010-05-02 05:33 alex Relationship added related to 0000454
2010-04-27 12:25 alex Note Added: 0001983
2010-04-27 12:25 alex Status reviewed and tested => resolved
2010-04-27 12:25 alex Fixed in Version => 5.1.0-B1
2010-04-27 12:25 alex Resolution open => fixed
2010-04-27 12:25 alex Assigned To !COMMUNITY => alex
2010-04-27 12:25 alex Changeset attached 5.1.x r13446
2010-04-27 11:45 Dmitry Note Added: 0001977
2010-04-27 11:45 Dmitry Status needs testing => reviewed and tested
2010-04-27 11:45 Dmitry Developer alex => Dmitry
2010-04-27 11:45 Dmitry Status needs work => needs testing
2010-04-27 09:16 alex Note Added: 0001974
2010-04-27 09:16 alex File Added: mod_rewrite_redirecting_proper_alex_v2.patch
2010-04-12 19:03 Dmitry Note Added: 0001875
2010-04-12 19:03 Dmitry Status needs testing => needs work
2010-02-27 04:23 alex Developer => alex
2010-02-03 14:20 alex Issue Monitored: Dmitry
2010-02-03 14:20 alex Note Added: 0001455
2010-02-03 14:19 alex Note Added: 0001454
2010-02-03 14:18 alex File Added: mod_rewrite_redirecting_proper_alex.patch
2010-02-03 13:34 alex Relationship added related to 0000252
2010-02-03 13:34 alex Note Edited: 0001444 bug_revision_view_page.php?bugnote_id=0001444#r389
2010-02-03 13:34 alex Target Version 5.0.3 => 5.1.0
2010-02-03 13:34 alex Description Updated bug_revision_view_page.php?rev_id=387#r387
2010-01-29 19:06 Dmitry File Added: 548-Automatic_mod_rewrite_redirecting-Dmitry-20100129-v1.patch
2010-01-29 19:05 Dmitry Note Added: 0001444
2010-01-29 19:05 Dmitry Assigned To Dmitry => !COMMUNITY
2010-01-29 19:05 Dmitry Status needs work => needs testing
2010-01-22 11:55 Dmitry Assigned To => Dmitry
2010-01-22 11:55 Dmitry Status active => needs work
2010-01-19 08:31 alex Target Version => 5.0.3
2010-01-19 08:30 alex New Issue
2010-01-19 08:30 alex Reference => http://groups.google.com/group/in-portal-dev/browse_thread/thread/4657b3af9de8f9d8

Notes
(0001444)
Dmitry   
2010-01-29 19:05   
(edited on: 2010-02-03 13:34)
Please note:

1. Please see and test attached Patch.

(0001454)
alex   
2010-02-03 14:19   
Patch "mod_rewrite_redirecting_proper_alex.patch" is more advanced version of "548-Automatic_mod_rewrite_redirecting-Dmitry-20100129-v1.patch" patch which also includes:
- support for GW_NOTIFY constant
- prevent infinite redirect when "tools/show_cache.php" script was used
(0001455)
alex   
2010-02-03 14:20   
Reminder sent to: Dmitry

It's your time to test now.
(0001875)
Dmitry   
2010-04-12 19:03   
Strange - didn't work as expected:

I had Mod-Rewrite ON and visited /index.php?env=-news:m3-1-1-5-s- expecting to be redirect (which took place) with 301 code but the following headers were sent (200) as you can see.


Response Headers - http://simone1.intechnic.com/dev/SVN/5.1.x/index.php?env=-news:m3-1-1-5-s-

Date: Tue, 13 Apr 2010 00:00:08 GMT
Server: Apache/2.2.9 (Fedora)
X-Powered-By: PHP/5.3.1 ZendServer/5.0
Set-Cookie: ZDEDebuggerPresent=php,phtml,php3; path=/
sid=992593847; expires=Tue, 13-Apr-2010 01:59:39 GMT; path=/dev/SVN/5.1.x; domain=.simone1.intechnic.com
sid_live=992593847; path=/dev/SVN/5.1.x; domain=.simone1.intechnic.com
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Transfer-Encoding: chunked
Content-Type: text/html; charset=UTF-8

200 OK
(0001974)
alex   
2010-04-27 09:16   
Patch "mod_rewrite_redirecting_proper_alex_v2.patch" contains re-assembled version of previous patch. Only SVN version differs.
(0001977)
Dmitry   
2010-04-27 11:45   
Tested good!
(0001983)
alex   
2010-04-27 12:25   
Fix committed to 5.1.x branch. Commit Message:

Fixes 0000548: Automatic mod-rewrite redirecting
(0002044)
Dmitry   
2010-05-02 10:59   
when I select Force URL End Redirect and I enter the website:

http://www.jurmala.com/SVN/in-portal-5.1.x (or http://www.jurmala.com/SVN/in-portal-5.1.x/)

I get redirected to:

http://www.jurmala.com/SVN/in-portal-5.1.x/index/

This should NOT happen for Index page I think, at least we should not add "index".
(0002046)
alex   
2010-05-02 11:28   
Reminder sent to: Dmitry

I disagree about that, since without that redirect both:
http://www.site.com/ and http://www.site.com/index.html will lead to same place resulting duplicate content in google.
(0002047)
Dmitry   
2010-05-02 12:02   
Actually I think you are wrong here:

http://www.google.com/index.html
http://www.google.com

As you can see it's the same page and this is done this was since it's Index of the site and you can even specify index in Google Analytics so it treats / and index.html (or whatever) as one page.

I believe we should add an Exception for Index page.
(0002059)
alex   
2010-05-05 02:19   
Please test "no_redirect_on_home_page.patch" patch.
(0002061)
Dmitry   
2010-05-05 08:48   
Tested good, please commit!
(0002065)
alex   
2010-05-05 11:15   
Fix committed to 5.1.x branch. Commit Message:

Fixes 0000548: Automatic mod-rewrite redirecting
(0002532)
alex   
2010-07-22 15:06   
Closing, since 5.1.0 release has been released.