Method by which plugins and themes extend core WordPress functionality.

learn more… | top users | synonyms

0
votes
1answer
13 views

Genesis: How to add content after aside and before the content-sidebar wrap

Fail #1: The hook, genesis_after_content, allows me to add content directly after the <main> tag and before the <aside> tag. So in a content first, sidebar second configuration, it would ...
1
vote
1answer
22 views

Is it possible to modify the media library admin screen?

I've been searching for a few hours now but I can't seem to find a solution to this. I'm developing a plugin and I'd like to be able to add custom text underneath the admin media library heading. I ...
0
votes
0answers
34 views

How to disable wp_trim_excerpt filter

I have a Divi child theme. I'm using the blog module to list out the blog posts. If the post excerpt field is empty, I don't want the post contents to be extracted instead. Having Googled, I came ...
0
votes
0answers
16 views

creating posts from excel random number of posts are created

I'm creating a plugin to import posts from a CSV file. The plugin is creating posts, but a random number of posts are created with an infinite loop. I have checked the while loop and for loop, they ...
0
votes
0answers
19 views

How to find all the available hooks in a theme

I have invested time and money on a Wordpress theme with a terrible support service. I have to fix bugs and implement new features myself. But I prefer to do it through filters and hooks. For example:...
-3
votes
0answers
21 views

Gravity Forms Dynamic Population Pre_Submission Hook

I'm not very savvy with Jquery. Can you help me embed it on a single wordpress page so that it can act on my Gravity Form? I have a gravity form with an interactive google map in it. There are two ...
0
votes
1answer
20 views

What is the action hook to use if you want to capture the new password during password change?

Clicking the Update Profile button in the [wordpress]/wp-admin/profile.php admin screen will allow the user to update his/her profile including the password. What is the right action hook to use ...
0
votes
1answer
30 views

Does WordPress have something like timer hook?

Are there some timer hooks to trigger event like this? add_action("one_min_timer", "my_handler"); function my_handler() { //checking something every 1 min }
1
vote
0answers
25 views

How to get list of all hooks of current theme / plugin?

I want to get the list of all available hooks from active theme / from a specific plugin. I was tried to get it from global variables $wp_actions & $wp_filter But, They are showing all registered ...
0
votes
0answers
20 views

How can I get post meta data (custom field) from within a custom wordpress action hook?

I have a custom hook in my theme which is set up like this: do_action('my_custom_hook'); That code is in my header.php file and outside of the main loop. I have a call to this hook like so in my ...
0
votes
1answer
87 views

Add Adsense code between job listings - wp job manager plugin

I am using the wp-job-manager plugin and i want to add an Adsense code between the job listings ( after fifth job listing ) in the page with [jobs] shortcode. The function that outputs the jobs ...
0
votes
1answer
26 views

Comment Approve - Add custom function when comment is approved

I would like to save some PHP memory when quering category page (like 5000 products at once) with average review rating, so I would like to save average rating of reviews every time I will manually ...
0
votes
1answer
37 views

wp query add array by if condition

I am trying to output list by a condition. I am trying to create a plugin and the plugin addon. when the plugin addon activated, the condition should be fired. Condition 1. if admin or editor or ...
-1
votes
1answer
33 views

How to string lines from the_content() hook in WordPress?

Inside my content-video.php template, I have the following codes: <iframe src="<?php echo get_the_content(); ?>" width="960" height="540" frameborder="0" allowfullscreen="allowfullscreen">...
3
votes
1answer
55 views

'post_type_link' filter not working

I know it should work fine, don't know if this is a recent bug or something. So, to confirm it, I installed a fresh wordpress using default theme. I made a small plugin like bellow: <?php /* ...
1
vote
0answers
23 views

Edit page slug after save, cause 404 by linked pages

I have two page bar page at url: http://www.example.com/bar/ foo page at url: http://www.example.com/foo/ bar page link to foo page in content, eg.: <a href="http://www.example.com/foo/">...
0
votes
1answer
32 views

Move jQuery on *top* of footer

I am using this code by Peter Wilson to move jQuery to footer: function pwcc_jquery_to_footer( &$wp_scripts ) { if ( is_admin() ) { return; } /* Move jQuery to the ...
1
vote
1answer
84 views

Best possible way to get all options

I need to provide a list of all options set via plugins etc to remote calls. There is a plugin WP API Options but it hardly does the job. There are two possible ways (that I know of) to get a list ...
3
votes
1answer
78 views

Hook/notify when any option or setting is added or updated

I know about: add_option_{option_name} update_option_{option_name} but these need specific option names. What I am looking for is a way to know if and when any option is changed (added or updated). ...
2
votes
0answers
23 views

Remove and restore one shortcode

I would temporarily remove a shortcode, make something and restore it... it's possible? // override default wordpress "the_content" hook remove_filter('the_content', 'do_shortcode', 11); add_filter('...
2
votes
2answers
89 views

do_action and hook methods

I am trying to understand how hook methods work in WordPress. I understand that when do_action is called WP looks for all registered listeners and invokes them according to set priority. How does ...
3
votes
1answer
31 views

Generic plugin (de)activation hook?

I am looking for a way to track which user activates or deactivates a plugin for logging purposes. I've been searching around, but can only find information for plugin developers to have a hook to (de)...
-1
votes
1answer
37 views

Why functions metaboxes is causing White Screen in Admin [closed]

I am having an issue after migrating a project to other server. When I go to /wp-admin I am getting a 'White Screen of Death'. If I access to /wp-login.php instead I get the login form but with an ...
8
votes
4answers
266 views

Is it possible to completely stop WP_Query retrieving posts?

I'm trying to use WP Redis to cache entire $wp_query object with key is $query_vars_hash. This is how $wp_query was added to $wp_object_cache: add_action('wp', function($wp) { if ( is_admin() ) ...
1
vote
1answer
27 views

How to use a hook to override an update_post_meta call in a plugin?

A plugin I'm using contains the following code: $download = array( 'post_title' => $title, 'post_content' => '', 'post_status' => 'publish', '...
2
votes
1answer
31 views

Is there a filter hook that I can use to change how taxonomy term names are displayed?

I need to hide a custom taxonomy's terms' names on the frontend while preserving them on the backend. Instead of the terms' names I need to display pseudonyms. I can't find a single filter hook to do ...
1
vote
1answer
32 views

Custom Front End Registration - How Does the Key work in the Password Set Request?

I've been working from some tutorials on building a front end registration / login system. Specifically this link - http://cubiq.org/front-end-user-registration-and-login-in-wordpress Everything is ...
0
votes
1answer
18 views

Adding user filter - Not updating data in URL

What I am trying to do I am trying to add a filter option by adding a dropdown menu that i have hooked onto restrict_manage_users, so i can filter users by a specific meta value. My problem When i ...
3
votes
1answer
22 views

What function to hook for changes made in status and visibility of a post

I have a function to run every time a post is published or updated in anyway. Right now I am doing function myFunction(){ //Do Something } add_filter('publish_post','myFunction'); add_filter('...
0
votes
0answers
15 views

There is any hook that fires after/before updating menus locations in “Manage Locations” tab?

I'm looking for hook that fires before or after updating menus location. I want to fire function after saving on "Manage Locations" tab in Appearance > Menus. I know there is wp_update_nav_menu ...
4
votes
0answers
33 views

Admin settings update updating every time home page is hit?

I have created a plugin that sends an email with all orders placed that day by X o'clock to email Y. I followed the tutorial here: https://scotch.io/tutorials/how-to-build-a-wordpress-plugin-part-1 ...
0
votes
0answers
17 views

On update, set post status to 'draft'

In my website I have created a custom post type named "Activities". A certain user group is able to add/edit these posts. I'd like to set the post type to "draft" each time a user (not administrator) ...
0
votes
1answer
18 views

Hook to change Author Info

Is there a hook or filter that will allow me to change the author of a post when someone views the page? Thanks!
5
votes
0answers
38 views

Adding a drag and drop re-ordering from a custom post type default list

I have custom post type named 'slider_to_be_ordered' and has the following arguments enabled: 'supports' => array( 'title', 'page-attributes' ), 'hierarchical' => true, ...
0
votes
2answers
39 views

Admin page and admin menu. Permissions plugin

I was googlin really hard but couldn't find any answers. What i'm trying to do is write a simple permission admin page plugin. So far what i did a page with every role where i can check a certain ...
1
vote
1answer
31 views

Understanding WP

Sorry if this is a newbie question. For designing a woocommerce catalog page i usually copy woocommerce template folder into theme folder and start editing that (overriding template). I see there are ...
0
votes
0answers
13 views

Best way to change the author's name on view only

I'm developing a plugin that allows users to sign in and make posts. However, I have a substantial number of users and don't want them to be added as users in WordPress's user database, so I have my ...
1
vote
0answers
22 views

Wordpress form. Variables to display on other page? [closed]

I'm using Ninja Forms, and I'm working on a form where when the users presses "ok" then the page is supposed to go to another page which shows specific information and links for that user. Right now ...
0
votes
1answer
22 views

Modifying the wordpress login page and then referencing it with a shortcode problem

Both parts are working great separately. I have made the shortcode for the login form with: //register new shortcode add_action( 'init', 'my_add_shortcodes' ); function my_add_shortcodes() { ...
5
votes
1answer
58 views

How to customize the WP admin default help contents

I will be needing to customize the WP admin default help contents to be tailored specifically to a client in navigating his custom dashboard What are the hooks and sample codes to use in ...
0
votes
1answer
33 views

How to append custom text to the output of 'categories widget'?

How do I customize the "categories widget" to append additional text on the sidebar display? from category 1 category 2 category 3 category 4 to category 1 folder category 2 folder category 3 ...
2
votes
1answer
28 views

How to exclude certain widget from showing up on home/front page? [duplicate]

Without using a plugin, how do I prevent/exclude the sidebar widget "recent posts" from showing up on the home/front page? I do want it to show on the sidebar of rest of other archive/post pages.
1
vote
0answers
43 views

Shipping Options in Fedex Plugin for WooCommerce [closed]

I am a longtime PHP developer but new to WooCommerce and plugin development. I have a need to limit the transit time for certain perishable items. Therefore, I cannot always offer Fedex ground, but if ...
9
votes
2answers
173 views

What is “all” in isset($wp_filter['all])

I'm a newbie in WordPress. I'm trying to understand how it generates the XHTML pages. I guess it's the function of do_action( 'hook-name' ) , but I'm stuck with the understanding of the instruction ...
1
vote
1answer
34 views

Insert term when page is published - avoid duplicates after edits

So i want to dynamically add terms to a custom taxonomy named after new pages when these are published. Problem I have is that when you edit the page titles, another term will be added to the taxonomy....
-2
votes
2answers
98 views

Customise Jetpack Publicize text

EDIT: Due to downvotes (with no comments!), I've edited this post to be a bit more specific... Why isn't the following change working? $custom_message = get_the_title( $post->ID ) .''. $hash_tags;...
0
votes
1answer
38 views

Show modified time if post is actually modified

I want to display post updated time only if post is modified, I am using function the_modified_time() . So I just read about that there is if statement that can be used to check if post is even ...
2
votes
0answers
32 views

__NAMESPACE__ with register_activation_hook

Im teaching myself namespaces and OOP in wordpress at the moment so bare with me. In the base of my plugin I'm loading activation and deactivation hooks. Currently the deactivation hook works but ...
1
vote
1answer
52 views

External Authentication, session_tokens not destroyed on logout

There are many questions and answers on external authentication and some code prior to WordPress 4.0 need some tweaking to get them to work. For example, adding a fourth parameter to the ...
0
votes
1answer
27 views

I need to hook and change language of facebook sdk

I need to hook into this function to change language to from en to french facebook sdk. $facebook_sdk_src = apply_filters( 'bimber_facebook_sdk_src', '//connect.facebook.net/en_US/sdk.js#xfbml=1&...