Opened 13 years ago
Closed 13 years ago
#23759 closed enhancement (duplicate)
Pass $update to save_post and wp_insert_post actions
| Reported by: | alex-ye | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Posts, Post Types | Version: | 3.5.1 |
| Severity: | normal | Keywords: | has-patch |
| Cc: | Focuses: |
Description
For now it's hard to check if the post is updated or publish for the first time when using save_post and wp_insert_post hooks
Attachments (1)
Change History (8)
#4
in reply to: ↑ 3
@
13 years ago
Replying to SergeyBiryukov:
For now it's hard to check if the post is updated or publish for the first time
Post status transition actions can be used as a workaround:
http://codex.wordpress.org/Post_Status_Transitions
Related: #21450
Yes it could be used , but Post_Status_Transitions it's different form what I ask , especially when you want all things in one function I currently check $_POSTupdate in the back-end , but what about when you make some staff in the front-end ...
I read the Related ticket but and I think we cant make the both in the core :)
#5
@
13 years ago
There are already pre_post_update, edit_post, and post_updated hooks. I'd rather not add something else to the ubiquitous save_post hook, too.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Post status transition actions can be used as a workaround:
http://codex.wordpress.org/Post_Status_Transitions
Related: #21450