Ceon URI Mapping

Frequently Asked Questions (FAQs)

  1. The software is installed and working but the store's URIs still use dynamic Zen Cart ones (like index.php?main_page=xx).
  2. A 404 server error is being displayed (e.g. a 404 error).
  3. A server error is being displayed (e.g. a “500 Bad Request” error).
  4. When Ceon URI Mapping is enabled images stop appearing on the site!
  5. When Ceon URI Mapping is enabled the site's layout is messed up!
  6. When Ceon URI Mapping is enabled a module on the site doesn't work properly! (E.g. Dynamic menus/popups etc. stop working).
  7. When the rewrite rule for Ceon URI Mapping is added, some file types on the site are blocked or showing up as 404s!
  8. A session parameter (like “?zenid=XXXX”) is being added to the end of the store's URIs.
  9. A string beginning with “?cPath” is being added to the end of a product's URI.
  10. After adding the rewrite rule access to part of the site (e.g. the site's control panel) is being blocked.
  11. Some of the core files have already been modified for the site. How can the Ceon URI Mapping code be added?
  12. Some of the template files for the site have already been modified. How can the Ceon URI Mapping code be added?
  13. The software is installed but there is no “Ceon URI Mapping (SEO)” option in the store's “Configuration” menu.
  14. When installing/upgrading the software there is no menu item called “Ceon URI Mapping (SEO) Config” in the “Modules” menu of the store's Zen Cart admin.
  1. The software is installed and working but the store's URIs still use dynamic Zen Cart ones (like index.php?main_page=xx).

    • Ceon URI Mapping does not automatically add mappings for existing Categories/Products/Manufacturers/EZ-Pages!

      You can read more about this here.

    • If that is not the source of the “problem” and you have added some mappings, but the store is still using dynamic URIs where it should be mapping to static URIs, then a problem may have occurred during the installation of the software...

      This FAQ may have the answer to the problem.

    Back to top

  2. A server error is being displayed (e.g. a 404 error).

    This is most likely caused by the person installing the software not having added a working Rewrite Rule.

    As is mentioned in the Setting up a Rewrite Rule section of the documentation, a RewriteRule needs to be added for the store, either to a .htaccess file or a VirtualHost Directive.

    Follow the instructions in the Setting up a Rewrite Rule section of the documentation.

    If that doesn't help, then, this kind of issue is something that is outside the scope of this documentation. There are plenty of guides to be found on the internet on how to configure a server properly for Rewrite handling.

    Please Note: If you attempt to contact Ceon directly about any such issues you may be required to pay for any support given, as outlined in the support documentation.

    Back to top

  3. A server error is being displayed (e.g. a “Bad Request” error).

    This is most likely caused by using the wrong path to “index.php” being used in the RewriteRule directive or by other rewrite rules on the server interfering with the rule being used for the Ceon URI Mapping module.

    • If putting the rule in a .htaccess file, then care needs to be taken with the location of the file and the final path to index.php being used in the RewriteRule directive.
    • If putting the rule in a VirtualHost directive, the RewriteRule will need to have the relative path to the Zen Cart directory prepended to index.php.
    • If putting the rule in a .htaccess file, make sure the directory the shop is in (e.g. “shop/”) is before index.php in the last line of the Rewrite Rule. That may fix things!

      For example, the line may end up looking as follows (note that there's no slash at the beginning of the shop's directory name):

      RewriteRule .* shop/index.php?%{QUERY_STRING} [L]

    • If that doesn't work, try putting a slash in front of the path to the index.php file.

      For example, the line may end up looking like one of the following:

      RewriteRule .* /index.php?%{QUERY_STRING} [L]

      RewriteRule .* /shop/index.php?%{QUERY_STRING} [L]

    • If putting the rule in a VirtualHost directive, try adding the relative path to the shop (e.g. “/” or “/shop/”) before index.php in the last line of the Rewrite Rule and restart the webserver. Depending on your version of Apache, that may fix things!

      For example, the line may end up looking as follows:

      RewriteRule .* /shop/index.php?%{QUERY_STRING} [L]

    If trying the above doesn't help, then, this kind of issue is something that is outside the scope of this documentation. There are plenty of guides to be found on the internet on how to configure a server properly for Rewrite handling.

    Please Note: If you attempt to contact Ceon directly about any such issues you may be required to pay for any support given, as outlined in the support documentation.

    Back to top

  4. When Ceon URI Mapping is enabled images stop appearing on the site!

    Ceon URI Mapping enables a site to use static URIs.

    For a site to work with static URIs, all paths on the site must be relative to the site's root, NOT to the current page!

    These are often known as “absolute” paths.

    The site's root is “/”. E.g. http://storesite.com/.

    There are several things that can be done to make sure this happens.

    • First off, make sure that the site has a <base href="http://storesite.com/" /> tag set in the Zen Cart header file.

    • This tag must come before any tags that load in CSS or JavaScript files.

    • The tag is normally added by Zen Cart to the file includes/templates/template_default/common/html_header.php.

    • If the store uses a custom template, it may be using a file includes/templates/STORE-TEMPLATE/common/html_header.php.

    • Make sure that the <base href="... tag is present in which of these files the store uses - unfortunately some template creators, unprofessionally, accidentally leave out this essential tag.

    If that doesn't fix things, then individual paths may need to be changed from relative paths to absolute paths.

    • Use paths that go right from the root to their final file.

      For example, instead of a CSS file using a relative link to an image like:

      url(../images/some-image-name.png)

      Use a full, absolute path such as:

      url(/includes/templates/STORE-TEMPLATE/images/some-image-name.png)

    Back to top

  5. When Ceon URI Mapping is enabled the site's layout is messed up!

    This is the same issue that is covered in this FAQ.

    Back to top

  6. When Ceon URI Mapping is enabled a module on the site doesn't work properly! (E.g. Dynamic menus/popups etc. stop working)

    This is quite likely to be a similar issue to that covered in this FAQ.

    Try reading and applying what is mentioned in that FAQ first.

    If the information in that FAQ doesn't enable you to fix things:

    • If the module uses JavaScript/AJAX, check any JavaScript to make sure that it isn't expecting the current page's URI always to be the root of the store (e.g. http://storesite.com/shop/).
    • As static URIs appear to be like “subfolders” to modules written using JavaScript, the module may need to be recoded to work with static URIs.
    • This can be done by having paths within the software built from the root of the store and not relative to the current “subfolder” on the site, as static URIs break the idea of a site having folders in the URI.

    If that doesn't enable you to fix things:

    • Check the module's code to see if it uses the $_SERVER['REQUEST_URI'] variable.
    • As the use of static URIs means that the Zen Cart query string parameters are no longer present in $_SERVER['REQUEST_URI'], any code which checks against them in this variable will fail, and therefore needs to be rewritten to work with a Zen Cart that uses static URIs.
    • For example, if the code used a test such as:

      strstr($_SERVER['REQUEST_URI'], 'create_account')

      It could be changed to:

      $_GET['main_page'] == 'create_account'

    If none of the above helps, then, this kind of issue is something that is outside the scope of this documentation.

    Please Note: If you attempt to contact Ceon directly about any such issues you may be required to pay for any support given, as outlined in the support documentation.

    Back to top

  7. When the rewrite rule for Ceon URI Mapping is added, some file types on the site are blocked or showing up as 404s!

    Information about preventing problems with Ceon URI Mapping “blocking” certain file types can found in the configuration documentation.

    Back to top

  8. A session parameter (like “?zenid=XXXX”) is being added to the end of the store's URIs.

    Zen Cart adds a session ID to the end of all links on the very first page that a user visits.

    This is because when the user first arrives, no cookie has been set in their browser, so Zen Cart must assume that cookies are not enabled, and therefore it adds something like “?zenid=XXXX” to the end of all the links/URIs on the first page visited.

    There is no way to avoid this; however it is not a problem!

    Ceon URI Mapping has full Canonical URI support built in, so the search engines don't see the “?zenid=XXXX” bit at all and the site is not penalised in any way.

    It may not look as nice as you'd like but it only appears for the first page and, as has just been said this is unavoidable - just ignore it!

    Back to top

  9. A string beginning with “?cPath” is being added to the end of a product's URI.

    The module retains Zen Cart's category history when linking to a linked product which is not within its “master” category, so the full path back through any parent categories is available. To do so, it is essential that the “cpath” query string parameter is added to the URI.

    Without this feature all linked products would always show as belonging to their “master” category, which will not be the category the customer has accessed the product from.. this would make it appear to the customer that they had “jumped” to another part of the site, they would no longer be in the same category they were in previously!

    There is no way to avoid the cPath parameter being added for linked products. It's advised to use linked products only when necessary and/or to simply accept that it's not possible in Zen Cart to omit the cPath parameter in the URI of linked products.

    Back to top

  10. After adding the rewrite rule access to part of the site (e.g. the site's control panel) is being blocked.

    Information about adding exceptions to the rewrite rule - and therefore restoring access to particular addresses on/sections of the site - can be found in the configuration documentation.

    Back to top

  11. Some of the core files have already been modified for the site. How can the Ceon URI Mapping code be added?

    Each change in the core files required for the Ceon URI Mapping module to work is clearly marked in the sample versions of the files.

    Changes begin with a comment such as:

    // BEGIN CEON URI MAPPING 1 of x

    And end with a comment such as:

    // END CEON URI MAPPING 1 of x

    Where ‘x’ is the number of code changes within the current file which must be included for the Ceon URI Mapping module to use that file correctly.

    • Each change should be copied and pasted into the modified core file at the exact same place it is present within the respective sample file.
    • Using a “diff” software package, such as the free WinMerge software or the excellent, commercial, Beyond Compare software, makes this considerably easier to do without mistakes.

    Back to top

  12. Some of the template files for the site have already been modified. How can the Ceon URI Mapping code be added?

    The changes to the template files, which are required for static URIs to be able to be used by some of the standard Zen Cart sideboxes and by the product listing filter forms, are clearly marked in the sample versions of the files.

    Changes begin with a comment such as:

    // BEGIN CEON URI MAPPING 1 of x

    And end with a comment:

    // END CEON URI MAPPING 1 of x

    Where ‘x’ is the number of code changes within the current file which must be included for the Ceon URI Mapping module to use that file correctly.

    • Each change should be copied and pasted into the modified template file at the exact same place it is present within the respective sample file.
    • Using a “diff” software package, such as the free WinMerge software or the excellent, commercial, Beyond Compare software, makes this considerably easier to do without mistakes.

    Back to top

  13. The software is installed abut there is no “Ceon URI Mapping (SEO)” option in the store's “Configuration” menu.

    It essential that there is a section in the “Configuration” menu of the store's Zen Cart admin called “Ceon URI Mapping (SEO)”.

    If this configuration group and option is missing Ceon URI Mapping will show and work within the Zen Cart admin but will not be enabled in the store - standard Zen Cart dynamic URIs will be used!

    For some reason, some servers fail to add the configuration group and option when installing Ceon URI Mapping.

    This can hopefully be fixed by the following...

    • Go to Modules > Ceon URI Mapping (SEO) Config in the Zen Cart Admin.

    • Then go to the Installation Check tab and click on the link to open the Installation Check utility page.

    • The module will now automatically carry out the installation check.

    • If any errors are listed, follow the instructions given by the software.

    • Now go back to Modules > Ceon URI Mapping (SEO) Config in the Zen Cart Admin.

    • Go back to the Installation Check tab and click on the link to run the configuration checker.

    • If any problems are found with the configuration, the software should hopefully be able to fix the problems.

    If this does not fix things then there is simply something wrong with the server/site itself.

    Back to top

  14. When installing/upgrading the software there is no menu item called “Ceon URI Mapping (SEO) Config” in the “Modules” menu of the store's Zen Cart admin.

    The additional file(s) to add the link to the Ceon URI Mapping Config Utility to the store admin's modules menu must have accidentally been missed when installing/upgrading the software.

    • Copy the file(s) missed out originally. Click here for more information on what file(s) should be copied.

    Back to top

  15. Can we distribute this distribution to our clients?

    Yes, the software is GPL. However, the documentation in this distribution is copyrighted to Ceon and must not be distributed in a modified form without our express permission.

    As long as the documentation isn't modified, it can be freely distributed along with the software.

    If you'd like to modify the documentation, for example by branding it with your company logo, please contact us for permission! A credit acknowledgement to Ceon and JKED will always be required.

    Back to top

  16. How can I help with the module?

    If you have any feedback or a bug report, please send it to us! There's nothing that makes developing more rewarding than feeling that it is appreciated!

    • Donate by Credit/Debit Card or PayPal.  We accept Visa, MasterCard, Maestro, American Express, Visa Debit, Visa Electron & MasterCard Debit!This module has taken over 14 weeks of work, with none of the time taken being paid for by anyone, so if you find it useful, please support us - just click the donate button.

      We'll have more time to keep this contribution up-to-date and to support those who need our help if some nice people donate.

      Fewer than 1 in 500 people donate towards our software, so it would be greatly appreciated - Thanks!

Back to top