WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to set up theme options so they save with AJAX, I found this tutorial http://return-true.com/2010/01/using-ajax-in-your-wordpress-theme-admin/

it's calling

$options = get_option('test_theme');

but I don't understand what that is returning. it calls this right before the form, presumably to loop through the options? the data is actually getting saved, it's just not being represented when the page is refreshed.

share|improve this question
up vote 1 down vote accepted

This sets $options to the value of test_theme in the database, you can go to phpmyadmin and the wp database and the wp_options (if wp is your prefix) and do a search on option_id row and you'll find it there.

To get this option it should be saved before in the database using add_option() and update_option(), for more info check out the Options API

share|improve this answer

Your Answer


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.