mardi 30 décembre 2014

how to give custom message to user when create a post in wordpress


I am trying to make a custom message instead of the default message when user post a add in ClassiPress Theme , does anybody know how to do it!


i'm trying below code, but it not working



add_filter('transition_post_status', 'notify_status',10,3);


function notify_status($new_status, $old_status, $post) {
global $post;
if ($new_status == 'trash')
{
$pstatus = $new_status ;
$message= 'admin blocked ur post';

return $message;
}
}




Aucun commentaire:

Enregistrer un commentaire