About Theme options

Hello,

Hope this finds you well and safe.

I am on my way to a 2nd WordPress theme, currently under development. First theme went quiet smoothly but I feel like I’m missing something in my demo. The Ability to showcase multiple options of for example a header

I am using Redux Framework for my themes, and as you might know the data is stored in an object and is theme wide (As far as i know) and an option will apply to all pages. So my question is:
How can I showcase multiple Header styles (Changed from theme options) on my frontend while using the same WordPress installation.

My bets are as follows:

  1. Create a network, and hold a different site in each network with the different designs and theme options I want to showcase. (This becomes a mess really easy really fast when theme updates)
  2. Create page post meta fields that will override the theme options

So what’s the right way to do it? Any help would be phenomenal.

  1. Use GET parameters in your URL (make sure to properly escape them) to override your theme options.

Also, I would advise to not to use Theme Options but switch to a WP Customizer instead. It is becoming a standard, so don’t be stuck with outdated tech, or it will bite you in the a$$ sooner or later.

I do not remember how exactly Redux is managing options, but WP Customizer uses theme_mod table which is super easy to override via filters, so you will require just a little bit of code to actually pull this URL GET params stuff off.

1 Like

Redux fully supports Customizer already, all options that are registered in the WordPress admin, can be accessed from the Customizer.

GET parameters sounds like a promising option. However, one quick question regarding this matter:

Should or can this logic be implemented into the product itself, or should I implement this mechanism into my child theme on my demo preview using hooks and filters. (You know, for theme review purposes)

I did it via a child theme (which I use just for the live demo, not the one I bundle with the theme). No need to bloat your theme with this functionality.

Beast, thanks for your help! :slight_smile:

Cool portfolio BTW! Keep it up and you will be an elite in no time.

1 Like

Thanks! I will hold your word to it :smiley: