This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Change table prefix in wp-config.php | |
2. Change table names. Script below: | |
RENAME table `wp_commentmeta` TO `new_commentmeta`; | |
RENAME table `wp_comments` TO `new_comments`; | |
RENAME table `wp_links` TO `new_links`; | |
RENAME table `wp_options` TO `new_options`; | |
RENAME table `wp_postmeta` TO `new_postmeta`; | |
RENAME table `wp_posts` TO `new_posts`; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* CTA Widget | |
* | |
* @package _s | |
*/ | |
class CTA_Widget extends WP_Widget { | |
/** | |
* Constructor |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Set new post and post ID variables | |
$args = array( | |
'post_title' => $post_title, | |
'post_content' => $post_content, | |
'post_status' => 'draft', | |
'post_type' => $post_type | |
); | |
$new_post = wp_insert_post( $args ); |
NewerOlder