Tagged Questions
0
votes
0answers
16 views
Display recent commented post above new submitted post
I have a list of all posts that are commented on a particular day. If someone comments a post, I want it to put that one above the other posts, even if they are submitted on a more recent date...
How ...
2
votes
1answer
42 views
How to add a “publish” link to the quick actions
I'm trying to add a "Publish" link by the quick actions:
but I'm not exactly sure of how implement it.
Here's what I've got so far:
add_filter('post_row_actions', function ( $actions )
{
...
-1
votes
1answer
37 views
Search from Post on the basis of custom fields
I have shown all the Post on a page. Where i want to add Filter for sorting Like Date and other Custom Fields.
So how can i Do this Please Help me.
0
votes
1answer
60 views
add <div> to end of post in the loop with plugin
I'm looking to add a <div> with some more html content to the bottom of specific posts in the loop. The the_post action can be used to add the <div> to the beginning of the post in the ...
0
votes
2answers
141 views
Removing any and all inline styles from the_content()
For one of my current projects, I had to transfer blogposts from an old Wordpress site to my project.
Things went smoothly until I've seen that all the posts were copy pasted from Word, leaving this ...
0
votes
1answer
26 views
Filter post before *editing*
I know there are a lot of hooks in WP for altering a posts content (and other fields) before the post is written to the DB upon saving; but what I am interested in doing is running my custom filter ...
0
votes
2answers
44 views
wordpress remove views from action links in a custom post
I have created a custom post type, but I want to remove the View link from actions, in the listing of the custom post.
I have tried this snippet
add_filter( 'post_row_actions',array(&$this, ...
0
votes
1answer
135 views
Filter/Remove HTML Elements on all posts and pages
I'm working on a migration from Drupal to WP. The database conversion and import went smoothly, but there is a lot of 'crap' in each post content such as divs with inline styles. Basically, in each ...
1
vote
1answer
140 views
How to filter posts that belong to a specific category only if that is the only category
I need to filter posts that belong to a category only if that is the only category. For example if my post A belongs to cat1 and I don't want to display posts that belong to cat1, post A won't be ...
0
votes
1answer
93 views
how “manage_posts_custom_column” action hook relate to “manage_${post_type}_columns” filter hook?
How add_action("manage_posts_custom_column", "custom_callback_fun01"); relate to add_filter("manage_{xxxx-xxx}_columns", "cusotm_callback_fun02" );?
How do they both work together? By using these ...
0
votes
1answer
172 views
How to allow visitors to filter posts by multiple taxonomies
I am trying to allow users to filter a custom post type list by multiple taxonomies. For Example lets say my custom post type is clothing and it has two custom taxonomies brand and type associated ...
0
votes
1answer
72 views
changing parent_id on post
I'm trying to change a post's parent via the wp_insert_post_data filter but I'm not having any luck. In the example below, I'm replacing any "parent" references with the id I want to set.
function ...
0
votes
1answer
324 views
How to remove_filter that filters iframes in posts?
Which filter if removed allows iframes to be inserted into wordpress posts?
0
votes
2answers
642 views
wp_list_categories() Exclude All Categories Except One
Is there a way to exclude all categories except one? I want to show a category and it's sub-categories as a dropdown menu, but the admin might add more subcategories to it so I don't want to limit ...
0
votes
1answer
1k views
Filter Posts By Tag
I'm trying to filter my posts by category, then further by city. The only way I can think of filter by city is if the admin adds the city to the listed tags and then filtering from there via switch ...
0
votes
1answer
1k views
How does filter the_posts work?
I don't want to display post with empty body / post_content on my home page. So I added below code to my function.php. It detects post with empty body but it still display them. I expected that if I ...
0
votes
1answer
306 views
Modify posts listing at back end
I want to modify posts listing at back end?
Say, for a particular user, with role author, O want to list only few posts at posts listing. How can I do this?
1
vote
1answer
161 views
How to take options from form fields and turn them in to links?
I have a form in WordPress with options when clicked they retrieve a filtered posts. I want to take the options from the form and place it like normal links. Can this be done? Thank You all in advance ...
3
votes
1answer
323 views
Update post counts (published, draft, unattached) in admin interface
I am working on a multi-user WordPress setup and have made it so a particular type of user can only see and interact with posts, images, pages etc that they have authored. The code to make this happen ...
3
votes
3answers
753 views
How to publish a post with empty title and empty content?
Why I'm doing this you might ask? I'm developing a website for a business with a portfolio where the gallery items are posts. These posts are populated through custom fields and category selections, ...
0
votes
1answer
245 views
Get current taxonomy and display query accordingly
Okay i'm having a bit of a catogorisation/taxonomy/filtering problem here and am at loss on how to solve this.
I hope someone could help me on the way a bit.
Say I've got a blog about food, with a ...
0
votes
1answer
1k views
Getting post id from wp_insert_post_data function?
I'm trying to use the function get_the_tags() from outside the 'loop'.
I understand this can be achieved by using the post ID like get_the_tags($postID). Does anyone know how I can get the post ID ...
0
votes
1answer
333 views
Trying to exclude custom posts based on date, while sorting by custom field
I have a custom post type named "performance". I have a custom post query that orders posts by a custom field value (order-date). Now I want to exclude posts that have order-dates that are in the ...
0
votes
1answer
167 views
Filtering posts on Post Administration Page by Week Number instead of by Month
Has anyone written or can suggest a plugin that would replace the filter-by-month in the Post Administration screen with filter-by-week-number instead?
e.g. a drop down option for "Week of ...
0
votes
2answers
450 views
Add filter to the end of the post
I have a function which is used to display a video,
I want this video to be shown after the post,
It should display the video when the post ends.
I have added filter to it, but then too, the video is ...
0
votes
3answers
448 views
How to retrieve the postID in a “image_send_to_editor” hook function?
Here is my function:
function insert_img_rel_attrib( $html, $id, $caption, $title, $align, $url )
{
$postID = ???
$rel = "<a rel='shadowbox[".$postID."]'";
if ($url) {$html = ...
1
vote
2answers
1k views
Filter Home Page Posts in Buddypress
I would like to remove blog posts from the home page if they belong to a certain category. How can I go about this in Buddypress (preferably without a plugin)?
0
votes
2answers
5k views
how to display post content without post image?
i've implemented a jQuery gallery for displaying several images within a post.
the problem is that the_content(); also displays the post image.
any ideas how to filter it?
thanks