I have two front-end post submission forms. One is for normal post submission and another one is for custom post type "work" submission. The normal post submission form works fine but the custom post type form is not working ok. Here is the problem:
When the admin submit post from the custom post type form, the form gives me "Not found error" But when a user with capability of "contributor" submits the post, the post submits as a "post" not as custom post type.
What am I doing wrong here? Can anyone help?
Here is code I added to the functions.php file for normal post form:
And here is the code I added to the functions.php file for the custom post type form:
Note: The forms are almost identical, could this be a problem?
UPDATE: I changed the custom post type form function like this: http://pastebin.com/RPJcdpEL Now both admin and contributors can submit posts but admin's submissions are added as custom post type and contributors submissions are added as normal post not as custom post type :(