natansdj/wp-stage-switcher

This package is abandoned and no longer maintained. No replacement package was suggested.

WordPress plugin that allows you to switch between different environments from the admin bar

Maintainers

Package info

github.com/natansdj/wp-stage-switcher

Homepage

Issues

Forum

Type:wordpress-plugin

pkg:composer/natansdj/wp-stage-switcher

Statistics

Installs: 13

Dependents: 0

Suggesters: 0

Stars: 0

1.0.4 2016-01-05 05:19 UTC

This package is auto-updated.

Last update: 2023-03-22 21:32:58 UTC


README

A WordPress plugin that allows you to switch between different environments from the admin bar.

WordPress Stage Switcher

Fixed bug on hosts url

Requirements

You'll need to have ENVIRONMENTS and WP_ENV defined in your WordPress config.

The ENVIRONMENTS constant must be a serialized array of 'environment' => 'url' elements:

$envs = array(
  'development' => 'http://example.dev',
  'staging'     => 'http://staging.example.com',
  'production'  => 'http://example.com'
);
define('ENVIRONMENTS', serialize($envs));

WP_ENV must be defined as the current environment:

define('WP_ENV', 'development');

If you use Bedrock, WP_ENV is already defined in the config.

Installation

If you're using Composer to manage WordPress, add wp-stage-switcher to your project's dependencies. Run:

composer require natansdj/wp-stage-switcher 1.0.4

Or manually add it to your composer.json:

"require": {
  "php": ">=5.3.0",
  "wordpress": "3.9.2",
  "natansdj/wp-stage-switcher": "1.0.4"
}

Support

Use the Roots Discourse to ask questions and get support.