Ever wanted to test or tweak an alternate Theme for WordPress, but don't want things to look messy for your visitors ? You have two solutions.
Another Test install
That's an easy one, just set up another WordPress blog and play with it, tweak it, break it, no once cares. The only thing you may want to check before playing is that it sends no ping (Options / Writing / Update Services) and no trackback (Options / Discussion) when you post random junk, because your test install will soon be discovered by others … and by spammers :)
Use the Theme Switcher
This solution doesn't even require you to set up another blog. It consists in installing a Theme Switcher, and making it available for you only.
- Get the plugin : theme switcher
- Activate it
- Add the following code somewhere in your sidebar.php :
- <?php
- if (
- (preg_match("/wordpressuser[^=]*=admin/i", $_SERVER["HTTP_COOKIE"]))
- ) { ?>
- <div id="themeswitcher">
- <h3>Theme</h3>
- <?php wp_theme_switcher(); ?>
- </div>
- <?php } ?>
From now on, people logged in with "admin" will be able to see the theme switcher and select another theme. Others will stick to the theme selected by default.
Shorter URL
Want to share or tweet this post? Please use this short URL: http://ozh.in/8a
there was a mess around?
Yes, pendant quasi five secondes.