WordPress Plugins allow easy modification, customization, and enhancement to a WordPress blog. Instead of changing the core programming of WordPress, you can add functionality with WordPress Plugins.

learn more… | top users | synonyms (1)

2
votes
1answer
500 views

Error with Custom Admin Screen in iframe Thickbox

I have a plugin that adds a new admin screen in an iframe. I created a PHP file in my plugin, and I put a link with a class of Thickbox to that. Everything works just fine, but it produces a PHP error ...
2
votes
2answers
153 views

Multisite, sharing content by URL

I have a network of two sites, A.example.com and B.example.com. I'd like it so that if I create a page on A with a permalink of /Widgets I can access it on B using the same relative permalink but ...
2
votes
1answer
370 views

How to use the settings API to set multidimensional arrays

I'm writing a course information plugin. Most course info is related to to a post (a custom post type of 'course'), so I have put the majority of info in the postmeta table. But some info isn't ...
2
votes
1answer
199 views

Scheduled event does not run at midnight

I have an event scheduled to fetch feeds from different sources at midnight. I believe for some reason it is not being triggered. I use Core Control plugin for testing. When I 'Run Now' through it, ...
2
votes
1answer
441 views

When to check if a function exists

I've just started developing a WP plugin, and i've been reading some code from other plugins as a way to get started. I've seen a couple of plugins that wrap all or some of their functions in the ...
2
votes
1answer
729 views

How to duplicate custom menu settings to export to another site

I'm trying to write a routine that will pull items from the wp_options table in order to transport them to another site. The problem I have is that if the source site has custom menus, I'd like to ...
2
votes
3answers
554 views

How to: get main plugin/theme file?

There're the functions get_theme_data(); & get_plugin_data(); - which both use get_file_data(); that needs a specific file as $input. I got a set of classes that may be used by a plugin or a ...
1
vote
1answer
58 views

Saving Plugin settings to the database

I'm not a complete novice with php or wordpress but am wanting to approach this problem the most efficient way so believe asking here will help. I've got a plugin that randomly generates a quote - ...
1
vote
1answer
199 views

Hello dolly type plugin that allows people to add their own

I am making a plugin that shows a random joke on a custom 404 page via shortcode and it is basically near enough the same as the default hello dolly plugin, where the jokes are hardcoded into the ...
1
vote
1answer
51 views

Common functionality between my own plugins

I read that when creating new post types, creating a settings page, and creating a new taxonomy, you should create a plugin. So I have done that. But I have functionality, which could be generalized, ...
1
vote
1answer
49 views

Create a Page via plugin

My problem is to show a list of products read from db tables. I know how to read them and I am able to produce the table, but only using a shortcode embedded in a page that I've created via WP. I ...
1
vote
2answers
130 views

enqueue script only if it is not already enqueue

I want to include a script in a shortcode output, so I am trying this: function my_shortcode( $atts, $content = null ) { extract(shortcode_atts(array( 'title' => '', ), ...
1
vote
6answers
154 views

Pages 404 in wordpress

First of all, I am very new to wordpress and know almost nothing about it. When I create the page foo using in wp-admin, I get the message that the page is created. When I click on view page, it ...
1
vote
1answer
26 views

How to use is_multisite() in a must-use-plugin?

I want this code to be executed in a plugin in the mu-plugins folder. When executing in functions.php everything works fine, but when I try it as a plugin in mu-plugins this creates a blank page. if ...
1
vote
1answer
137 views

When is it too late to call the action wp_enqueue_scripts?

I'm creating a plugin that always enqueues a script in the footer. I also have a function that if called would enqueue an additional script that depends on the other one. Here is the basic format of ...
1
vote
1answer
116 views

Are shortcodes case-sensitive?

If I write a plugin and register a shortcode using this code: add_shortcode('footag', 'footag_func'); and a user uses this in their post: [FOOTAG] Is it supposed to work?
1
vote
1answer
113 views

Why are two functions over-riding each other?

I have function in my plugin that is: add_filter('comment_text', 'commentimage_comment_text'); function commentimage_comment_text($comment = '') { $options = get_option('commentimage'); $id = ...
1
vote
2answers
570 views

How do I only load js on the post-new.php and post.php pages in admin?

I have some script that is loading in the admin. I only need it to load on the new post and edit posts screens. What is the best way to do this?
1
vote
1answer
34 views

Including file or library from other plugin

I'm creating a plugin I would like to use from other different plugins. This plugin declares classes and functions. So, I am thinking about the best way to include, from one plugin, a php file present ...
1
vote
1answer
121 views

Using ob_get_content to get_search_form puts into infinite loop

I am trying to change the look of my searchform. It basically needs to have two text fields. I want this to be in form of a plugin, which anyone can activate. SO obviously I do not have any control ...
1
vote
1answer
321 views

Check spam in custom form - akismet

I have a plugin that has input form, I have decided to check submitted data with akismet. I do have API key, WP comments are filtered correctly... here is, what I found: ...
1
vote
2answers
323 views

How to check if current static page is frontpage from admin plugin

I set static page as front page. I need to know if user currently on homepage in my custom plugin. Functions is_home() and is_front_page() doesn't works, since homepage is static page. I can get an ...
1
vote
1answer
60 views

Adding Second Plugin Author

Background: I have a few plugins in the WordPress directory and have recently made the decision to team up with another individual to grow one plugin faster. I'm planning on adding him as a plugin ...
1
vote
2answers
380 views

remove custom taxonomy metabox form custom post type

I have created a custom post type 'hotel' and custom 'taxonomy' so when administrator creates a new hotel and saves it it related custom taxonomy automatically get created but I don't want to show ...
1
vote
2answers
95 views

Failed to invoke other hook from the init hook

Related to this question (Use wp init hook to call other hooks?) but not the same. Sometimes, I found that the hook will failed to run when I place inside the init hook, e.g. Not Work: ...
1
vote
2answers
241 views

Script won't load via plugin class

I'm not sure why this script is not loading or producing any load errors via Firebug. Here is my plugin script: class AV_Slideshow{ function __construct(){ $this->hooks(); } function ...
1
vote
1answer
269 views

Plugin Settings not Saving on Ajax re-ordered table

This is an extension of Update Option Stored in Multi-Dimensional Array which was help getting draggable plugin options to save via ajax (which works), but unfortunately this is specific to the actual ...
1
vote
1answer
210 views

How to post form in ajax mode and handle it in wordpress

currently I can only do it in a normal non-wordpress way. So, does wordpress provide a solution for this circumstance?
1
vote
2answers
736 views

Using Ajax call in jQuery doesn't work in widget

So I'm in the midst of creating a new conversion widget and I'm having some trouble getting the Ajax call to work in my widget. (works perfectly outside of WordPress). The problem at the moment is ...
1
vote
1answer
138 views

Master menu item for multiple plugins?

I guess this question is more or less about aesthetics and organization rather than functionality, but I'm curious nonetheless... I know I can add a custom menu item in the dashboard for my plugin ...
1
vote
2answers
741 views

Upload to a remote server using wp_remote_post

I'am developing a plugin that will push files to a remote server via http upload. Currently I got it to work with CURL doing something like this: $post = array("post_file"=>"@/path/FILE.EXT"); ...
1
vote
3answers
3k views

Add post thumbnail from external image with plugin

I'm currently writing a plugin modifying the post content with the wp_insert_post_data filter. While doing that I would also like to add a post thumbnail using an external image url. It doesn't really ...
1
vote
1answer
330 views

Replacing WordPress menu functionality with a plugin

I asked this earlier on StackOverflow.com before realizing there was a StackExchange specifically for WordPress. Here is the link to the old question (for moderator deletion): ...
1
vote
5answers
239 views

Problems with removing admin bar

I am trying to remove the admin bar from a theme front end of a theme. I found the following code block: add_filter( 'show_admin_bar', '__return_false' ); remove_action( 'personal_options', ...
1
vote
1answer
2k views

wp_mail not recognizing cc and bcc headers

I am using WordPress 3.1.3 I am getting following notices when I use wp_mail with cc and bcc headers. Notice: Undefined variable: cc in ...
1
vote
1answer
1k views

How to use WP default post list tables in a plugin?

I'm developping a plugin to manage a base of users and I'd like to show them in the same type of table used in other parts of the WP admin (post lists, user lists, etc.), I'd like to have the same ...
1
vote
3answers
2k views

Conflicting save_post functions when passing the post id and saving custom meta boxes for different post types

Post save functions are conflicting with each other when adding them to the save_post action hook. 2 different custom post types with 2 different (one for each post type) custom meta boxes. I'm ...
1
vote
2answers
1k views

Menu Error in Admin Console with Custom Plugin: You do not have sufficient permissions to access this page

(Moderator's note: Original title was "Getting error: You do not have sufficient permissions to access this page. Trying to build custom plugin") I'm trying to write my own custom WordPress plugin, ...
1
vote
2answers
862 views

How do I determine if a category exists by ID?

I know I can get a categories ID by calling get_cat_ID('category-slug'), however, what is the method to call to determine if a category exists by ID when you don't know the slug? In other words, I ...
1
vote
2answers
3k views

Show dialog box in TinyMCE plugin and use WordPress php functions in it

I'm adding a TinyMCE button to my plugin. So far, I've been able to add the button and call my editor_plugin.js file and it's command. Not an easy mission btw... I want this button to show a Dialog ...
1
vote
2answers
288 views

How can I view all WP generated thumbnails in Media Manager?

When WP creates thumbnails from the original uploaded image, they are hidden from view inside the Media Manager listing. Can they be made visible, via some filter or action so that you can selectively ...
1
vote
1answer
341 views

Ad rotator script for Adsense/CPA rotations. Ideas? Existing Solutions?

My theme handles Adsense inclusion automatically for the end user. I'm looking to add a feature that allows them to rotate in CPA ads in place of the adsense ads (on a set frequency by percentage). ...
1
vote
2answers
176 views

Is it possible to use add_filter from a theme to alter a plugin's function?

Can add_filter() be used to intercept a plugin function? I'm not having any success, so I'm thinking perhaps I'm doing this wrong. The plugin is "All in One SEO" and the function I'm trying to ...
1
vote
1answer
230 views

How can I limit the amount of characters used for description in the manage categories grid?

My category descriptions consist of whole pages of content. When I view the manage categories screen, the grid does not truncate the text but rather, shows all of it. I realize I could turn off the ...
1
vote
3answers
439 views

Plugin options table,is the data serialized

I am planning on building a plugin and i need to know if the data stored in the options table i will create for the plugin will be serialized or it will be in the ordinary sql format.
1
vote
1answer
619 views

Converting theme widgets to plugins?

i need a help, i have a theme, where in i have a twitter widget, i just want to separate it, and keep it in different file, as if it is a plugin, here are is the complete code, what i have to do? ...
1
vote
2answers
225 views

How can I call “preview post” from wp_remote_get with authentication?

I've got a plugin that needs to interogate the post preview (the contents of the rendered page that's presented when the user clicks "Preview Post". To attempt to obtain this input stream into a code ...
1
vote
1answer
456 views

What URL do you pass to wp_remote_get to load the body of the current post's preview?

In the code below, I'm attempting to get a reference to the body content of the current post's fully rendered preview... $response = ...
1
vote
2answers
224 views

How to determine, from plugin script, if active theme has <h1>The Post Title</h1>

My plugin needs to know if the currently active theme places the post title in H1 heading tags? I'm looking for suggestions on approaches to create script that could discern this. UPDATE: The plugin ...
0
votes
0answers
54 views

How to properly modify get_userdata in plugin to get roles to update in database

I wasn't sure if starting a new question was appropriate, but the questions are completely different from my original ones and code has changed since originally asking for help. This is still the same ...