I am creating a plugin page for Wordpress. This plugin page contains an iframe. But a suggested php method (instead of iframe html method) of yours would be nice too.
What is a problem is that this plugin page not responding. Because this plugin page has not created its own admin menu. What is wrong with this plugin page?
Here is code:
<?php
/*
Plugin Name: Leo
Plugin URI: http://www.example.com
Description: Blabla
Author: Leo
Version: 1.1
Author URI: http://www.example.com
function schedule() {
?>
<h1>schedule</h1>
<a href="/wp-admin/admin.php?page=schedulesite">Show schedule</a><br />
<?PHP
}
function schedulesite() {
echo "<iframe style="width:100%;height:800px;border=0;"
src="http://www.example.com/schedule.php"></iframe>";
}
function scheduleAddMenu() {
add_menu_page('schedule', 'schedule', 10, __FILE__, 'schedule');
add_submenu_page(__FILE__, 'Show schedule', 'Show schedule', 10, 'schedulesite', 'schedulesite');
}
?>