Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /*
- Plugin Name: WordPress MultiSite Delete Sample Content
- Plugin URI: http://www.damiencarbery.com
- Description: Delete the sample post, page and comment that is created for a new site in a WordPress MultiSite installation.
- Author: Damien Carbery
- Version: 0.1
- $Id: $
- */
- function wpms_delete_sample_content($blog_id, $user_id, $domain, $path, $site_id, $meta) {
- switch_to_blog($blog_id);
- wp_delete_comment( 1, true );
- wp_delete_post(1, true);
- wp_delete_post(2, true);
- }
- add_action( 'wpmu_new_blog', 'wpms_delete_sample_content', 10, 6 );
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement