The tag has no wiki summary.

learn more… | top users | synonyms

0
votes
1answer
116 views

Custom Meta Box Causing Error: “Are you sure you want to do this? Please try again.”

My custom post type have a meta box that is listing another custom post types in its meta box. And it is causing error each time I try to publish a post with that custom post type. It is always bring ...
0
votes
0answers
46 views

How to preview and publish multiple drafts?

How can I as administrator preview all post drafts like in a regular archive, with simple "publish" and "trash" buttons/links for each post? Do I need to develop a plugin or could this be done simply ...
1
vote
1answer
181 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, ...
0
votes
3answers
427 views

Can't publish custom post type - “You are not allowed to edit this post.”

Hey guys I've created this post type but when I click the publish button I receive the message: You are not allowed to edit this post. Have I done something wrong in my code to disallow anyone ...
1
vote
0answers
41 views

Controlled publishing in Wordpress

We are currently rebuilding our corporate website and I'm looking for a way to control the publishing of pages. The flow to create or amend pages would be something like this: 1) New page is built or ...
0
votes
2answers
77 views

check if a draft has been moved there from publish to draft

I am writing a plugin, part of the functionality does functions on hook: publish_to_draft I then later want to re-publish that post and trigger specific functionality to see if it has previously been ...
0
votes
0answers
45 views

Contributors can still publish content after user downgrade

I'm trying to slowly hand over WordPress access to other site users but when I downgrade their user type from "Author" to "Contributor," I'm finding that WordPress isn't restricting their respective ...
0
votes
1answer
107 views

do more action after I publish a post

I am using wordpress3.5, I need to write post information to a file after I publish a post successfully. What I am not know is When I click Publish button, what function wordpress invoke to save ...
7
votes
2answers
181 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 ...
0
votes
2answers
147 views

How to add correct Last update in Postings (the_modified_time)

Having little issue with following: We want to add "Last update" after making important corrections or additional text/images to existing Postings. Using following code (hardcoded) does in a way ...
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 ...
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
65 views

an action hook when a post reaches a certain number of views

I am using WP Post Views plugin to display the post number of views. I use: <?php if(function_exists('the_views')) { the_views(); } ?> I am creating a badge system for my wordpress site. My ...
0
votes
1answer
271 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 ...
2
votes
1answer
177 views

Scheduled Posts and wp-cron - Why don't scheduled posts publish if too old?

I notice that the documentation for wp_schedule_single_event mentions the following:- The action will fire off when someone visits your WordPress site, if the schedule time has passed. However ...
2
votes
2answers
2k views

How can I make post fields required in Wordpress?

I am setting up a Wordpress site as a CMS and trying to figure out a way to make certain post fields "required" before an author can publish a post. In particular, I want authors to be required to ...
0
votes
2answers
255 views

Detect Post Type when publish_post is ran

I currently have WordPress build an XML Sitemap everytime a POST or PAGE is PUBLISHED by using this Action... add_action("publish_post", "create_news_sitemap"); I am not doing the same process but ...
3
votes
1answer
218 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
vote
1answer
378 views

Update post meta on bulk edit / update

I have a small problem with a code that works most of the time. I just discovered it cannot be used when I bulk edit custom post type. If I'm on individual post page and hit publish, the custom post ...
0
votes
2answers
76 views

How to show or hide a post based on meta_value selection?

How would I go about hiding a post based on a meta_value selection done on the back end. The usual method is to just change the post status from Publish to Draft however, I want this to work based on ...
0
votes
2answers
55 views

I want my post to republish again after adding a custom field

I wanted a code in Wordpress that could allow me to republish the post every time I add a new custom field. For example, if I already have a post and wanted to add an update to it; I want it to appear ...
1
vote
2answers
61 views

Make the Status, Visibility, or Date fields opened by default in the Publish box

By default, the Status, Visibility, and Date fields in the Publish metabox are closed, and you have to click Edit to show them. Is there a way to make these fields visible by default? The hidden ...
1
vote
2answers
560 views

Auto Publish On Cron

I have some 100 unpublished posts. I want to publish 1 random post every time a cron is run. Is there a way or plugin to achieve this...
0
votes
1answer
2k views

Force Publish Future (Scheduled) Posts Immediately [duplicate]

I am trying to force publish 'future' or 'scheduled' posts, and I am having trouble The reason I am asking is because I am creating a site that allows users to do the editing on the front of the ...
2
votes
2answers
1k views

How to make scheduled post preview visible to anyone?

When I write a post and schedule it for later publishing, WordPress will allow me to preview the post as if it was already published but I need to be logged in as administrator (or anyone who is ...
2
votes
1answer
409 views

Why does publish_{custom-post-type} fire on update?

I'm trying to fire two different actions on both publish and update. Neither should ever fire at the same time. The problem is that publish_pm_task is getting fired on update and save_post is never ...
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 ...
0
votes
3answers
202 views

Default pages to be unpublished - possible?

Is it possible to change the default status of every new page created to be "unpublished"? We want to have someone help us add pages to a site, but not have them show up by default until it is (all ...
0
votes
1answer
96 views

Showing the next post's title, even if it's an unpublished post

At the bottom of each post I need to either: Offer a link to the next post (if the next post is published); or Display the title of the next post with the date it will be published (if it's a future ...
4
votes
2answers
687 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 ...
2
votes
2answers
682 views

How can I add a jQuery OnClick event to the Publish posts button?

I want to add a simple confirmation event to the Publish posts button, so when my client hits "Publish" it will ask him if he's sure, to which he clicks "Yes" or "cancel" and the post then publishes ...
0
votes
1answer
93 views

Plugin that generates a page of post content

My script is generating a duplicate post even after I explicitly state that the post_type should be a page. It also ignores the $post_title, which I do not want to create a duplicate post if the title ...
0
votes
1answer
410 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 ...
1
vote
2answers
234 views

get_terms on save_post hook

Usually, if I want to check for some attribute of the post I'm about to publish, I will check like this: $post_title = $_POST['post_title']; post_title is the name of the title field in the edit ...
0
votes
1answer
76 views

i am making text changes on my page show in preview not on live site, why? [closed]

I go into the admin back room on my site make text changes and hit preview changes and they show up, but when i go to the live site, they don't show at all. What am i missing, what should i be doing? ...
0
votes
1answer
240 views

Publish page by invoking submit via jQuery

I'm looking for a solution to a bug that occured in an answer to an earlier question. The general idea is that I want to invoke submit on the post form and have the page published. What happens now ...
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='" . ...
0
votes
1answer
771 views

Check if post id exist in table than only update instead of inserting new row

I am trying to add simple view counter for my advert and everything seems works fine with below code but only it is inserting each time new row on post "Update". What I want if the post id is exists ...
1
vote
2answers
992 views

Elegant way to include only published posts with get_objects_in_term()?

The obvious way is to iterate through the resulting array of IDs, get_post for each and test against post_status == 'publish'. But I wonder whether this could cause memory issues since get_post will ...
1
vote
0answers
77 views

Copy post to separate database with “add_action(…)”

I'm basically trying to have a copy of a post be sent to another database's table when it's published. I've gotten it to add a new row in the new table, with my own static arguments, but I'm not sure ...
5
votes
4answers
163 views

Display a post's publish date from 2112

So I am making a news website about the future, 2112 to be specific (hello, critics). I wanted to display a post's date to be from 2112. But when I try to do this from the admin panel, it 'schedules' ...
-1
votes
1answer
210 views

Can't publish posts, Jetpack won't connect, empty notification emails to my inbox

I own a self-hosted Wordpress blog and I am experiencing a lot of issues: Jetpack stopped working and it won't connect: verify_secrets_missing : The Jetpack server encountered the following client ...
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
79 views

Change Post and CPT author on the fly while publish the post

I am developing my site and require to change post author id on the fly while publishing. All post will be write and publish by admin but as content provided by different author and need to change ...
4
votes
1answer
354 views

Custom post type capabilities

I've got a somewhat unique scenario that I would appreciate some assistance with. I have a custom post type, coin, for content that is automatically created by an custom import process. I would like ...
0
votes
1answer
236 views

Display password protected posts to logged in users

In a WPMU & BuddyPress installation, I want to directly show the password protected posts to logged in users without asking them for posts passwords... and still be accessible to guests ...
1
vote
0answers
78 views

redirect deleted / drafted pages

A client asked me to unpublished a page, which I did. However, I kept it as a draft, just in case they wanted to republish at a future date. My issue is that anyone with this link will hit a 404 ...
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
2k views

WordPress plugin to publish to multiple remote WordPress blogs

I have a WordPress (.org) blog (let's call it blog1) that is used by many authors, who may create, edit and publish posts (on blog1). Each author has her/his own WordPress blogs, hosted elsewhere. ...
2
votes
1answer
282 views

Unpublish all posts in a category

I have a category with about 3.500 posts. 2.500 are not published, but saved as drafts. I want to unpublish all the remaining 1000 posts from this one category. Maybe I will want to delete all of the ...