CV3 URL Redirects

From NewHaven Software Wiki

Jump to: navigation, search

Contents

Overview

This article discusses URL redirects in general, some reasons why you may need or want to use them, and how to import them into your CV3-hosted website.


Why redirect?

A redirect is an instruction for the web server to send a user to a different location than the one they originally requested (for instance, the user types www.mydomain.com/specials and is actually sent to www.mydomain.com/category/current-specials). There are several reasons why you may want to do this:

  • Like the example above, you may want a simplified link to send out in email blasts or post online.
  • If you rename a category or product so its page link changes, a redirect ensures that any search engine or other external links pointing to the original page will still go to the intended destination.
  • If you are moving your site from another hosting platform and the link structure changes (i.e., your old site had category pages as /<categoryname>.php while CV3 would be /category/<categoryname>), redirects ensure that existing links will still work (just as for moved/renamed pages above).


Adding redirects to CV3 sites

You can easily import a list of redirects to your CV3 website using a text file.

URI redirect import files are plain text files (pipe-, comma-, or tab-delimited) that contain two or three columns (the third is optional). The first is the "from" URL, which should be a relative path from your domain (meaning "/page/123" rather than "www.domain.com/page/123"). The second is the "to" URL, which can be either a relative path as the "from" URL or a complete URL to another domain. Either one of these can include a query string (for "/product/123?promo=foo", "?promo=foo" is the query string). The web server is case-sensitive, so you'll need to make sure the upper/lower case letters match for both URLs.

Generally allowed characters are: A-Z (upper- and lower-case), 0-9, "+", "-", "_", "/", "%", "!", ".", "&", "?", "=", "#". If your URLs contain any characters not shown here, they will need to be escaped; please contact our [Support Team] for assistance.

Example import file

"/contact","/about_us","n"
"/product_123","/product/123","n"
"/external_site","http://www.domain.com","n"
"/display?pid=123","/product/123","y"
"/promo_one","/?p=one","n"
"/Blog","/blog","n"

If your original URI is "/customer service" with a space, replace the space with a plus +

"/customer+service","/customer_service"

Importing the file

To import the file in your CV3 admin, follow these steps:

  1. Open Settings->URI Redirects.
  2. Browse for the file you created above.
  3. Select the Type based on how you created the file (text files from Excel are generally Comma-delimited).
  4. Enter your email address to be notified when the import is complete.
  5. Check the replace current redirects box if you want to wipe out all current redirects and replace them with the ones in the file. If you do not do this, they will be added instead.
  6. Submit the form. You will receive an email when the import has been processed.


Re-running the import

Redirects expire 30 days after they are imported (this is to ensure that old, unused redirects don't linger on the server for years clogging up resources). If you want to keep your redirects active for a longer period, set a calendar reminder to re-run the same import file on a regular schedule (you can add to the file over time if needed, of course).

For major changes like renaming a category/product page link or moving to a new platform with a different URL structure, you should probably maintain the redirects for 6-12 months.

Personal tools