change options for non-active theme in wp

by 2 replies
3
I know that theme options are stored in wp_options. I was assuming there would be a table for every theme or child theme and I could copy the data from the active theme to the other tables so that when I activated one of them they were ready to go (or mostly so). But there is only one 7 page table.

So where does the data from the options of the non active themes live?
#programming #change #nonactive #options #theme
  • Howdy,

    The options for each WordPress theme (both active and inactive) are all stored in wp_options.

    Each theme developer has his or her own method of storing and organizing their theme options. Some choose to use individual rows and others like myself store all of the theme options in a serialized array on one row. Hell some even shoddier developers may actually create their own table just for the options, so that adds to the multitude of possibilities involved with this.

    So the task you are attempting, at least via editing the DB will be a bit of a ballache as each theme has it's own way of storing it's options.

    An easier solution may be to setup each theme on a clean install of WP and then use the following plugin to take a clone of the DB, you can subsequently upload the package to each new site you deploy. Though this should be done before populating the new site with posts.

    WordPress › Duplicator « WordPress Plugins

    Hopefully that helps, but if you have any more questions feel free to ask them.
    • [ 1 ] Thanks
  • Some theme specific options are stored in the wp_options table, some themes store their options in theme-specific tables. It's a personal choice by the theme developer, and as opposed to the opinion of the prior commenter, the theme-specific option is a far superior way, not shoddy.

    There is no easy way to synchronize any theme specific settings from one to another, except perhaps if they happen to use the same labels for the same settings. You may see some commonality between different themes by the same author, but there is no rule unless a particular theme author decides on their own to do so.
    • [ 1 ] Thanks

Next Topics on Trending Feed

  • 3

    I know that theme options are stored in wp_options. I was assuming there would be a table for every theme or child theme and I could copy the data from the active theme to the other tables so that when I activated one of them they were ready to go (or mostly so). But there is only one 7 page table. So where does the data from the options of the non active themes live?