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)

11
votes
2answers
5k views

How to add sub-menu to a menu generated by wp_nav_menu by using plugin

I have a menu generated by wp_nav_menu which look like <ul class="nav-menu" id="menu-top-nav"> <li class="menu-item menu-item-type-custom menu-item-object-custom menu-item-43" ...
0
votes
1answer
70 views

Lead form that submits to 2 external APIs

I need to add 2 registration forms to my wp website, each form should submit the information in it to 2 different APIs. I don't know even where to begin. Is there a plugin that can help me handle the ...
0
votes
3answers
2k views

Creating open content area and restricted content area

I'd like to create a site that has two separate areas of content. One for members with a payment system and another one for regular viewers that gives teasers so that they would want to read more and ...
3
votes
1answer
913 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 ...
1
vote
2answers
757 views

Subscribe to author?

Basically, I want to follow the author by other WordPress users. Whenever an author posts new post subscribed users need to get notification by email. If it's not already there, I can create a plugin ...
0
votes
3answers
122 views

How to pull user/author profile data in a plugin?

My site has a user profile page. For some reason I would like to pull user profile data in my plugin. I know I can pull logged in user profile data using get_currentuserinfo();. For example I would ...
0
votes
1answer
63 views

How do I duplicate a single post, with all its properties, and save it as a different post?

In a wordpress plugin, how can I duplicate/clone a single post? I would need to: 1) get a specific post 2) clear its ID property so that it's saved as a new post 3) save it. In the process, I would ...
1
vote
0answers
984 views

How to bind data-src attribute for the image in the post using jquery?

I'm trying to use foresight.js for responsive image in the wordpress blog. For that I have to add the data-src attribute in the place of src in the <img> tag. Or I have to get the url from the ...
1
vote
0answers
139 views

permalinks with get variables

I'm trying to create my own permalinks with wordpress rewrite API. I have been registering my get variables as it follows add_filter( 'query_vars','driver_vars' ); function driver_vars( $vars ) { ...
0
votes
1answer
1k views

Remove Meta-boxes (Yoast SEO plugin) [duplicate]

Possible Duplicate: WordPress SEO by Yoast: Hide Meta boxes in posts for non-admins I was wondering how to remove Meta-boxes from the post page. I would like that only administrators or ...
1
vote
1answer
1k views

Custom GET Parameters In Plugin's Admin Page

In my plugin's options page, I'd like to have custom GET parameters. WordPress already has a "?page=" GET parameter, so simply linking to something like "?myparameter=value" won't work. I though of ...
0
votes
1answer
53 views

Create pages for authors

I have a pretty good question here. I would like to create a hidden page on my wordpress blog for each user as they are registered. I already have most of the code of what needs to be put on the page ...
3
votes
1answer
231 views

What is the correct way to check if WP_Filesystem can write to a directory without aking for username / password?

I'm trying to implement caching using the filesystem so i need to check if i can write in a directory. I've read Otto's article, but i've failed to understand how should i implement a check where the ...
1
vote
2answers
144 views

How to display non-page / post content

I have a custom made Twitter stream on my site. I want to have a permalink for each tweet which would go to a page which would display only the tweet - no other content - surrounded by my custom ...
0
votes
1answer
40 views

Can I use a custom post type as a custom taxonomy for a different custom post type?

I am working on a site and need some guidance on how to proceed. The site allows registration of (1) artists, (2) promotion teams, and (3) members. The site hosts talent expos in which artists ...
3
votes
5answers
576 views

How do I make a theme “plugin-ready”?

How do I revise a theme so that I can publish my event hooks and anyone can build a plugin to add new functionality easily to my theme?
2
votes
1answer
847 views

Checking if a file is already in the Media Library

I'm creating custom files in a plugin and adding them to the Media Library using the code provided in the Wordpress Codex for wp_insert_attachment. However, my plugin occasionally overwrites those ...
-2
votes
1answer
177 views

How to create a sharing marketplace with wordpress for bicycles?

I want to create a marketplace for bicycles with wordpress. Users can register/login and sell their bicycle to other users. They also can create a pre-defined page for their bicycle... Which ...
1
vote
2answers
2k views

Get plugin_dir_url() from one level deep within plugin

I've written several plugins using the structure : /plugins/myplugin/myplugin.php /plugins/myplugin/class/class-myclass.php So as to take advantage of OO and overall structuring my code From within ...
0
votes
1answer
50 views

Projectmanager Internal Link Code Location

I'm working with the ProjectManager Plugin (by Kolja Schleich) and i've exausted myself trying to find the code that controles the Internal Link Form field. Does anyone out there in the magical world ...
2
votes
2answers
239 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 ...
49
votes
4answers
16k views

Best way to initiate a class in a WP plugin?

I've created a plugin, and of course being me, I wanted to go with a nice OO approach. Now what I've been doing is to create this class and then just below create an instance of this class: class ...
1
vote
2answers
368 views

Ordering posts by metadata

In my plugin, I use these instructions to obtain a list of posts: $args = array( 'numberposts' => -1, 'offset' => 0, 'meta_query' => array( array( ...
0
votes
2answers
2k views

Let user subscribe to specific categories

How could I let each user subscribe to a specific categories of his choice? I want to do something like reddit subscribe to categories? Is there any tutorial helps doing this?
-1
votes
2answers
2k views

How can I create a user generated photo wall

I'm looking for a way to create a user generated photo wall. Like a memorial site so to speak. I would have a big header image up top, than people could submit their own photo and it would post below ...
2
votes
1answer
5k views

How to Rewrite Wordpress URL for a Plugin

I am trying to build a Wordpress plugin here with a custom user admin area. What I would like to do is when the user adds /edit at the end of the page, it should open a page from my plugin. So for ...
1
vote
1answer
392 views

Adding option to Gallery shortcode

just starting out in WP dev, and I'm looking for any guidance I can get. What I'd like to do is use a hook or filter to add my own option to the core WP gallery shortcode. I would want it to work just ...
0
votes
0answers
365 views

Mamp Pro features like virtual hosts in Xampp or Wamp?

A friend of mine showed me the virtual hosts feature within Mamp, its pretty nifty. Using git and mamp pro to work locally makes it really easy to set up staging for WordPress sites. Was wondering if ...
1
vote
3answers
56 views

Plugin Paths Issue

I am using a plugin which has several instances where it is using a hardcoded path rather than using the WP function to find a path. The problem here is that it's referring to wp-content but I've ...
1
vote
2answers
354 views

Avoiding Duplicate function names in Post Loop (WP_Footer script)

Say I created a plugin that injects content (used as a shortcode) into a post. I'm trying to push that code for each post to the bottom of the page. This works fine, however when you are on an ...
0
votes
1answer
290 views

How do I create Widget within plugin that uses its own class?

I wrote WordPress plugin and want to include 2 extra Widgets with it... if( !class_exists('plugin_name') ) { class plugin_name { // plugin code } } // include widgets code ...
1
vote
1answer
127 views

Enumerating shortcode attributes in JavaScript

I'm working on a plugin which uses a shortcode to call a JQuery function, and it requires three aspects to work: The JQuery code + its own code, to be included on the pages it will be used on The ...
0
votes
1answer
462 views

Integrating Custom Database with Wordpress

I Have a Wordpress Site with few users who are my college students They Registered using their RollNumbers/HallTicket Numbers as their usernames in Wordpress site Now I Have Another Database with ...
1
vote
3answers
404 views

Save Plugin Version Number as Option?

I seem to recall seeing a tip somewhere saying that it was a best practice to save a plugin's version number as an option. I'm working through releasing a plugin, and I'm considering whether to do it, ...
5
votes
1answer
2k views

Register custom query args parameter for WP_Query()

I have written a plugin which can store a table of technical specifications for each post (product) in an own database table. For the search function of the site I want to add a custom parameter to ...
2
votes
1answer
1k views

How can I track active users of my plugin? and why doesn't WordPress.Org offer this?

It seems every major app platform from Android to iOS has great stats for developers. However, if you publish a plugin via WordPress.org you are not allowed to include any 3rd Party tracking code (for ...
1
vote
1answer
60 views

using get_option to add a different js

I'm trying to us get_option in my plugin to choose to load 1 of 3 js files. I started with this (and it works) ... add_action('wp_footer','isotope_vpl_set_style'); function ...
0
votes
1answer
309 views

Select options not reloading after form submit

I have two forms. One for adding, one for deleting option values. Deleting and adding works, but I have to manualy reload page to see changes in select part. How to make theme apper after submit? ...
1
vote
1answer
227 views

Resizing Images for a Gallery-Plugin?

I'm currently working on a gallery plugin similar to the one found on Posterous. I'm needing all images in the gallery in a very small thumbnail-size. Probably only 50px wide. What's the best ...
0
votes
1answer
55 views

Get URL of Post You Are Editing

I can't seem to find this anywhere, Is there a way to retrieve the URL of the post (which is of a custom post type) you are editing. Basically I want to somehow get the same URL that shows up like ...
1
vote
1answer
512 views

Wordpress Search filter to remove possible script injections

I am trying to write a short plugin that will filter html characters from the search form. In the event someone enters in <script>alert('some infectious js!');</script> into the search ...
-1
votes
1answer
414 views

Serialized Data

I'm trying to add data to a serialized string - I get the serialized string from my database - e.g. a:1:{i:0;s:2:"32";} Unserialize it add a value to it e.g. 128 serialize it and save it back But I ...
0
votes
1answer
173 views

custom comments form for custom post type

Hello everyone I am creating a theme dedicates to hotels display and booking in which I have created a custom post type 'Hotels' so now I want a mechanism to book the hotel rooms and a "book now" ...
1
vote
2answers
686 views

How to include external library in wordpress plugin

How can I make an external PHP library available with my plugin. Where the library files need to be placed?
5
votes
2answers
737 views

Passing current cookies in wp_remote_get to get Draft Post Preview

I want pass current user cookies in wp_remote_get function to get a Draft Post Preview page content. I check already the questions: What URL do you pass to wp_remote_get to load the body of the ...
5
votes
2answers
1k views

Add custom user capabilities before or after the custom user role has been added?

Should custom user capabilities be added before the custom user role has been added, or the other way around? add_role() asks for and array of $capabilities in the third parameter of the function. ...
0
votes
1answer
1k views

WooCommerce currency converter support [closed]

I am using WooCommerce Plugin to make a website. Everything is working fine with this plugin but when I wanted to implement currency converter, there is no such facility is available there. I really ...
1
vote
1answer
854 views

Using wp_parse_args to set up Plugin Default Settings

So I want to have defaults set up for each of my plugins settings, and I'm using wp_parse_args to do so which I believe is the correct way, but I'm hitting a roadblock. Here's my code at the moment: ...
1
vote
2answers
185 views

How to i18n text coming from the db or from an external source

I'm writing a plugin and i wanted to i18n correctly text which i'm storing in the db or in an external file. How should i do that?As of now we are generating pot files with wordpress and so all the ...
2
votes
1answer
409 views

Show comments fields in two columns

I am using comment_form(); in loop-single.php file to show the comment form. I have the following fields in it: Name, Email, Website, Title, Comment. Currently all these form fields show underneath ...