[1.6] Conditional theme options
Posted: Mon Jan 10, 2011 1:21 am
Okay, so here's another crazy idea: conditional theme options, i.e. in plain text "if theme option A is value X, enable theme option B".
Example use: I might include a theme option to use either a fixed or fluid width layout. Now, if the user opts for the fluid layout, it makes sense to use a max-width for the main container, which doesn't make much sense if the layout has fixed width. It also makes perfect sense to let the user choose a max-width, i.e. if he selects the fluid width, the template could display a set of radio buttons to choose between a max-width of, say, 1024px, 1280px or 1600px.
This would also help to keep the theme options page tidy if template authors offer a lot of theme options. Maybe this concept could also be used for plugin configuration?
YL
Example use: I might include a theme option to use either a fixed or fluid width layout. Now, if the user opts for the fluid layout, it makes sense to use a max-width for the main container, which doesn't make much sense if the layout has fixed width. It also makes perfect sense to let the user choose a max-width, i.e. if he selects the fluid width, the template could display a set of radio buttons to choose between a max-width of, say, 1024px, 1280px or 1600px.
This would also help to keep the theme options page tidy if template authors offer a lot of theme options. Maybe this concept could also be used for plugin configuration?
YL