Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I do local WP development on a WordPress Multisite instance. What is the best way to move theme settings from there to the live instance? By theme settings I am talking about widgets and theme options.

share|improve this question

3 Answers 3

Answer 1 is not the best way... it's the old way.

The best solution going which I have found, and use regularly for moving site from local dev to live is at http://pluginbuddy.com/purchase/backupbuddy/. It backs up everything, including databases and plugins, and lets you restore a site or migrate an entire site to a new server. You don't even install WP on the new server because backup buddy does it all. A full migration from local to live takes about 10 minutes.

For being able to save your widget setup to each specific theme you have under a WP install the plugin at http://wordpress.org/extend/plugins/widget-saver/ is most excellent.

share|improve this answer

The best way would be to create an SQL export dump of your database for that site more spesificly the options table of the database.

share|improve this answer

I'm going to assume that you're doing things correctly, which means that you're using register_setting() to create a single, options-array DB entry.

Thus, assuming your Theme slug is mytheme, and your DB entry is named theme_mytheme_options, you simply need to export the following from wp_options:

  1. theme_mytheme_options
  2. theme_mods_mytheme

Export them from the development SQL server, and then import them into the production SQL server.

You could probably even write an exporter/importer for the process (maybe take a look at the WordPress importer Plugin as a reference?).

EDIT

MultiSite-specific: you'll need to know the ID of the network site. The table name should be in the format: {network}_{siteID}_options.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.