A WordPress theme for all
Thursday, June 4, 2009 Under the title of the blog, on the left, just above the navigation bar, there is a switch that allows you to switch to an alternative graphical theme, namely "clear".
The graphic theme of a blog is chosen by the owner of the blog itself, whether it is created by hand, whether it is downloaded from the network. The end result, however, in addition to "we" owners should be pleased by our visitors do not always appreciate certain choices of layout. For some it will be commonplace for another wonderful, for others still terribly annoying! Why, then, do not choose to "visit" the layout with which to view our blog?
Everything stems from the forces Emanuele propose a version of "clear" of undolog.com! How to blame him? However, if I followed his advice, I should do it with others and the consequence would be to find himself subject to change every week! Despite this you are "readers / visitors" to read the blog, so why not provide a tool that can make you sceggliere the best viewing possible? Along with other interesting perspectives ...
Also there are those who never ever fully satisfied with the subject that owns (see Napolux) and a tool like WP Choose Your Theme could partly solve the problem, ensuring a double navigating a new subject, or after trial, and the consolidated statements for the "loyal".
So I listened to Emanuele and I created a version of "clear" of this blog . I realized, for the occasion, a simple plugin that allows you to view the list of available themes and select them from the front-end of WordPress. In practice, visitors will choose how to display the Blog!
WP Choose Your Theme
WP Choose Your Theme for WordPress plugin is able to choose the theme to the visitor to use. The choice is stored via cookies and, in this version, maintained for a month. Its operation is very simple: install, activate, hide, through the configurations, the issues that we do not want our visitors to select and insert this line in "your templates, for example in the sidebar sidebar.php
- <h2> Choose a theme </ h2>
- ; ?> <? php wp_chooseyourtheme ();?>
The issues permits will be displayed in combo menu. When the visitor selects a theme, this will be stored in the cookie and page reloaded. In this release the plugin offers three viewing modes.
Parameters
The list of topics can be presented in three ways:
Combo Menu
- <h2> Choose a theme </ h2>
- ; ?> <? php wp_chooseyourtheme ();?>
- / / Or
- "mode=menu" ) ; ?> <? php wp_chooseyourtheme ( 'mode = menu ");?>
This generates an HTML:
- "wpcyt_combo" > <select class = "wpcyt_combo">
- <option> Theme name 1 </ option>
- <option> Theme name ... </ option>
List
- <h2> Choose a theme </ h2>
- "mode=list" ) ; ?> <? php wp_chooseyourtheme ( "mode = list");?>
This will generate a highly customizable HTML, as shown below:
- "wpcyt_list" > <ul class = "wpcyt_list">
The current theme is indicated by the addition of the class selected in the tag li Version combo menu the current theme is automatically selected in the list.
Roll
- Next <h2> theme </ h2>
- "mode=roll" ) ; ?> <? php wp_chooseyourtheme ( "mode = roll");?>
In this case creates a unique link that points to the issue next cycle made all the topics available:
Advantages and potential
As said earlier the main benefit it offers to set a theme browser that can surf over another. The greater the number of subjects available, the greater the ability to meet the diverse needs of our surfers. A theme, then, in WordPress, is not just a simple look and feel. In addition to "simple" layout, which includes the rendering graphics, colors, font type and placement of content, we add the capcha of WordPress can be customized in the vision of this content. With the introduction of suitable functions is in fact possible to add a different way to enjoy the blog that is not limited to mere change in appearance.
Disadvantages and warnings
All this obviously has a price, paid in full by the owner of the blog. At first sight it is clear that more subjects means greater burden in the maintenance of the Blog. Any addition made on an issue must necessarily be another riprosta: PayPal buttons, banners and all the elements that relieve the contents of the WordPress database. For example, the same plugin WP Choose Your Theme even if installed at the "global", requires the manual insertion of Education wp_chooseyourtheme() in the sidebar sidebar.php for example. If we have made available three issues, all three must be filled by education, or to change the theme you would not know how to reverse or select a different theme.
Moreover, as mentioned above, the use of cookies to inform the system that this particular user has chosen this particular topic, may conflict with some plugins. For example, I had some problems with WP Super Cache, not new to this type of issues. However, I think I solved it by editing the .htaccess Seek / lines:
- !^.* ( comment_author_|wordpress|wp-postpass_ ) .*$ RewriteCond% (HTTP: Cookie) ^ .* (comment_author_ | wordpress | wp-postpass_) .* $
and making changes in:
- !^.* ( comment_author_|wordpress|wp-postpass_|wpcyt_name ) .*$ RewriteCond% (HTTP: Cookie) ^ .* (comment_author_ | wordpress | wp-postpass_ | wpcyt_name) .* $
wpcyt_name is the name of the cookie used by WP Choose Your Theme













[...] Choose Your Theme is a WP Plugin for Wordpress in a position to choose the graphic theme to our visitors to use when navigating our blog. The origins of this project you can find in a WordPress theme for all. [...]
Excellent plugin!
For the problem of having to update all the issues every time, you could create alternate themes using child themes, is not it?
There are already plugins that do something like this theme switcher?
Ps
With some aggiustatina graphics would be perfect. 
A thousand times better than the clear theme, if I may
Congratulations for the attention shown to your users!

On the issue, as mentioned by Napolux, should correct a couple of things. I imagine it is still under process but for example the green buttons in the comments are ugly.
Another thing ... why not work with CSS instead of having to create a completely new template with a totally different path for the images (of course, some choices should be reviewed: see for example the button to send comments ...)?
Hello,
Emanuele
PS: I confirm that such plugin already exists!
@ Napolux:
Yes, there are already ... but better have it on their own
Then I hope that mine is better 
@ Napolux:
Recommends ... Recommends ...
@ Emmanuel: there would also be different solutions. However I have chosen the most brutal and redundant and acted effectively on all files of the theme. My goal, in fact, is not only to change the look and feel understood as colors and images, but also allow you to change the navigation, providing new templates, additional functions in file
functions.phpetc ...Pian paino, however, thanks to your suggestions, settle the details of the version "white" ...
Very nice this white version. I noticed that the bannerino Adsense, under tags, was black with greenish link
However, a good job, although I like much better version of black Undolog.
Hello
@ Sniper Wolf:
Yes, this happens because AdSense is an external service set outside the context of the topic. What should I do (time tyrant ...) and create a new AdSense for this topic ... will take care as soon as
@ Ghid:
Worth watching! Actually I have not mentioned the Child Theme for WordPress because they are too little known and little used, at least by the vast majority to non-technical bloggers. Often, it is easier (and is also known to be the most) install different themes, then separated into physical folders.
However you say is entirely justified and Child Theme would be the best solution for those who want to create a variation of your theme using the theme of inheritance with his father. Topic on which one could discuss shortly ...
Giovambattista, not to listen Emanuele all times, is one who is waging a battle around the entire blogosphere to remove the themes blacks. Joking aside, this version is really pretty clear and more readable. In my part of the theme changes once a month, but if you told me you were working on a plugin I waited! Failing that, I added a little 'controls and functions within my theme, to do something similar to yours. In my case I have 12 themes, one for each month. Plus 2 high contrast: light and dark. The user can choose which one to use, as I explained recently in my article. I have not made it easy to change because I would like however the majority continued to use what I choose, at the bottom are the landlord, no?
@ camu:
how to give you wrong ...
Camu ahaha! It is elegance!

Topics blacks saw them well 10 years ago!
Hello,
Emanuele
[...] A WordPress theme for all WP Choose Your Theme, a plugin was created specifically to enable the visitor to choose which theme to show on your blog. [...]
[...] A WordPress theme for all [...]
[...] 4) A WordPress theme for all [...]
With Safari 4 does not act as the switch of the theme ... could be a problem with Javascript
Salerno @ David: Yes, Safari has an abnormal behavior, on both Mac and Windows. Could be due to the internal cache of Safari. On the Mac, the change of the theme I worked, but intermittently. Investigate ... (Safari on Windows has gone even crash)
[...] Choose Your Theme is a WP Plugin for Wordpress in a position to choose the graphic theme to our visitors to use when navigating our blog. The origins of this project you can find in a WordPress theme for all. [...]