Stylesheet switcher
-
Hello,
I managed to add stylesheet theme options for my new theme, like this:
<select name="<?php echo $value['id']; ?>" id="<?php echo $value['id']; ?>"> <?php foreach ($value['options'] as $option) { ?> <option<?php if ( get_settings( $value['id'] ) == $option) { echo ' selected="selected"'; } elseif ($option == $value['std']) { echo ' selected="selected"'; } ?>><?php echo $option; ?></option> <?php } ?> </select>
Everything works fine inside the theme options page. But how can I add a theme switcher on the sidebar of the website, so users can select and change stylesheets for previewing purposes?
This menu works well on the website too, but I don’t know how to save the selected options and make the loaded stylesheet change.
Any ideas? Is it possible?
Thank you!
- The topic ‘Stylesheet switcher’ is closed to new replies.