PHP CSV Redirects Module - CSV

Used to add redirects to the 404 page

How to use

  • A single content item is added to the 404 section, this is always a child section of the route of a channel called 404 e.g., for the main Middlesex website MDXUK » 404
  • Select the Terminalfour PHP CSV Redirect PHAR file from the Media Library (this has been uploaded to folder Categorised > mdx.ac.uk> Site Assets > T4 Modules > CSV Redirects) media ID: 12202
  • Upload a CSV File. The file must be a CSV and have the old URL in column 1 and new URL in column 2.
  • Check the Ignore Query element for query strings to be ignored
  • Check the Exact Match element to redirect only if an exact match is found, if unchecked a redirect will trigger if URL matches a From URL 85% 

Find further guidance on the T4 Redirect Module in the T4 documentation.

Content Type Details

ID: 495
Name: PHP CSV Redirects Module - CSV
Description: PHP code need for the redirects using a CSV
Minimum user level: Administrator

Content Type Elements Details

NameDescriptionSizeTypeRequired
NameThe Name element80 CharactersPlain TextYes
Main LibraryLink to the Main Library PHP File N/AMediaYes
CSV FileSelect CSV file with first column the URL that needs to redirect and second column the URL that redirect has to goN/AFileYes
Ignore QueryIn the From URL always ignore the variable passed via queryN/ACheck Box
(List: Yes - Unchecked)
No
Exact MatchIf selected it will always redirect only if an exact match, otherwise it will check if the From URL is 85% close the list of URL providedN/ACheck Box
(List: Yes - Unchecked)
No