How can I develop a new theme in WordPress without disrupting the current site
Clash Royale CLAN TAG#URR8PPP
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty margin-bottom:0;
up vote
1
down vote
favorite
I am working on updating our current website and would like to build a new theme without disturbing the current site. How should I go about doing this? Can I just add the theme and then not make it active until I'm ready?
themes
New contributor
add a comment |Â
up vote
1
down vote
favorite
I am working on updating our current website and would like to build a new theme without disturbing the current site. How should I go about doing this? Can I just add the theme and then not make it active until I'm ready?
themes
New contributor
1
Have you already tried to research the problem or you seek for a free guidance?
â Max Yudin
38 mins ago
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I am working on updating our current website and would like to build a new theme without disturbing the current site. How should I go about doing this? Can I just add the theme and then not make it active until I'm ready?
themes
New contributor
I am working on updating our current website and would like to build a new theme without disturbing the current site. How should I go about doing this? Can I just add the theme and then not make it active until I'm ready?
themes
themes
New contributor
New contributor
New contributor
asked 1 hour ago
Alex Eichenmuller
91
91
New contributor
New contributor
1
Have you already tried to research the problem or you seek for a free guidance?
â Max Yudin
38 mins ago
add a comment |Â
1
Have you already tried to research the problem or you seek for a free guidance?
â Max Yudin
38 mins ago
1
1
Have you already tried to research the problem or you seek for a free guidance?
â Max Yudin
38 mins ago
Have you already tried to research the problem or you seek for a free guidance?
â Max Yudin
38 mins ago
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
3
down vote
There are a couple of options.
One: there are plugins that will let just certain logged-in users see the site in a different theme. You could use one of these and enable the new theme for yourself until you're ready to make the switch.
Two: copy your site onto a staging site and experiment there. The biggest potential downside is that if the theme has any settings, you'll have to go make those on the live site when you're ready to make the switch. However, if your theme has a lot of settings, this may be your only option - you'll have to look at the plugins and see whether they allow you to configure multiple themes.
add a comment |Â
up vote
0
down vote
You can use the pre_option_stylesheet
filter to dynamically change the stylesheet. In the following example, I show the default stylesheet selected on WordPress admin to regular users and a different theme with the slug my-new-theme
to users with the activate_plugins
capability.
/*
* Plugin Name: WPSE Theme Switch Example
* Description: Show `my-new-theme` to users with the `activate_plugins` capability.
* Required PHP: 5.4
*/
namespace StackExchangeWordPress;
class stylesheet
protected $theme = 'my-new-theme';
public function get_theme( $theme )
return $this->show_new_theme() ? $this->theme : $theme;
protected function show_new_theme()
return ! is_admin() && current_user_can( 'activate_plugins' );
add_filter( 'pre_option_stylesheet', [ new stylesheet(), 'get_theme' ] );
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
3
down vote
There are a couple of options.
One: there are plugins that will let just certain logged-in users see the site in a different theme. You could use one of these and enable the new theme for yourself until you're ready to make the switch.
Two: copy your site onto a staging site and experiment there. The biggest potential downside is that if the theme has any settings, you'll have to go make those on the live site when you're ready to make the switch. However, if your theme has a lot of settings, this may be your only option - you'll have to look at the plugins and see whether they allow you to configure multiple themes.
add a comment |Â
up vote
3
down vote
There are a couple of options.
One: there are plugins that will let just certain logged-in users see the site in a different theme. You could use one of these and enable the new theme for yourself until you're ready to make the switch.
Two: copy your site onto a staging site and experiment there. The biggest potential downside is that if the theme has any settings, you'll have to go make those on the live site when you're ready to make the switch. However, if your theme has a lot of settings, this may be your only option - you'll have to look at the plugins and see whether they allow you to configure multiple themes.
add a comment |Â
up vote
3
down vote
up vote
3
down vote
There are a couple of options.
One: there are plugins that will let just certain logged-in users see the site in a different theme. You could use one of these and enable the new theme for yourself until you're ready to make the switch.
Two: copy your site onto a staging site and experiment there. The biggest potential downside is that if the theme has any settings, you'll have to go make those on the live site when you're ready to make the switch. However, if your theme has a lot of settings, this may be your only option - you'll have to look at the plugins and see whether they allow you to configure multiple themes.
There are a couple of options.
One: there are plugins that will let just certain logged-in users see the site in a different theme. You could use one of these and enable the new theme for yourself until you're ready to make the switch.
Two: copy your site onto a staging site and experiment there. The biggest potential downside is that if the theme has any settings, you'll have to go make those on the live site when you're ready to make the switch. However, if your theme has a lot of settings, this may be your only option - you'll have to look at the plugins and see whether they allow you to configure multiple themes.
answered 44 mins ago
WebElaine
4,5301512
4,5301512
add a comment |Â
add a comment |Â
up vote
0
down vote
You can use the pre_option_stylesheet
filter to dynamically change the stylesheet. In the following example, I show the default stylesheet selected on WordPress admin to regular users and a different theme with the slug my-new-theme
to users with the activate_plugins
capability.
/*
* Plugin Name: WPSE Theme Switch Example
* Description: Show `my-new-theme` to users with the `activate_plugins` capability.
* Required PHP: 5.4
*/
namespace StackExchangeWordPress;
class stylesheet
protected $theme = 'my-new-theme';
public function get_theme( $theme )
return $this->show_new_theme() ? $this->theme : $theme;
protected function show_new_theme()
return ! is_admin() && current_user_can( 'activate_plugins' );
add_filter( 'pre_option_stylesheet', [ new stylesheet(), 'get_theme' ] );
add a comment |Â
up vote
0
down vote
You can use the pre_option_stylesheet
filter to dynamically change the stylesheet. In the following example, I show the default stylesheet selected on WordPress admin to regular users and a different theme with the slug my-new-theme
to users with the activate_plugins
capability.
/*
* Plugin Name: WPSE Theme Switch Example
* Description: Show `my-new-theme` to users with the `activate_plugins` capability.
* Required PHP: 5.4
*/
namespace StackExchangeWordPress;
class stylesheet
protected $theme = 'my-new-theme';
public function get_theme( $theme )
return $this->show_new_theme() ? $this->theme : $theme;
protected function show_new_theme()
return ! is_admin() && current_user_can( 'activate_plugins' );
add_filter( 'pre_option_stylesheet', [ new stylesheet(), 'get_theme' ] );
add a comment |Â
up vote
0
down vote
up vote
0
down vote
You can use the pre_option_stylesheet
filter to dynamically change the stylesheet. In the following example, I show the default stylesheet selected on WordPress admin to regular users and a different theme with the slug my-new-theme
to users with the activate_plugins
capability.
/*
* Plugin Name: WPSE Theme Switch Example
* Description: Show `my-new-theme` to users with the `activate_plugins` capability.
* Required PHP: 5.4
*/
namespace StackExchangeWordPress;
class stylesheet
protected $theme = 'my-new-theme';
public function get_theme( $theme )
return $this->show_new_theme() ? $this->theme : $theme;
protected function show_new_theme()
return ! is_admin() && current_user_can( 'activate_plugins' );
add_filter( 'pre_option_stylesheet', [ new stylesheet(), 'get_theme' ] );
You can use the pre_option_stylesheet
filter to dynamically change the stylesheet. In the following example, I show the default stylesheet selected on WordPress admin to regular users and a different theme with the slug my-new-theme
to users with the activate_plugins
capability.
/*
* Plugin Name: WPSE Theme Switch Example
* Description: Show `my-new-theme` to users with the `activate_plugins` capability.
* Required PHP: 5.4
*/
namespace StackExchangeWordPress;
class stylesheet
protected $theme = 'my-new-theme';
public function get_theme( $theme )
return $this->show_new_theme() ? $this->theme : $theme;
protected function show_new_theme()
return ! is_admin() && current_user_can( 'activate_plugins' );
add_filter( 'pre_option_stylesheet', [ new stylesheet(), 'get_theme' ] );
answered 48 secs ago
Nathan Johnson
4,76841036
4,76841036
add a comment |Â
add a comment |Â
Alex Eichenmuller is a new contributor. Be nice, and check out our Code of Conduct.
Alex Eichenmuller is a new contributor. Be nice, and check out our Code of Conduct.
Alex Eichenmuller is a new contributor. Be nice, and check out our Code of Conduct.
Alex Eichenmuller is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fwordpress.stackexchange.com%2fquestions%2f316939%2fhow-can-i-develop-a-new-theme-in-wordpress-without-disrupting-the-current-site%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
1
Have you already tried to research the problem or you seek for a free guidance?
â Max Yudin
38 mins ago