Best practice for Designing a Plugin with this scenario
You can create a page after your plugin is activated. Take a look at this: register_activation_hook( __FILE__, ‘insert_page’ ); function insert_page(){ $my_page = array( ‘post_title’ => ‘My Page’, ‘post_name’ => ‘MyPage’, ‘post_content’ => ‘My page’s content.’, ‘post_status’ => ‘publish’, ‘post_author’ => get_current_user_id(), ‘post_type’ => ‘page’, ); wp_insert_post( $my_page, ” ); } Then assign your template … Read more