Tagged Questions
1
vote
1answer
32 views
How do I handle multiple Submit buttons in plugin's option page?
I'm developing my first plugin for WordPress and I'm getting a grasp of the whole hook system. I'm now stuck on a (probably) small issue, that I could possibly circumvent, but I'm afraid of coming out ...
0
votes
1answer
51 views
My first plugin doesn't save the data in options
This is my entire code. It doesn't save the data I enter on the plugin settings page. I don't have a clue on why this happens! Can somebody please help me?
<?php // add the admin options page
...
0
votes
2answers
112 views
How to store accumulate multiple option values in a single array using Options_API
I have created an option array that stores a series of options, along with their values. The problem is that I want to ACCUMULATE these options and store them in the options database. Meaning I would ...
0
votes
1answer
54 views
Make Database query only when option is updated
Below is a DB query I am using to retrieve values and place them in a WP_List_Table. Values are currently being added by add_option, then those values are converted into a custom database table ...
0
votes
1answer
30 views
Plugin options page - save two related options as one entry
I created an options page for my plugin where the user can specify image dimensions which will be saved for later use. So far the image dimensions are entered by the user in one input field like ...
1
vote
1answer
22 views
Editing options pages?
I'm trying to find a way of adding a single checkbox to one of the existing options pages, most likely options-reading.php programmatically. Unfortunately, I haven't found any good references on this. ...
0
votes
1answer
349 views
The Correct Way to Use Nonce Field without Settings API
I'm trying to create an admin option page without the Settings API for some reasons. Then if I do so, I've heard that I need to use nonces for security. I'd like to know the correct way to use them.
...
0
votes
1answer
330 views
Saving multiple fields as array
I'm adding a settings section to a theme that will allow the user to enter testimonials which will be randomly displayed on the site. Each testimonial has 2 fields, author and testimonial, I've ...
0
votes
1answer
157 views
Default Plugin Settings Not Writing to Database
I have my plugin setup as such:
Main plugin file mouldings.php
<?php
/*
Plugin Name: Moulding Profiles
Plugin URI:
Description: Creates a 'Moulding Profiles' and 'Idea Gallery' custom post ...
5
votes
3answers
179 views
Releasing new plugin version, how to rename old options keys?
I have everything ready for publishing a new version of my plugin but one last issue stands...
The old version had no naming convention for its key option names.
The options grew and I renamed all ...
0
votes
1answer
66 views
Need to add/remove group of options and display them as rows
I am creating a plugin which has 5 textbox for options. What I need to do is to treat these 5 options as 1 item, and being able to add more items.
I've always worked with static hardcoded options for ...
1
vote
1answer
589 views
Multiple options pages validation for a plugin
I am writing a plugin and I decided to have multiple pages for different options of the plugin (for clarity's sake). Doing a single option was a piece of cake, but I'm encountering difficulties when ...
0
votes
2answers
242 views
How Can I add Fields in wp-option table?
I want to activate my plugin and I want to create fields in "wp_option" table. How can I do that?
1
vote
1answer
455 views
How can I add an options page for my class based plugin?
I'm trying to use the new Settings API with a class based plugin to add a settings page. This is the code I have so far:
class simple_sample_plugin{
function simple_sample_plugin()
{
...
0
votes
1answer
221 views
Options don't save, validation callback not executed
I have been using settings API for my plugins for some time and it used to work well. Now it is broken and I can not figure out why. Apparently, the option validation function is not even called. Form ...
0
votes
1answer
90 views
How to get values from network settings panel?
I'm using wordpress 3.3. I've created a plugin
My plugin details:
My plugin creates a sub menu under Network settings and create two form fields to define adsense code (200 x 200 ad, 300 x 250 ad).
...
0
votes
1answer
163 views
Save user-specific options in WordPress admin
I'm writing a plugin that need to save user specific option in an admin page. I'm only thinking of adding username-prefix to option, for example:
$options = get_option('username-plugin_options');
...
3
votes
3answers
418 views
What's the best method for emptying an option created with the Settings API?
I'm trying to empty an option created with the Settings API and failing.
update_option ( 'my_option', '' ); appears to do nothing, whereas delete_option ( 'my_option' ); destroys the whole option ...
2
votes
1answer
459 views
WordPress plugin options and jQuery
I'm creating a plugin that uses jQuery to modify some css, but what I can't figure out is how you can control the execution of the jQuery with WordPress plugin options (like checkboxes true/false). ...
2
votes
2answers
170 views
Wordpress Plugin Setting's POST
I've developed a few plugin for Wordpress. Currently I've not been able to replicate the way wp save settings. I've a setting page which I learned from a tutorial. It POST to option.php, and wp take ...
0
votes
2answers
1k views
How to find out if option exists but is empty?
I am using something like this on one of my plugins:
$myOption_def = "myOption Default Value";
$myOption = get_option( 'myOption' ) ? get_option( 'myOption' ) : $myOption_def;
That works fine, but ...
1
vote
5answers
357 views
How to store a medium amount of options?
I develop a plugin that has a not too small number of settings. So far, there has been a fixed number of them, so I store them in a Wordpress option. Now I consider letting users define (an arbitrary ...
32
votes
6answers
4k views
framework for plugin/theme options panel? [closed]
I found that the longest part of a plugin or theme development is creating the options panel, at least in my case.
So i like to know what's your take on that.
Do you use a ready made framework or ...
2
votes
2answers
133 views
Unified Approach for Placing Option Pages
Currently, it is up to any plugin's author as to where to put a link to the plugin's option page. I have seen at least the following "solutions":
Plugin list
Dashboard menu
Plugins menu
Appearance ...
12
votes
4answers
5k views
How do I add CSS options to my plugin without using inline styles?
I recently released a plugin, WP Coda Slider, that uses shortcodes to add a jQuery slider to any post or page. I am adding an options page in the next version and I would like to include some CSS ...