redirectoid 1.0.0-beta1

redirectoid 1.0.0-beta1

Released Feb 11, 2013 by sepiariver

A simple snippet that redirects to any Resource specified by ID, or a random child of a specified parent(s).

Redirectoid supports various response codes described here:

It also exposes the arguments for the $modx->makeUrl() method for further customization.

Thanks for using MODx Revolution.

This version is deprecated. It is recommended to use a newer version.

Download 9kb (849 downloads)
Downloads: 3,468
License: GPLv2
Requires Revolution 2.2.x or greater
Compatible up to Revolution 2.2.x
Supports mysql

Initial beta release.

Installation Instructions

Simply call the snippet like this: [[Redirectoid]]

Requests to that page will be redirected to the site_start. Optionally provide an ID and response code:

[[Redirectoid? &id=`3` &responseCode=`307`]]

This will redirect the page with the snippet call to the Resource with ID 3, sending a Redirect Status Code of "307 Temporary Redirect".

It comes in really handy when you use Resources as slide items, or items in other listings, where you want the Resource to be published, but don't really want people visiting the Resource directly. Just add this snippet to the content field or perhaps a blank "Item Template" with a redirect to the parent ID that actually displays the styled content, like this:

[[Redirectoid? id=`[[*parent]]`]]

Tested in 2.2.6 but should work in any version that includes the modX.sendRedirect class.

Version Released Author Downloads
4 Versions 1 Contributors 3,472 Downloads
2.1.0-rc1 Aug, 20 2016 sepiariver 1,086
2.0.0-pl1 Jul, 21 2014 sepiariver 347
2.0.1-pl1 Jul, 20 2014 sepiariver 1,191