Results 1 to 9 of 9
  1. #1
    Join Date
    May 2015
    Posts
    4
    Plugin Contributions
    0

    Default HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    Hi, newbie here. My client has version 1.3.8a running in a subdirectory (/zencart) but it now requires a new design which i have been brought in to do on the latest ZC version.

    I've never worked with ZC and the previous designer just left it untouched for years. He has two identical .htaccess files - one in root and one in /zencart. When i install the latest ZC version in the new subfolder (/zencart2) and run the install i get an infinate loop preventing me from installing in that folder.

    The htaccess contents are here:

    *********
    AddHandler x-mapp-php4 .php

    RewriteEngine On

    RewriteCond %{HTTP_HOST} ^.*THECLIENTSWEBSITE.co.uk$ [NC]
    RewriteRule ^(.*)$ http://THECLIENTSWEBSITE.co.uk/zencart$1 [R=301,L]

    AddType text/x-component .htc
    *********

    can anyone help me get around this so i can run an install? Thanks guys.

  2. #2
    Join Date
    Jul 2012
    Posts
    16,817
    Plugin Contributions
    17

    Default Re: HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    Quote Originally Posted by Nigel Bywater View Post
    Hi, newbie here. My client has version 1.3.8a running in a subdirectory (/zencart) but it now requires a new design which i have been brought in to do on the latest ZC version.

    I've never worked with ZC and the previous designer just left it untouched for years. He has two identical .htaccess files - one in root and one in /zencart. When i install the latest ZC version in the new subfolder (/zencart2) and run the install i get an infinate loop preventing me from installing in that folder.

    The htaccess contents are here:

    *********
    AddHandler x-mapp-php4 .php

    RewriteEngine On

    RewriteCond %{HTTP_HOST} ^.*THECLIENTSWEBSITE.co.uk$ [NC]
    RewriteRule ^(.*)$ http://THECLIENTSWEBSITE.co.uk/zencart$1 [R=301,L]

    AddType text/x-component .htc
    *********

    can anyone help me get around this so i can run an install? Thanks guys.
    Need to evaluate that the requested directory is not your new "temp" directory.

    Besides this, the store should be just in the root directory instead of being seen by visitors as being in a sub-directory.

    Additional rewrite rule needed:

    Code:
    RewriteCond %{REQUEST_URI} !^/zencart2 [NC]
    Making your .htaccess:

    Code:
    AddHandler x-mapp-php4 .php
    
    RewriteEngine On
    
    RewriteCond %{HTTP_HOST} ^.*THECLIENTSWEBSITE.co.uk$ [NC]
    RewriteCond %{REQUEST_URI} !^/zencart2 [NC]
    RewriteRule ^(.*)$ http://THECLIENTSWEBSITE.co.uk/zencart$1 [R=301,L]
    
    AddType text/x-component .htc
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  3. #3
    Join Date
    Jul 2012
    Posts
    16,817
    Plugin Contributions
    17

    Default Re: HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    There are a number of ways to revise the .htaccess in the future if the store is not brought up one directory to be in the main directory. Even if it is not moved up, I would suggest an .htaccess rewrite to remove the sub-directory from the provided path and redirect sub-directory calls to the main directory. The difference in all of this is that there is the uri that visitors see and then there is the file directory structure.

    Currently ZC is installed in some path leading up to public_html then in a subdirectory of zencart. So the customer sees on their browser sitename. com/zencart.

    Ideally, the customer should only see sitename. com and be done with it.

    This does not mean that the filestructure must change though, because if the pointer for sitename. com is such that it sends to that directory, then the customer wouldn't know that it is in a sub-directory of public_html. Problem is, and why the above suggestion, that previous customers (and search engines) know the site content as sitename. com/zencart. So need to have that modified as after the above "shift" that sub-directory won't exist from the internet side. So, that would be a reason to use an .htaccess redirect from sitename. com/zencart to sitename. com... (Keeping all following tokens.)
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  4. #4
    Join Date
    May 2015
    Posts
    4
    Plugin Contributions
    0

    Default Re: HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    You have no idea how much you've just helped. This has been driving me insane and the other developers has been no help. My concern is the loss of SE links by moving it out of the subdirectory but i'll solve that. Thanks again mc12345678. I'll update this post if I have any issues I think.

  5. #5
    Join Date
    Jul 2012
    Posts
    16,817
    Plugin Contributions
    17

    Default Re: HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    Quote Originally Posted by Nigel Bywater View Post
    You have no idea how much you've just helped. This has been driving me insane and the other developers has been no help. My concern is the loss of SE links by moving it out of the subdirectory but i'll solve that. Thanks again mc12345678. I'll update this post if I have any issues I think.
    So a properly formatted redirect is less of an issue than a complete lack of the product(s) being found. It is understood that some things may move, and generally speaking a single redirect is not an issue (meaning one rule to move from a subdirectory to a parent or other directory.) If however, you end up with redirects on redirects then things become 1) more confusing and 2) potentially an issue for search engines and rankings. Get things working properly first, then begin planning your redirect.

    But glad that at least can now get through the testing part of creating your development site.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  6. #6
    Join Date
    May 2015
    Posts
    4
    Plugin Contributions
    0

    Default Re: HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    Quote Originally Posted by mc12345678 View Post
    There are a number of ways to revise the .htaccess in the future if the store is not brought up one directory to be in the main directory. Even if it is not moved up, I would suggest an .htaccess rewrite to remove the sub-directory from the provided path and redirect sub-directory calls to the main directory. The difference in all of this is that there is the uri that visitors see and then there is the file directory structure.

    Currently ZC is installed in some path leading up to public_html then in a subdirectory of zencart. So the customer sees on their browser sitename. com/zencart.

    Ideally, the customer should only see sitename. com and be done with it.

    This does not mean that the filestructure must change though, because if the pointer for sitename. com is such that it sends to that directory, then the customer wouldn't know that it is in a sub-directory of public_html. Problem is, and why the above suggestion, that previous customers (and search engines) know the site content as sitename. com/zencart. So need to have that modified as after the above "shift" that sub-directory won't exist from the internet side. So, that would be a reason to use an .htaccess redirect from sitename. com/zencart to sitename. com... (Keeping all following tokens.)
    So this access ruse has enabled me to access the zencart2 subfolder to install but the php version is out of date. Now i can upgrade the version but do you know if the old ZC version 1.3.8 will run on php5 or will it crash the existing site?

  7. #7
    Join Date
    Jul 2012
    Posts
    16,817
    Plugin Contributions
    17

    Default Re: HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    Quote Originally Posted by Nigel Bywater View Post
    So this access ruse has enabled me to access the zencart2 subfolder to install but the php version is out of date. Now i can upgrade the version but do you know if the old ZC version 1.3.8 will run on php5 or will it crash the existing site?
    See http://www.zen-cart.com/content.php?48
    For compatibility information; however generally speaking 1.3.8 will not work on PHP 5.3 and above. ZC 1.5.4 should not be operated on PHP 5.2.x; however, if you look at the below link, there are ways to temporarily allow it to operate on PHP 5.2.x (preferably at least 5.2.17):
    http://www.zen-cart.com/showthread.p...s)-with-v1-5-4
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  8. #8
    Join Date
    May 2015
    Posts
    4
    Plugin Contributions
    0

    Default Re: HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    Quote Originally Posted by mc12345678 View Post
    See http://www.zen-cart.com/content.php?48
    For compatibility information; however generally speaking 1.3.8 will not work on PHP 5.3 and above. ZC 1.5.4 should not be operated on PHP 5.2.x; however, if you look at the below link, there are ways to temporarily allow it to operate on PHP 5.2.x (preferably at least 5.2.17):
    http://www.zen-cart.com/showthread.p...s)-with-v1-5-4
    Are you able to help with the version update for a fee? I tried to PM you but your box is full.

  9. #9
    Join Date
    Jul 2012
    Posts
    16,817
    Plugin Contributions
    17

    Default Re: HTACCESS Infinate Loop blocking upgrade - URGENT HELP NEEDED

    Quote Originally Posted by Nigel Bywater View Post
    Are you able to help with the version update for a fee? I tried to PM you but your box is full.
    Responded via PM. :)
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

 

 

Similar Threads

  1. htaccess help - blocking access to robots.txt
    By spid3r1987 in forum General Questions
    Replies: 0
    Last Post: 6 Oct 2009, 09:35 AM
  2. .htaccess Blocking Images
    By chava in forum General Questions
    Replies: 6
    Last Post: 25 Jul 2007, 02:49 PM
  3. Urgent Urgent help needed please
    By con-fused in forum General Questions
    Replies: 1
    Last Post: 12 Feb 2007, 09:41 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg