The tag has no wiki summary.

learn more… | top users | synonyms

2
votes
1answer
1k views

Check before publishing, if already exist post with current custom field value

I have a custom post type with only 3 custom fields in it. $post_types = get_post_meta($post->ID,'post_types',true); $post_taxonomies = get_post_meta($post->ID,'post_taxonomies',true); ...
5
votes
2answers
2k views

How to HIDE everything in PUBLISH metabox except Move to Trash & PUBLISH button

I have a custom post type (called contacts). Since this post type is not working like a post, I don't want to show SAVE DRAFT, PREVIEW, Status, Visibility or Publish Date. The only options I want to ...
2
votes
2answers
2k views

How to limit user to publish post per day and per role?

I would like to know is there any way/Plugin to limit the user published post (in a given time span) by his role? Like this: Role A -> 1 post per day and 30 post total. Role B -> 10 post per ...
1
vote
2answers
1k views

How to trap “Publish” button to check for meta box validation?

I'm trying to do some form validation on my custom meta box, and I remember somewhere reading about some javascript function to disable/enable the Publish button - except I can't find it. How do I ...
3
votes
1answer
2k views

Post publish only hook?

Is there any hook which is fired only when the post is "published" for the first time. I dont want to execute my code when the post is "updated" or when its status is set to "not-published" and then ...
1
vote
1answer
190 views

Publish Post After Click On A Link

I have a frontend posting form (CF7), where user inputs (among other data of course) his email. Now I set the status to pending. What I want is, that the user would get trough autoresponder a mail, ...
7
votes
2answers
184 views

How to prevent posts from being published too close to each other?

I manage a blog which consists of about 25 writers. Sometimes a few of them are in the process of writing a new post at once, and they end up publishing them too close to each other. Is there a way ...
4
votes
2answers
764 views

Prevent publishing the post before setting a featured image?

As the title says , I want a plugin/function to prevent/inform the user when he tries to publish the post without setting the featured image. ANY HELP ???
3
votes
2answers
591 views

WordPress prompt checklist before publish?

Does anyone have a suggested plugin that does the following: when a user hits publish on a post for the first time, it should have a popup, notice, or alert that asks the following: Do you have a ...
1
vote
1answer
1k views

Modify front-end delete button to publish pending posts

I've found this helpful snippet to make a delete post link on the front-end: <?php if (current_user_can('edit_post', $post->ID)) echo "<a href='" . ...
4
votes
2answers
699 views

How can I make it so the Add New Post page has Visibility set to Private by default?

I'm trying to create a plugin that alters the Add New Post page so the Visibility field says "Private" by default: Status: Draft Visibility: **Private** Publish immediately [Publish] ...as opposed ...
0
votes
2answers
382 views

How to show an error message after publishing a post?

I'm using the transition_post_status hook to perform some operations after publishing a post. In some conditions I would like to show an error message in a red box under "Edit Post" and above "Post ...
0
votes
1answer
46 views

featuring old articles without messing up with the archive

This is all about featuring content in WP. Say, you got 1000's of posts that you accumulated over the years and each has their own original ( and true ) post dates. And now you want to feature them ...
2
votes
1answer
518 views

When a user creates a post (pending), send a confirmation link that allows them to publish

I've got another question for you guys! I need the following thing: User creates post (automatically sets it to pending for approval) Send the user an email with a confirmation link The User clicks ...
2
votes
1answer
1k views

Publish pending article from front end with a button?

Is it possible to take the blue publish button in back end of the wordpress and place it in the frontend near the post in my index.php. I need a way to publish the pending article without going to ...
3
votes
1answer
223 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 ) { ...
2
votes
1answer
400 views

In what sequence are the hooks fired when a post is “published”?

I would be grateful if someone could point out a link. I understand this may have a very lengthy answer but I searched and couldn't find any resource. Alternatively, it would also be nice if someone ...
0
votes
2answers
1k views

Do action on publish or update?

Is there a way to only do a section of code on a template if the post has just been published or updated? What do I need to wrap around that code? UPDATE: I need to check if any of my custom-post ...
4
votes
3answers
128 views

How to let authors revise other authors drafts, but keep them from publishing?

I want to give all authors permission to edit other authors drafts, but not publish them. It seems like the only way to give authors access to drafts by other authors is to grant them ...
0
votes
1answer
285 views

How to display and use all existing tags at my write-post-at-frontend-panel?

I can write and publish posts from my frontend - everything is fine. You know the backend: write-post-style, right? There it lists all existing tags. How can I display all existing tags at frontend ...
0
votes
1answer
2k views

wp_login action hook not working

I have spent many time looking for a solution to my issue, but in vain. Your help is invaluable. I am creating a simplified badge system. The goal is to increment the number of badges for a user if ...
0
votes
1answer
364 views

run script on publish

I am trying to run a script when a user publishes / updates a post. I am using the filter: wp_insert_post_data The problem I am having is the script is a php file outside of WordPress but on the ...
9
votes
4answers
228 views

How can I delay the publishing of a page or post?

Sometimes it would be nice to be able to set a draft to be published when I'm not in front of the keyboard. Is this possible? If so, how?
3
votes
3answers
1k views

How can I set a draft page as parent without publishing?

Anyone know a way round this? http://wordpress.org/support/topic/set-draft-page-as-parent I can't risk publishing as a public-facing system updates periodically from the same install.
2
votes
2answers
697 views

add action only on post publish - not update

I have action which adds meta field with value on post publish. Problem is that when I update post meta field is reset to default value. I already tried 'new_to_publish' instead of 'publish_post' ...
1
vote
3answers
367 views

How to access the post meta of a post that has just been published?

I am using the hook publish_post to run my code where I need the post meta of the just published post. But the post meta value I am looking for is somehow not available at this point of execution. On ...
0
votes
1answer
446 views

publish_post action hook not working

I've got a really simple problem here, and i'm sure that the solution is going to be really simple. Here is the code: function the_fat_lady_sings() { echo 'this plugin is a far harder than i ...
0
votes
2answers
963 views

Stop wordpress from creating empty/null entries

Fiddling around with a custom post type which is quite heavy modified. Started doing some testing to see if I had broken some function, and realized that wordpress doesn't have a function that checks ...