0
votes
0answers
16 views

Sanitize Term Custom Field - apostrophe problem

Alright guys, before posting I've searched the similar questions but I couldn't find the answer. Problem: I've added custom fields to a custom taxonomy, when I'm saving the options using ...
0
votes
0answers
17 views

Apply cropping to custom size from media library

I want to be able to apply a specific crop to the medium size or any other custom image size i define. I want to control the crop as it is controlled in the media library for the thumbnail. I want to ...
1
vote
2answers
45 views

How do i save plugin-specific info?

Im currently building a plugin that imports some data from an XML feed. This is all working great. Now i want to add some info, letting the user know when the last import happened. "Last import: ...
0
votes
0answers
33 views

get Options value in “external” page

I've create a really small plugin. This plugin add one filter : add_filter('the_content', 'BlueSteelAPI', 5); BlueSteelAPI is calling my API. I've create an admin page for register the secret key ...
0
votes
2answers
80 views

Who To Create Option Page For This Simple Plugin

I know how to write WordPress plugins but I have no idea how we could create an option page for our plugin. I read lot of tutorials but I still have no idea about creating option pages. So just for ...
1
vote
0answers
68 views

Image upload and other options in the same plugin settings form?

I write a wordpress plugin. My plugin has two options. One is an image upload mechanism and the other is a checkbox. My code is below: <?php /* Plugin Name: Plugin Name Plugin URI: Description: ...
0
votes
0answers
167 views

Error: Options page not found when saving my Plugin-Settings

after saving my options for my plugin I am getting the options page not found error. After some research, I found, that I may have forgotten to register my option or registered the wrong one. I ...
0
votes
1answer
44 views

how to protect wordpress website

i completed my website but i want to protect my site using login option.when i enter my site its goes to login page if user logged in after home page will display.how can do that if there any ...
0
votes
1answer
84 views

'all' hook and get_option issue

code listing: http://pastebin.com/0LEqgRUZ I ran into a trouble with my plugin. (It is a class based plugin actually) I'm trying to use get_option function. When I just make ...
1
vote
3answers
370 views

Creating a plugin that will add options. Where should the options menu pages go?

I am creating a plugin for a restaurant theme that will provide a few options to add the restaurant hours of operation. Currently, I use a custom post type to control the restaurant hours but have ...
0
votes
1answer
116 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
368 views

Plugin getting Cannot modify header information errors

I am trying to build my first plugin but am receiving the following error: Warning: Cannot modify header information - headers already sent by (output started at ...
0
votes
2answers
67 views

How to add options to the plugin page?

I can't find a more or less clear example on how to create additional fields, so may be someone can help me here? Here is my code: function __construct(){ add_action('admin_init', array($this, ...
0
votes
1answer
110 views

Saving widget options from class method

I have a widget class (derived from WP_Widget) that has a method (called via ajax) to update part of its options(the elements order) without the user to click "Save", to set the handler I do from the ...
1
vote
2answers
51 views

options creation for plugins

I am new to wordpress and learning to create plugins. I want to know how wordpress itself create options in 'wp_options' table for plugin during plugin installation or activation? How wordpress decide ...
3
votes
1answer
423 views

How do I extract the Alt Text from an image attachment upload via the Wordpress Options Framework Plugin?

I'm currently creating a custom WordPress theme and using the WordPress Options Framework plugin to make a custom options page for my client. I'm able to easily create an image upload option and can ...
1
vote
2answers
2k views

clean wp_options table unused rows

In my Wordpress Blog site i have installed too much plugin and remove also many plugins. In database table "wp_options" size increases approx 13MB and there are many rows which are unused at this ...
1
vote
0answers
257 views

WP-Super-Cache - generate cache programmatically

I wonder if there is possibility to generate WP-Super-Cache programmatically after the cache is being purged ( after I have published a new post ). I thought of writing some kind of crawler that will ...
1
vote
2answers
5k views

Contact form 7 select box different value-text then content-text in option

DSoes anyone know how I can set a different valute in the select-options in contact form 7 plugin? Here is an HTML example of what I'm trying to do <selct> <option value="1">My ...
0
votes
1answer
261 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 ...
0
votes
1answer
93 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 ...
0
votes
2answers
183 views

Multisite Plugin - Access options (wp_options) on child sites

Is there a way I can access the wp_options table of all the child sites? I want to create a multisite plugin that can be setup at the network level and will populate the child site plugins with ...
1
vote
1answer
563 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() { ...
2
votes
2answers
2k 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", ...
0
votes
1answer
101 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
182 views

update_option creates an option, which empties on a blog reload

I am currently writing a plugin that allows all authors to be listed on a page. I've created an options page and wanted to create a function that allows administrators to exclude certain authors from ...
3
votes
1answer
2k views

Correct way to serialize the data of options table?

I am writing a plugin and it require around 15 different options so I am using php serialization. I'm doing it by an array and update option with php serialize functions. but when I access it from ...
2
votes
1answer
191 views

Restore a Plugin's Default Settings

Is there a way to code "Restore Defaults" button into a plugin options page? I'm writing a plugin right now that has sets up some default values on activation (via register_activation_hook), and I'd ...
1
vote
1answer
178 views

Admin Theme customization

I followed instruction on the wordpress codex site on creating an admin theme via a plugin. I activated the plugin, but my stylesheet isn't being included in the <head>.. Here's my code: ...
9
votes
2answers
2k views

How to add field for new site-wide option on Network Settings screen?

I'm working on a plugin, and part of it involves setting an option value that applies to all sites in a WordPress network. I know about the add_site_option and get_site_option functions that let you ...
1
vote
3answers
610 views

How to debug register_setting callback function

I am using the following code: register_setting( 'myplugin_options', //setting group name 'myplugin_options', //option name that will be stored in the database ...
2
votes
1answer
65 views

Environment Specific Options Token

Is it possible to add a token to any wp-option that could be replaced on get where the token being defined in a plugin’s option or the configure file? E.g. ...
0
votes
3answers
2k 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
2answers
462 views

Changing widget options via the functions.php when there are no hooks

The problem: to change a widget's options with a custom function in functions.php, when there are no useful hooks, and where there are multiple occurrences of the same widget (multiwidget). This ...
0
votes
1answer
51 views

What is the most efficient way of adding additional functionaliy for admin only

I'm trying to figure out the best approach to add additional functionality that will only be utilized by admins via /wp-admin. What's the best way to implement so that resources aren't being wasted. ...