Download the PHP package tlovett1/safe-redirect-manager without Composer

On this page you can find all versions of the php package tlovett1/safe-redirect-manager. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package safe-redirect-manager

Safe Redirect Manager

A WordPress plugin to safely and easily manage your website's HTTP redirects.

Purpose

Easily and safely manage your site's redirects the WordPress way. There are many redirect plugins available. Most of them store redirects in the options table or in custom tables. Most of them provide tons of unnecessary options. Some of them have serious performance implications (404 error logging). Safe Redirect Manager stores redirects as Custom Post Types. This makes your data portable and your website scalable. Safe Redirect Manager is built to handle enterprise level traffic and is used on major publishing websites. The plugin comes with only what you need following the WordPress mantra, decisions not options. Actions and filters make the plugin very extensible.

Installation

Install the plugin in WordPress. You can download a zip via GitHub and upload it using the WordPress plugin uploader ("Plugins" > "Add New" > "Upload Plugin").

Configuration

There are no overarching settings for this plugin. To manage redirects, navigate to the administration panel ("Tools" > "Safe Redirect Manager").

Each redirect contains a few fields that you can utilize:

"Redirect From"

This should be a path relative to the root of your WordPress installation. When someone visits your site with a path that matches this one, a redirect will occur. If your site is located at http://example.com/wp/ and you wanted to redirect http://example.com/wp/about to http://example.com, your "Redirect From" would be /about.

Clicking the "Enable Regex" checkbox allows you to use regular expressions in your path. There are many great tutorials on regular expressions.

You can also use wildcards in your "Redirect From" paths. By adding an * at the end of a URL, your redirect will match any request that starts with your "Redirect From". Wildcards support replacements. This means if you have a wildcard in your from path that matches a string, you can have that string replace a wildcard character in your "Redirect To" path. For example, if your "Redirect From" is /test/*, your "Redirect To" is http://google.com/*, and the requested path is /test/string, the user would be redirect to http://google.com/string.

"Redirect To"

This should be a path (i.e. /test) or a URL (i.e. http://example.com/wp/test). If a requested path matches "Redirect From", they will be redirected here. "Redirect To" supports wildcard and regular expression replacements.

"HTTP Status Code"

HTTP status codes are numbers that contain information about a request (i.e. whether it was successful, unauthorized, not found, etc). You should almost always use either 302 (temporarily moved) or 301 (permanently moved).

Note:

Filters

Default redirect status code

The default redirect HTTP status code can be changed using the srm_default_direct_status filter.

Redirect loops detection

By default redirect loop detection is disabled. To prevent redirect loops you can filter srm_check_for_possible_redirect_loops.

Only redirect if 404 occurs

By default every matched URL is redirected. To only redirect matched but not found URLs (i.e., 404 pages), use srm_redirect_only_on_404.

CLI commands

The following WP-CLI commands are supported by Safe Redirect Manager:

Development

Setup

Follow the configuration instructions above to setup the plugin. We recommend developing the plugin locally in an environment such as WP Local Docker.

Testing

Within the terminal change directories to the plugin folder. Initialize your unit testing environment by running the following command:

Run the plugin tests:

Issues

If you identify any errors or have an idea for improving the plugin, please open an issue.

Translations

Safe Redirect Manager is available in English and other languages. A listing of those languages and instructions for translating the plugin into other languages is available on Translating WordPress. Many thanks to the contributors on the translation teams!

Support Level

Stable: 10up is not planning to develop any new features for this, but will still respond to bug reports and security concerns. We welcome PRs, but any that include new features should be small and easy to integrate and should not include breaking changes. We otherwise intend to keep this tested up to the most recent version of WordPress.

Changelog

A complete listing of all notable changes to Safe Redirect Manager are documented in CHANGELOG.md.

Contributing

Please read CODE_OF_CONDUCT.md for details on our code of conduct, CONTRIBUTING.md for details on the process for submitting pull requests to us, and CREDITS.md for a listing of maintainers of, contributors to, and libraries used by Safe Redirect Manager.

Like what you see?


All versions of safe-redirect-manager with dependencies

PHP Build Version
Package Version
No informations.
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package tlovett1/safe-redirect-manager contains the following files

Loading the files please wait ....