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)

0
votes
0answers
40 views

Admin panel specific page only with admin_head for 4.1?

<?php /* Plugin Name: Header Problem Demo Plugin URI: http://wordpress.stackexchange.com/questions/215190 Description: Shows how old admin_head-{page} method no longer works Version: 1.0 Author: ...
0
votes
0answers
16 views

How to modify the plugin update counter in the main menu? (red badge in the Plugins menu button)

I am providing a self-hosted plugin update system for my plugin. I hoked everything in order to replicate the information provided by the "Wordpress repository" pending for update plugins in the admin ...
0
votes
1answer
75 views

How can I use wp_ajax_response for front-end error reporting?

I already have the wp hook code in place, and now I want to send error messages back to the front end to be placed in alert box or html element. //my plugin add_action('wp_ajax_track_upload', '...
0
votes
0answers
18 views

Add a page with a plugin [duplicate]

I have a plugin that adds a few admin pages, a dashboard widget and a normal widget but I can't figure out how to add a page to the site. I want to create a permalink that makes wordpress use ...
0
votes
1answer
27 views

How to Insert images in WordPress using code

I am trying to create a plugin for auto posting. I was able to create new post and then get the attachment for the post. But images are not showing inside the post itself. but if I click on media ...
0
votes
1answer
22 views

What should I use instead of get_blog_option?

I am using a plugin that was using get_blog_option and it no longer works. I looked up the call and it doesn't work because it's a wpmu function only. Is there an equivalent method that I can use ...
0
votes
0answers
14 views

WordPress Plugin error: Multiple primary key defined

Given an SQL statement like this to fire on plugin activation: $charset_collate = $wpdb->get_charset_collate(); $sql_fields = "CREATE TABLE wp_my_table ( id int(11) NOT NULL AUTO_INCREMENT, ...
0
votes
0answers
23 views

Any way to make Apache's internal redirect work?

What I really want to do is to make URLs like http://localhost/bmicalc/bmi24.57 to redirect to http://localhost/bmicalc/index.php?pagename=bmi&result=24.57 without changing the URL in the ...
0
votes
2answers
36 views

How do I link to a php file in my plugin directory?

Basically in the wp-admin section I have a page where I attempt to export some records from a grid. I have an Export link which leads to something like admin.php?page=download&selected_ids=1,2,4. ...
1
vote
2answers
51 views

Add a row on clicking each post featured image

I have to add a row that (containing the content of post) below the post thumbnail on clicking thumbnail. I have done it by using this but it affects the adjacent post thumbnail.I want that a ...
0
votes
1answer
38 views

How do I force a download in the admin area?

I'm doing an export function in my plugin but I cannot force a direct download. I get the error: Cannot modify header information - headers already sent Apparently at some point before my function ...
-3
votes
1answer
33 views

Difference between WordPress stand alone & through host gator

I am new to WordPress development, I noticed a certain thing in the pricing. If I go into www.wordpress.com and try to buy a plan for e-commerce , I am getting a quote of $299 per year but if I buy a ...
2
votes
3answers
146 views

When is wp_loaded initiated only with admin or only when user enters the site or both?

When is wp_loaded initiated? Im trying to add function that downloads a big file for the plugin DB, and I need it to be executed whenever user/admin/unknown user get in the frontend, after the site ...
0
votes
0answers
37 views

In WordPress do I create tables for my plugin or do I create custom post types for a Student and Classes Registration system?

I want to use WP 4.x as a framework to build a small Student system. I do not wish to use an existing plugin. My needs are unique, and these do not do what I need. In my design, I have Students ...
1
vote
1answer
227 views

Why does Wordpress have a noop.php file?

While configuring Ctags to recognize WordPress functions, I came across the noop.php file. Here is an excerpt: /** * @ignore */ function add_action() {} /** * @ignore */ function did_action() {} ...
0
votes
0answers
30 views

Custom Taxonomy with Core Post Type Pagination Issue

I've added a custom taxonomy to the core Wordpress Post Object: register_taxonomy("main-category", "post", array( "hierarchical" => true, "labels" => $tax_labels, "public" => ...
0
votes
0answers
52 views

Need to hide form after submission

I am trying to hide a registration form after submission so that it only displays the thank you for login in or a default thank you page what is my best method for hidding the form after i register ...
1
vote
1answer
46 views

Do uploaded plugins get updates if they came from the wordpress plugin directory?

I'm a plugin developer and want to ensure my users are getting updates when I release an update within the wordpress plugin svn repo. I know if they search for the plugin through the plugin area of ...
0
votes
0answers
37 views

Integrate existing simple plugin with wordpress multi site

I have a simple plugin that add's new currency to woocommerce. Here is the code: <?php if ( in_array( 'woocommerce/woocommerce.php', apply_filters( 'active_plugins', get_option( 'active_plugins'...
0
votes
0answers
76 views

add_action wp_ajax_ not loading in plugin file WP Network

I'm developing a plugin that relies pretty heavily on AJAX calls. It works well in a single-install version of WordPress, but when I ported it into a Network WP my AJAX functions stopped working (...
0
votes
0answers
34 views

Upload Image from Custom Field to Wordpress

What do i really need .. is .. for example: I have Custom Field "image_url". I go to google and search for image. I found one. I manually place the direct image link to my "image_url" custom field. ...
0
votes
1answer
61 views

New Users are saved with no role selected

I'm working on a plugin that adds new user roles: Manager and Employee. Managers are supposed to be a "pseudo-admin". They can manage all post content (private or otherwise), and should be allowed to ...
0
votes
0answers
108 views

How to open the Attachment Editor frame in the WordPress media modal?

I am building a plugin that uses wp.media to launch a modal where the user can select multiple images to add to a gallery. There are many tutorials that explain this process and I managed to ...
0
votes
1answer
137 views

term_exists() returning NULL on term that exists

It seems that term_exists() is returning NULL for a term that already exists: $name = "כל האזורים" $taxonomy_name = "geographictermsisrael" $args = array("slug" => "everything", "parent" => 0) ...
0
votes
1answer
40 views

How to insert category name above post title in a featured pages plugin?

I'm trying to hack a plugin to insert the category name of the post above the post title in a plugin/widget that displays three posts in a single row on the front page. The hack I tried is as follows,...
0
votes
1answer
68 views

Multiple API Endpoints (wp_remote_get)

I'm trying to create a custom page with data from external API. But i need to get data on 2 endpoints $json = json_encode(array( )); $response = wp_remote_get('https://api1.endpoint.com', array( ...
1
vote
1answer
148 views

Create a plugin to change the action to which a function is hooked

I have a plugin that hooks a function on to the woocommerce_before_my_account action. I would like instead for the plugin to hook that function to the woocommerce_after_my_account action. If I ...
0
votes
1answer
50 views

get_avatar filter in WordPress 4.4, how to filter properly

Old code in my plugin replaced the get_avatar. It stopped working with the release of WP 4.4, therefore, I decided to try to learn how to use add_filter instead. There are other posts discussing the ...
0
votes
0answers
28 views

XML feed for Wordpress Social Board plugin modifications

At work, I've been tasked with modifying the Wordpress Social Board plugin by duplicating their RSS feed functionality to display an XML feed specific to our calendaring system. For example, this is ...
1
vote
0answers
28 views

Difference between wp_salt schemes

I am running a wordpress user system with 15k users/day. I have a custom message system and there is an issue in it. Sometimes (like at 1/1000 users) wp_hash that generates security nonce returns ...
0
votes
0answers
19 views

get_option() is undefined in TinymceWindowManager

I have added button to tinymce editor, which opens Popup using TinyMCE window manager and popup file is sbb-pop.php. I want to show settings using get_option() on popup window. But it throws error ...
1
vote
1answer
86 views

When is the proper time to minify css and js with git workflow?

New to web development, and have been utilizing a git repository for my wordpress website. I maybe over thinking this but here goes... Currently, my workflow is as follows: Make changes locally and ...
1
vote
1answer
31 views

How to create a backend for a custom theme?

Let's assume that there are six different pages in a website. Each page is different & only common part is header & footer. So how will you create back end such that most of the website can be ...
0
votes
0answers
62 views

Wordpress get value get_query_var('paged') of a url

Am creating a custom wordpress funtion that receives ajax url value , and i want to get the value of var paged of the received url see below code : functions.php function something() { $p= $_GET['...
0
votes
1answer
50 views

How should I go about registering JavaScript that isn't a file? [duplicate]

For a plugin I'm creating it generates custom JavaScript that should be executed in the footer of the page. Being that it's custom JavaScript, I can't simply put it in a file and register & ...
0
votes
0answers
59 views

How to add mp3 uploader as custom field in custom post type? [custom-post based plugin ]

i'm developing a plugin which is based on custom post type. i want to upload mp3 file with each new post which is my custom post. for that, i have to upload mp3 file and some meta info of mp3 file. ...
0
votes
1answer
57 views

How do you clean a filename after image sideloading a url that contains `%20`?

Right now I'm creating a plugin to sideload images from an external source. The UI allows me to select files on the external server then downloads them via AJAX & media_sideload_image. ...
0
votes
0answers
21 views

Retrieve specific field value for every menu items in nav menu

I'm added the new custom select html tag filed with two check boxes to menu items all work without any problem and i create this code within Walker class <?php if (!empty($item->normalwidth)) { ...
1
vote
1answer
81 views

Use register_taxonomy() in register_activation_hook()

I would like to use register_taxonomy() to define a hierarchy of geographical terms. It seems that the natural place to place it would be in a function called by register_activation_hook() seeing how ...
0
votes
0answers
8 views

Wordpress plugin(widget) development error logs [duplicate]

I am trying to development a wordpress widget, but for most time it's really hard for me to debug. Are there any way in wordpress plugin development that I can print something in a error_log file?
0
votes
0answers
56 views

enqueue css in a wordpress plugin condition

I have found a bug in a wordpress plugin /plugins/woocommerce-eu-vat-assistant/ In checkout page if the option "Added possibility to make EU VAT field compulsory when the customer enters a company ...
0
votes
1answer
54 views

Adding custom fields to Wordpress nav menus

I'm added new custom checkbox field to the nav menu items. the check box added without any problem when i check it it's work but when i want uncheck it not work and stay in checked state. the code ...
1
vote
0answers
98 views

Sharing a common set of image files for media library, across all sites within multisite

In mutisite, the uploads directory structure looks like this: /wp-content/uploads/sites/1/ /2/ /3/ Each number is the id of the site within the ...
1
vote
0answers
33 views

Get draggable widgets on Edit Post page

Is it possible to get the widgets with settings (just as widgets.php page) on the Edit post (like attached image) ? There i can define a custom sidebar in post meta. However how to get the list of ...
0
votes
1answer
41 views

Help me filter get_adjacent_post

I'm not keen on private posts interspersed with published posts on the front end, so I'm writing a plugin that seeks to segregate and separate them out. As part of this I want to modify the post ...
0
votes
0answers
23 views

Execute code only after user clicks 'update' button for CPT being edited

In my plugin, my custom post type posts might be updated either by a user clicking 'update' on the editor page, or programmatically. I need to execute a settings validation routine only when the ...
0
votes
1answer
34 views

Getting duplicate page when activating my plugin

I am creating a plugin in which I need to create a dynamic page and assign a template to it. I have created it using the code below: function gallerypage() { global $wpdb; $check_page = $...
0
votes
1answer
131 views

plugin_dir_url & plugin_basename not working when plugin dir is outside wordpress dir

I have been using these functions for quite a while now but yesterday I noticed that they were not working properly on a site where the plugin directory was outside the main WordPress folder. ...
0
votes
0answers
33 views

Displaying friend's posts only

So I am using the WPMU Dev friends plugin which adds functionality for WP members to search for friends and to add new friends etc. There is a specific function defined in the PHP file which says it ...
1
vote
3answers
140 views

How to determine if the current file is loaded in a plugin or in a theme?

How to determine if the current file is loaded in a plugin or in a theme? A boolean PHP function.