I want to check if the author has permission to edit a post, if not then deny the save post.
But there do not seem a function which looks for a return statement.
I have seen an example here where they just exits the scripts, but I think there must be a better way, but I can not seem to find it.
wp_redirectbefore theexitto send the user back. – fischi Dec 27 '12 at 10:08save_postaction it is safe toreturnfrom it. In any case WordPress will not let users edit posts they don't have permissions for. – Jono Warren Jan 3 at 20:41