A type of hook that provides a way for content to be overridden programatically

learn more… | top users | synonyms (5)

0
votes
1answer
17 views

Problem with Class, Filters and Callbacks

according to this Callback example if I'm referencing a method inside a class, I should use add_filter by specifying an array with 2 elements, first the object then the method. Here is my code: ...
0
votes
1answer
15 views

Jetpack Comments Change Placeholder Text

Is there a hook or template file where I can change the placeholder text on the #comment textarea w/in the comment form? Jetpack loads the form via an iFrame which prevents changing the placeholder ...
0
votes
0answers
17 views

How do I sort woocommerce grouped products by post date instead of menu order? [closed]

What code/filter can I add to my wordpress functions.php file to modify the order of grouped products by post date instead of menu_order? class-wc-product-grouped.php $args = ...
0
votes
2answers
25 views

Firebug and Chrome rendering two body tags

I have a curly problem I've been working on for some time. At first it appears as if the get_body_class() function was broken but after I removed it from the template the issue persists. <html ...
0
votes
1answer
13 views

shortcode which is introduced into entry the blog, and appears in side bar

I have the following shortcode plugin, it works perfectly, nothing more I want to put you in the blog and appear in the sidebar, how I can accomplish this? I want not put a widget in the sidebar, ...
0
votes
0answers
19 views

When to hook into edit profile action?

I have the following function which combines the values of a few user profile fields and saves them as a new user_meta called COMBINED_WORKSHOPS. The function works, but I don't know when/where to ...
11
votes
2answers
415 views

Disable emojicons introduced with WP 4.2

So WP 4.2 introduced emojis (smileys) that basically adds JS and other junk all over your pages. Something some people may find shocking. How does one completely erase all instances of this?
0
votes
0answers
12 views

Show child theme for users on specific IP

I have some users coming in from a fixed IP range on a very slow connection (256kbps) so want to server them a child theme that has a lot of the bandwidth intensive features removed. For ease of ...
0
votes
0answers
15 views

Filter meta data for simple and variable products on custom query [closed]

I have a custom query loop on a page using WP_Query and I want to filter by certain meta keys _price, _weight, _width, _height, _length, total_sales. I am able to get this working with both simple ...
1
vote
0answers
15 views

Custom filter function not working with Custom post type

I have custom post type "soto_property". I have made a custom filter to filter post listing according to used meta data named "operations". Here is my code- <?php add_filter( 'parse_query', ...
2
votes
0answers
33 views

How to make a widget expand wider than the column width when editing its settings in the admin

The WordPress Text widget expands horizontally beyond the margin of the sidebar when added to a sidebar and opened in the admin and I am trying to apply that function to a widget. I see inline css is ...
0
votes
1answer
12 views

How to add filter for wordpress plugin?

I have a really newbie question, but I'm really new to WordPress development. In the plugin that I'm using is using this filter. if ( true === apply_filters( 'some_custom_filter', false ) ) { ...
0
votes
1answer
14 views

How to replace all images in all posts and pages with a different size?

I'm about to reboot an old blog of mine and therefor I'm creating a new theme from scratch. Before I'd align pictures left and right, because it seemed good. But now I want to make it much cleaner and ...
5
votes
0answers
36 views

How to add taxonomy filter on the query fly?

I try to add tax query on pre_get_posts hook using following code : // Add custom posts to main query (archive and home) add_action( 'pre_get_posts', 'add_post_types_to_query' ); function ...
0
votes
0answers
20 views

How to get all the predefined do_action() calls from an active theme

To hook my plugin content into anywhere, suppose I offered the theme developers to create their own hooks with a prefix (pre_) anywhere in their theme - the rest of the hook is unknown to me. So what ...
0
votes
0answers
17 views

Avoid changing menu query with suppress_filters => false

I recently had to change qTranslate for qTranslate X since the former is not being updated. This broke my menu and after searching I found it was because qTranslate X sets suppress_filters to false. ...
1
vote
1answer
26 views

Get posts with at least one category in common with current post?

In single.php : I want to get all posts with at least one category in common with the current post. I tried reading through the wordpress codex documentation but I found it rather confusing (I'm ...
0
votes
1answer
9 views

Display child pages on homepage template

I thought this would be a simple case of following the Codex but apparently not. I'm trying to display child pages of a particular page on my homepage using a custom made template. So far I've managed ...
0
votes
1answer
49 views

Woocommerce Price Text

I'm trying to show after the price of my product, whether the price is 'per person' or 'per group'. I've created a custom field for both, so for example, if custom field 'price_per_person' is ticked, ...
0
votes
1answer
31 views

what is do_action(); in wordpress? [duplicate]

Sorry for making duplicate Topic but it is very important to me because i don't understand this topic by looking other related topics. Actually i am in process to build a WordPress theme and i am ...
0
votes
1answer
29 views

How do i get all author posts on custom post type list

I am trying to filter a custom post type by some custom fields value and if the posts are by author, query for 2 custom field works but author posts doesn't work. Thanks! add_filter( 'parse_query', ...
0
votes
1answer
37 views

add_filter does not work as expected

I have a wordpress plugin where i included this (with some changes) $fep_files = array( 'first' => 'first.php', 'second' => 'second.php' ); $fep_files = apply_filters('include_files', ...
0
votes
0answers
13 views

How to filter displayed posts like what we can see on products page

I wanna know if there is a way to filter displaying post on clicking on menu or a link. I know that there is some ways for admin post list, but i want it for front pages. I think we can do that by ...
0
votes
1answer
32 views

remove_action not removing add_action from constructor

I am trying to replace a message from a function that got hooked in a constructor from a class from woocommerce. This is what I tried to remove the message: What I tried. function remove_actions() ...
0
votes
0answers
11 views

Click on link to filter displayed posts like what we can see on products page

**I wanna know if there is a way to filter displaying post on clicking on menu or a link. I know that there is some ways for admin post list, but i want it for front pages. I think we can do that ...
0
votes
1answer
15 views

Custom filters inside a specific category?

I have different categories that require different filters For example a 'training' can be about a specific bodypart, by a specific athlete,.. What I want is something like this: But different ...
0
votes
1answer
42 views

Filter keywords from search query

I have search over the google, somewhere out there and here(http://wordpress.stackexchange.com). But, i can't seem to get the solution i was looking for. I would like to ask that, is there any ...
0
votes
0answers
19 views

add_filter('body_class') running from widget even when widget is not loaded on page/post

This should be adding a function to init() to check if the widget is active widget on the front end on a page/post - but even when the widget is not loaded on a page/post, .Widget_FilterProject is ...
0
votes
0answers
12 views

Filter displaying posts

I wanna know if there is a way to filter displaying post on clicking on menu or a link. I know that there is some ways for admin post list, but i want it for front pages. I think we can do that by ...
0
votes
0answers
18 views

Adding 'query_vars' filter redirects to the latest posts page

On our main page we tried to use an additional query parameter to keep in session and use later. Instead of browsing www.example.com/mywp, the user is now browsing www.example.com/mywp?param=value and ...
0
votes
0answers
8 views

Why WordPress attachments LINK TO settings are not working?

Using this code below, I added some on-hover share icons for all images of the content. But, now these images are not getting any "Link To" setting from authors. I don't know what is the problem. Can ...
0
votes
1answer
26 views

Custom display for homepage, tag and author pages

I need to have pages where the first post on the page has a special format. I've figured out how to modify loop-home.php to get the result I want outputted on the homepage. I want to have the same ...
0
votes
0answers
30 views

Custom Post Type and Taxonomies

I hope someone here can help me with a bit of a problem. I am working on a WP site where I have created a Custom Post Type called Retailer. In there I have three taxonomies Country, Region and City ...
0
votes
0answers
8 views

Journaling… Problem with comment duplication checks

This may be more of a request for advice than anything... I want to add a Journaling function into my plugin whereby all actions are logged. My initial thought was to use comments as it seemed to be ...
0
votes
1answer
25 views

How to use the filter 'widget_text' to a particular text widget with id

I have a sidebar with 10+ text widgets serving advertisements. Now I want to filter a particular text widget in a single post if that post has a data in meta field. I searched a lot and found Is There ...
0
votes
0answers
19 views

How to filter between two menu items

Right now my menu is something like this: <ul> <li><a href="#">item 1</a></li> <li><a href="#">item 2</a></li> <li><a href="#">item ...
-1
votes
1answer
32 views

From child theme remove class which is added by parent theme?

So the parent theme adds masonry in the body class by function water_lily_body_class( $classes ) { if ( !is_singular() && !is_404() && !is_author() ) $classes[] = ...
0
votes
0answers
11 views

How to use remove_filter if filter declared in a class? [duplicate]

I have a 3rd party plugin that declares a filter that i want to fully replace. The problem is there is no class variable to call upon. From the codex: global $my_class; remove_filter( 'the_content', ...
0
votes
0answers
12 views

Why are the terms of Product attributes in the table wp_term_taxonomy showing a count of 0?

im installing a plugin called Woocommerce Product Filters which is a filter system for products as its name may suggest. THe problem im having is when I turn on a number of attributes to filter by, ...
0
votes
0answers
21 views

Search Authors, Filter by custom taxonomies in their posts?

I have a website where users will post their past jobs (custom post type) and choose attributes (custom taxonomies) to describe the type of job and responsibilities. I would like to be able to search ...
0
votes
1answer
35 views

How to filter posts in admin by before date or by post status 'future'?

I have read/searched a ton of questions but all I find seem to be related to custom post types and such. The situation is that sometimes we happen to have a lot of posts waiting for to be published ...
1
vote
2answers
25 views

how to change appearence of the content of default post list columns?

Speaking about backoffice here. I usually add columns and filters to the backoffice for certain custom post types. No problem here. BUt what if I would simply like to change something on the content ...
1
vote
1answer
36 views

Adding custom column to comments admin panel?

How do I add a new custom column to wordpress wp-admin/edit-comments.php page ? I tried this but did not work. add_filter( 'manage_comments_custom_column', 'add_new_columns' ); function ...
0
votes
0answers
25 views

Limit Taxonomy Parents

I've got a custom taxonomy set up as hierarchical, with a custom function to limit the number of categories the user can select to one. I also need to limit the depth that this custom taxonomy can ...
0
votes
1answer
18 views

Trying to get property of non-object in shortocde

I'm having error in shortcode that "Trying to get property of non-object" on line no 130 Here is code: while ( $our_work->have_posts() ) { $our_work->the_post(); $termsArray = ...
1
vote
1answer
26 views

Insert other menus as submenus of a main menu

I have a main menu which features items for each of my service cpts. Each of those cpts has another menu associated with it, the id of which I grab using the ACF get_field function. What I'm trying ...
0
votes
1answer
36 views

Problem in outputting shortcode

This is my 2nd question about shortcode as I'm learning shortcode. Here is my code: add_shortcode('work-shortcode', 'work_shortcode'); function work_shortcode() { $return_string .= '<div ...
1
vote
2answers
45 views

Filtering Comment Reply Links (comment_reply_link_args) for “infinite replies” in nested comments

Since 4.1, WordPress has made the filter "comment_reply_link_args" available, apparently (?) with the intention of letting us intercept and modify particular options normally set in the admin panel as ...
0
votes
1answer
36 views

Replace image scr with it's surrounding href

I'm trying to add a filter to the content to replace the src of all images in the content with it's surrounding href link. Any ideas how to go about this? The only thread I could find that came close ...
2
votes
1answer
44 views

Filter media library items by size

I want to prevent users from being able to set a Featured Image from the media library if its width is less than 100px. Originally I thought to use the ajax_query_attachments_args filter, but it ...