wp_insert_post Wordpress function


Description:

Insert a post.


Syntax:


Arguments:

(array) $postarr Elements that make up post to insert.
(bool) $wp_error Optional. Allow return of WP_Error on failure.


Return Type:

(int|WP_Error) The value 0 or WP_Error on failure. The post ID on success.


Define At:

wp-includes/post.php


Wordpress Reference URL:

http://codex.wordpress.org/Function_Reference/wp_insert_post


0 Flares Facebook 0 Google+ 0 0 Flares ×
Posted in: Wordpress functions
0 Flares Facebook 0 Pin It Share 0 Google+ 0 0 Flares ×