Marketpath CMS Developer Tutorial Series


Last Updated 3/6/2018

Under most circumstances, it is easy for redirects to take a back-seat to your development efforts. Sometimes you want just a little bit more out of your sites, though, and redirects can help you get there.

Auto-generated redirects

Most of the redirects on your site are likely to be redirects created automatically when someone changes the URL of a page. This is a good thing. It prevents old links from breaking and keeps everything running smoothly. Consider the impact on "legacy" URLs before deleting these. If the page was never published then there is no impact - go ahead and delete it.

Manual redirects

Manual redirects are easy to create and can be helpful - particularly when migrating from an old site to a new site.

To create a manual redirect:

  1. Go to Site -> Redirects and click "New".
  2. The first choice you will be faced with is whether or not to use a Regex redirect. As a general guideline, if you do not need a regex redirect, do not use one. In practice this means that if you are simply redirecting one URL to another, don't use it, but if you want to redirect multiple URLs at once then you should use regex.
  3. If you are NOT using regex:
    1. the Origin will simply be the full URL to redirect from - starting with the // (eg: for "" the origin would be "//")
    2. The Destination will be the page to redirect to. If you decide to redirect to a URI instead of a page, you may enter any value here that would be valid in a HTTP redirect response.
  4. If you ARE using regex:
    1. The Origin will be the URL to match. You can use advanced regex concepts such as capturing groups and backreferences, but you must enter a valid regular expression.
    2. The Destination will the URL to redirect to. You may use substitutions as defined by your Origin regular expression.
  5. If "Is Permanent" is checked, all redirects processed using this record (which would only be one redirect if you did not use a regex) will be 301 (permanent) redirects. If it is not checked they will be 302 (temporary) redirects.
  6. The notes are purely for your benefit. If you did something crazy with a regex redirect you might take advantage of the Notes to explain what you did in case you or someone else needs to troubleshoot it later.

Note that whether a redirect is automatically generated, is a simple manual redirect, or a manual regex redirect, Marketpath CMS will always return a matching published page at the given URL if it exists and will only process redirects if it fails to find a published page.

---- End of Lesson ----

Question? Correction?

Let's work together to make our documentation as helpful as possible.

What is your name? 
What is your email address?