Add custom youtube videos to WordPress admin dashboard

February 21st, 2015 by
/*-----------------------------------------------------------------------------------*/
/* WordPress Videos
/*-----------------------------------------------------------------------------------*/

add_action('wp_dashboard_setup', 'my_custom_dashboard_widgets');
 
function my_custom_dashboard_widgets() {
global $wp_meta_boxes;
 
wp_add_dashboard_widget('custom_help_widget', 'Video Tutorials', 'custom_dashboard_help');
wp_add_dashboard_widget('custom_help_widgets', 'Video Tutorials 2', 'custom_dashboard_help2');
}
 
function custom_dashboard_help() {
echo '<p>Need help? Contact the developer <a href="mailto:yourusername@gmail.com">here</a>. For WordPress Tutorials visit: <a href="http://www.wpbeginner.com" target="_blank">WPBeginner</a></p>
<iframe width="480" height="270" src="http://www.youtube.com/embed/videoseries?list=PL7859D9192963D429&amp;hl=en_US" frameborder="0" allowfullscreen></iframe>

<iframe width="560" height="315" src="https://www.youtube.com/embed/PJG4uvQcGSs" frameborder="0" allowfullscreen></iframe>


';
}

function custom_dashboard_help2() {
echo '<p>Need help? Contact the developer <a href="mailto:yourusername@gmail.com">here</a>. For WordPress Tutorials visit: <a href="http://www.wpbeginner.com" target="_blank">WPBeginner</a></p>
<iframe width="560" height="315" src="https://www.youtube.com/embed/T5MAoPjydEM" frameborder="0" allowfullscreen></iframe>


';
}

Post a Comment

You must be logged in to post a comment.

Cached at: 2024-03-29 03:11:06pm