Tagged Questions
0
votes
1answer
49 views
Incorporating the Settings API in WordPress Themes - by Chip Bennet
I am using the code by Chip Bennett to create a settings options page for my plugin. The problem is that I am getting a Warning error as indicated below that I cannot figure it out. Any help is ...
0
votes
0answers
23 views
Question about saving settings
I am using the Settings API to save some of my plugin options. I also have a notice in the admin related to the plugin, which basically shows once upon activation, and then can be dismissed at the ...
0
votes
1answer
34 views
How to add options for Pages?
I would like to show an input field on the bottom, everytime, when a user create a new page. How is it possible?
0
votes
1answer
47 views
options validator input is false?
I have a form that looks as such:
<form action="options.php" method="post">
<ul class="nav nav-tabs">
<li>
<a href="#content" data-toggle="tab">content</a>
...
2
votes
0answers
52 views
Tab from Settings API resetting all options with INSERT INTO
I have an Options menu created with the code from Chip Bennett tutorial, the old code, though, the one from like a year ago (the new one has a much better validation structure, but still, it works ...
0
votes
1answer
43 views
Difference between Option_Group and Option_Name in Register_Settings
I think the title pretty much says it all! I'm working my way through various tutorials on how to add an options page to my test plugin and am struggling to understand the Register_Settings function.
...
0
votes
2answers
203 views
Can't get plugin settings page to save data
have a simple plugin that inserts text (a Google ad) partway through the content of a single post. I'm trying to create a settings page that will let users change the ad code, and change after which ...
2
votes
2answers
65 views
How to display some settings for super admin user only using Settings API
I'm developing a plugin with an options page using the Settings API.
I'd like to have one options array stored for my plugin, but on the settings page, I'd only like some of the settings to be ...
0
votes
1answer
78 views
How to add a Reset to Defaults button with Settings API?
How can I add a reset button when using the Settings API?
I've have something like this that's storing my defaults:
$slider_options = get_option( 'nextslider_options' );
/* Define the array of ...
3
votes
1answer
64 views
How to Save Different Settings Options Using Settings API and/or the Theme Optimizer
I would like to allow users to save different versions in the options panel using the Settings API and/or the Theme Optimzer.
For instance, imagine that I have styled my site using via an admin panel ...
-1
votes
1answer
181 views
Creating your own options-general.php page
I wanted to develop a duplicate General Settings Page instead of the built in one and all the settings on the built-in General Settings Page will also be displayed on the new General Settings Page.. ...
3
votes
1answer
362 views
Settings API - save an array of options as one setting (array_push?)
1. Basic settings API callback.
Using Settings API my $sanitize_callback validating function looks like:
(...)
if($type == "foo") {
$valid_input[$id] = $option[$id];
}
else ...
0
votes
1answer
171 views
Tabbed theme options query about add_settings_section callback function
I have been building a tabbed option page based on some tutorials I found, using the settings API. Here is the code http://pastebin.com/bbSnhFP5 . It's all actually working fine for me but it's not ...
0
votes
1answer
336 views
Settings API validation callback
I finally managed to create working validation callback for Settings API with big help of Chip Bennet, there's only one glitch that I'm not sure how to fix.
Here's the foreach loop from my validation ...
3
votes
1answer
643 views
Settings API - easiest way of validating checkboxes?
I'm using Settings API and I can't get checkboxes to work, if they're set to "false" they're not even being $_POST and that's the point.
Stephen Harris & Chip Bennett explained it, but I believe ...
0
votes
1answer
149 views
Settings API - how to update options manually?
I'm storing all my options using Settings API:
function registerSettings() {
register_setting('XX_theme_settings', 'XX_theme_settings', 'setting_validate' );
add_settings_section('theme_options', ...
1
vote
1answer
219 views
Settings API erases itself?
I have two forms created using Settings API, and when I save one of them the other one gets erased and vice versa.
Here's the whole code so you could paste it into your functions.php file and see ...
4
votes
1answer
463 views
Settings API - creating reusable form elements?
I have a set of settings fields:
(...)
add_settings_field( 'Option1', 'Option 1', 'textarea', 'page1', 'plugin_options');
add_settings_field( 'Option2', 'Option 2', 'textarea', 'page1', ...
1
vote
1answer
163 views
Settings API - changing add_settings_field() output?
I'm using Settings API and wondering if there's any way of editing default output of add_settings_field() function?
add_settings_field('the_field', 'bar', 'foo', 'page', 'section');
function ...
1
vote
2answers
918 views
How should I use register_setting, add_settings_section, & add_settings_field in my plugin's options page?
I'm working on a settings section for my plugin, and after reading over Wordpress's documentation which is in ROGUH DRAFT status, and also the Creating Options Pages - which is also in "transition", ...
1
vote
2answers
222 views
Possible to add another setting to 'Front page displays' setting for Custom Post Type
Let me set the scene:
I have a CPT that will work on a multi-site installation and some of the sites will be in a different language. For example my CPT is Case Studies I would use a URL structure ...
5
votes
2answers
432 views
What are the advantages to the Settings API?
Let me preface this by saying that I hardly ever work with WordPress - in fact, the last time I did a site in WordPress was back during 2.2. Yesterday I made quite a mess of everything and asked ...
8
votes
2answers
1k views
How to pass variable to add_settings_section() callback?
I am attempting to automate, as much as possible, the Settings API function calls for each setting in a Plugin. Looping through the options array, and outputting add_settings_section() and ...