This topic contains 1 reply and 2 voices, and was last updated by Tareq Hasan 6 years, 6 months ago
Viewing 1 Posts - 1 through 1 (of 1 total)
Author Posts
May 16, 2013 at 9:27 am 3697
Tareq Hasan Hi Tareq ! I have a simple question : I have an action hook and I want it to be called only on the new post page, not on the edit post page. How can I do that ?
May 16, 2013 at 7:04 pm 3717
Tareq Hasan Tareq Hasan

The post ID is the second parameter, for new posts, it’s null. For edit posts, it’s the post id of the edited post. So check if it’s null and only then show your element.

Viewing 1 Posts - 1 through 1 (of 1 total)