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)

1
vote
1answer
120 views

Using WAMP, trying to create a plugin, getting error: You do not have sufficient permissions to access this page

Just trying to create a simple plugin with some Theme Options so I can practice. When I try to access the Theme Options page under Settings... I get the: You do not have sufficient permissions to ...
2
votes
1answer
4k views

how to use thickbox in admin?

I would like to show my retrieved content form my classes method in thickbox. How could I do this? I have been adding the proper id to my desired hyperlink but all of the admin body is getting parsed ...
-1
votes
1answer
38 views

How to hide a piece of code from a wordpress web page?

I installed a plugin called Sociable on my Wordpress website. It displays social media share icons below each blog post, but on my website it's also showing up in the footer. Like here http://amsa.mn/%...
4
votes
1answer
651 views

How to extend LINK TO functionality in ATTACHMENT DISPLAY SETTINGS

In WP 3.4.x and earlier, it was possible to add a button to the media manager by messing around in an attachment_fields_to_edit filter. For example, a plugin could, when it figured out that an item ...
6
votes
4answers
785 views

Prevent network activation of plugin

I have a plugin that currently doesn't support network activation. The best fix for this of course is to fix it :) which I plan to do. However I wonder if there is a temporary solution I can use to ...
1
vote
1answer
149 views

handling csv data with a custom post type

I have a custom post type which represents a 'race' and there are meta fields for 'distance' (5km,10Mile) and 'type' (track,road,crosscountry). We get the race results as a csv file which contains the ...
9
votes
3answers
2k views

Best way to abort plugin in case of insufficient PHP version?

You write a plugin which requires PHP 5.1. Someone tries to install it on a server with PHP 4. How do you deal with that in a safe and user-friendly manner?
0
votes
1answer
179 views

Fill custom fields when saving custom post types

I have a Custom Post Type called "Report." It has some custom fields, including the name of the place where the post has been written. I would like that when a user saves (or updates) the post from ...
0
votes
1answer
60 views

Cannot get jQuery UI to enqueue in my plugin!

Not sure what I'm doing wrong, but I could use some help. My plugin architecture is below... register_activation_hook(__FILE__, 'my_post_options_box'); add_action('admin_menu', 'my_post_options_box')...
1
vote
1answer
345 views

Give a permalink to Custom Post Types without title

I have a "report" Custom Post Type registered in this way: register_post_type( 'report', array( 'label' => 'Reports', 'description' => '', 'public' => true, ...
0
votes
1answer
399 views

Wordpress actions for plugin admin UI page

How can I make a custom edit page for my plugins admin UI page, if the requested page has a query argument of $_GET['action'] == 'edit'? My plugins entry url looks like /admin.php?page=parser-top-...
0
votes
1answer
267 views

Breadcrumb is not generating the correct post page url

I have created a custom posts type cities and the code for its deceleration is register_post_type('City',$args); $labels = array( 'name' => _x('Cities', 'post type general name'), 'singular_name'...
0
votes
1answer
175 views

Virtual Page with Registration form

Working on a plugin, which is intended to provide a registration on front-end, to let users register. I am trying to create a Virtual page, which would display the form. Trying to create URL like ...
2
votes
1answer
190 views

wordpress plugin that show my reputation (points) in any stackexchange project in my wordpress blogs

I'm seeking for a plugin show my points (reputation) of Stackexchange (not Stackoverflow) in my Wordpress blogs. or other projects in stackexchange like : Superuser Security Serverfault SharePoint ...
1
vote
1answer
1k views

fatal error get_page_permastruct()

I'm getting the following error Fatal error: Call to a member function get_page_permastruct() /link-template.php on line 276 when I invoke the in class constructor the wp_insert_post($new_post);. ...
2
votes
2answers
257 views

Is there a faster way than wp_insert_post to add content to a blog

I've written a plugin which retrieves an xml file, parses and creates a series of short posts from the content. Although each post is very short (sometimes just a single sentence, never more than a ...
0
votes
2answers
1k views

add short code not working

I am new to wordpress, I am creating a plugin and for the short code, I am using the short code api. But when I insert this shortcode in my page, it displayes as it is, it does not display the ...
3
votes
1answer
3k views

Show message on wordpress admin dashboard

I have created a form. On success of the form, I am redirecting the user the their dashboard. Now, I want to be able to show a success message/notice on the dashboard. What is the convention to show ...
0
votes
1answer
288 views

Practical Solutions to HTML5 Video on WordPress

I was directed here from Stack Overflow -- We work with clients who have WordPress sites and one thing we keep struggling with is implementing HTML5 video across all browsers and devices in the ...
2
votes
3answers
6k views

When do I need to use esc_attr when using WordPress internal functions

When I am putting a WordPress value inside the attribute tag, for example, the following method does not need esc_attr e.g. // JS code alert('<?php echo get_bloginfo('name');?>'); the ...
8
votes
2answers
2k views

Is wp-content/install.php a Drop-in?

I cannot find documentation or discussions on what is and how to use Drop-in plugins. The question was raised in this Q&A, Populate content on install. Is a wp-content/install.php file that ...
2
votes
1answer
909 views

How to redirect to action on custom page within admin section

Currently I'm developing(well at least trying to;) plugin which will handle custom gallery of images. I stumbled upon one problem though. I'll try to picture it. I've created custom menu page on ...
5
votes
4answers
941 views

How to control output of custom post type without modifying theme?

I have a custom post type 'properties' that I'd like to control the HTML output for. For simplicity, let's focus on the archive view. As a basic example, here is what a loop looks like in an archive....
0
votes
1answer
114 views

How to get changed post title in my custom plug-in which fires when 'save_post' is called?

I created a custom WordPress plug-in that hooks onto 'save_post" using add_filter(). I need to do something with the post titles and whenever a user changes the title, my plug-in cannot get the new ...
1
vote
2answers
1k views

Hidden Custom Post Type

I am just wondering is it possible to create a custom post type in wordpress which is hidden from the wordpress admin panel?
0
votes
1answer
600 views

wp_insert_user keeps echoing values

This is bugging the heck out of me. Essentially I've narrowed the issue down to one line of code: $user_id = wp_insert_user ($userdata); From what I can tell nothing should be echoed here, but I ...
10
votes
4answers
21k views

What is the wordpress wp-includes folder for?

What is the wordpress wp-includes folder for? That is, whats the fundamental architectural purpose of it, for example why isn't it all in themes or an admin folder? Can a plugin developer rely in it'...
2
votes
2answers
1k 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 ...
2
votes
1answer
4k views

Fatal error: Call to undefined function wp_mail()

I am using a plugin wordpress-simple-paypal-shopping-cart for my cart requirement. I am trying to send an email through this plugin when some payment is made by using IPN. My code : $invoiceProducts ...
0
votes
1answer
2k views

Widget update function not saving values

Hello WordPress Answers! I'm having trouble with the widget update function saving values correctly, but first let me explain the situation. I'm writing a simple news ticker widget plugin, which ...
0
votes
2answers
3k views

What is the proper way to get logged in user id in a plugin?

I need to get logged in user id inside my plugin. Is this the proper way? $root = dirname(dirname(dirname(dirname(__FILE__)))); if (file_exists($root.'/wp-load.php')) { require_once($root.'/wp-load....
0
votes
1answer
193 views

An adiitional function fires on my AJAX submit

I am working on a small community style website for my family to use. Mainly it is a small version of a social network so my nieces and nephews can have fun with each other. I have set up "freinding" ...
5
votes
1answer
188 views

Listen to Post action

I am writing a plugin that adds a custom metabox to the post page. I would like to trigger an event when the user navigates away from the edit post page or when a user stops editing a specific post. ...
1
vote
1answer
86 views

Execute a function using ajax

I have a function called function getSingleAmazonProduct($asin=''). It returns an amazon product. I have a form field to enter the $asin. <div id="asinform"> <form id="...
-1
votes
3answers
2k views

Can I change header.php of current theme through a plugin function?

I need to add some html into the header.php but instead of directly changing the header.php of my theme or creating a child theme, how can I do it with just actions and/or hooks?
0
votes
3answers
2k views

How to Create a Directory in a Plugin Folder?

I am creating a plugin in WordPress Version 3.4.2. When the administrator submits a form, a new folder is created inside my plugin directory and a file saved in this new folder. But it gives me the ...
0
votes
1answer
51 views

Plugin: database creation

Can someone tell me what's wrong with this function? function xattachments_db_install() { global $wpdb; $xattachments_db_version = "1.0"; $table_name = $wpdb->prefix ."xattachments"; $...
0
votes
1answer
108 views

Making a Custom Post Type Publish Loop

I want to re-publish all previously published products of a custom post type. Let's say the post type is "events" This is what I was thinking something like this: $args = array( 'post_type' => '...
4
votes
1answer
95 views

Update exisiting site to 3.5 release candidate

I have an existing site that I want to update to 3.5 now, because I want to see if my plugins and themes work in it. I don't want to wait for the full release (when I'll be able to automatically ...
0
votes
1answer
44 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
5answers
4k views

WP_Query returns no results

I'm using wp_query to create a custom query that retrieves search results but it is returning 0 results. Here is the code: $query = 's=the&posts_per_page=5&paged=1'; $custom_query = new ...
0
votes
1answer
516 views

Admin Subpages without Menu entry

I have added some pages to the WP-Adminmenu, with add_menu_page and add_submenu_page. The URLs for those pages look like admin.php?page=my-plugin/admin/submenupage.php. If I try to add a page now that ...
1
vote
0answers
68 views

Possible to get all posts with my shortcode?

So here's what I'm trying to do. I'm building a plugin for a business directory. Each business is assigned to a category. There are two views, listing and detail. To give the user as much ...
0
votes
1answer
629 views

More gentle way to hook Wordpress custom url

I have written a plugin named foo, and I want when user typed url /hello and it will display the string world There is an existing post which uses the following code if ($_SERVER["REQUEST_URI"] == '/...
5
votes
3answers
10k views

How to call a plugin function from index.php [closed]

I have created a function in my plugin myplugin with the name foo, how to call it from the frontend? e.g. index.php?
0
votes
2answers
324 views

Rewriting Image URLs from dynamic to original

Here's the deal: My plugin automatically watermarks images from the WP gallery on the fly using the GD library wherever these images appear. So, I have a physical copy (in wp-uploads) of these ...
48
votes
6answers
10k views

Where to put my code: plugin or functions.php?

Is there an easy to understand scheme to decide what kind of code belongs to a plugin or the theme’s functions.php? There are many cases and many debates about that topic, mostly because there are ...
-1
votes
1answer
251 views

Is it possible to debug plugins with Xcode?

I am mac user and I want to write a Wordpress plugin. Does Xcode work for me or do I need a different and specific IDE for this?
0
votes
2answers
703 views

Make get_permalink() work outside the Loop using filters

I am developing a plugin which displays a wordpress post in a lightbox outside the loop. I noticed that some plugin which modify the contents of the post (like Facebook Like button plugin) use the ...
0
votes
1answer
7k views

Open a wordpress single post in a lightbox without the header and footer

I am developing a plugin which requires to open a single wordpress post inside of a lightbox. Here are a few details : Currently,I am using colorbox for lightbox. The lightbox is triggered to open ...