Complete the code to create a WordPress post with the title 'Hello World'.
<?php wp_insert_post(array('post_title' => '[1]', 'post_content' => 'Welcome to my blog!', 'post_status' => 'publish')); ?>
The post_title should be the title of the post, here 'Hello World'.
Complete the code to create a WordPress page with the title 'About Us'.
<?php wp_insert_post(array('post_title' => '[1]', 'post_content' => 'About our company.', 'post_status' => 'publish', 'post_type' => 'page')); ?>
The post_title for the page should be 'About Us'.
Fix the error in the code to correctly specify the post type as a page.
<?php wp_insert_post(array('post_title' => 'Services', 'post_content' => 'Our services.', 'post_status' => 'publish', 'post_type' => '[1]')); ?>
The post_type must be 'page' to create a WordPress page.
Fill both blanks to create a post with publish status.
<?php wp_insert_post(array('post_title' => 'News Update', 'post_content' => 'Latest news.', 'post_status' => '[1]', 'post_type' => '[2]')); ?>
The post should be published with post_status 'publish' and post_type 'post'.
Fill all three blanks to create a page with a title, content, and published status.
<?php wp_insert_post(array('post_title' => '[1]', 'post_content' => '[2]', 'post_status' => '[3]', 'post_type' => 'page')); ?>
The page title is 'Contact Us', content is 'Get in touch with us.', and status is 'publish' to make it live.
