Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /*
- * Plugin Name: Kaipo iframe
- * Plugin URI: http://www.kaipochat.com
- * Description: Chat By Interest
- * Version: 1.0
- * Author: JSL
- * Author URI: http://www.kaipochat.com
- * License: GPL2
- */
- function registerStyle(){
- wp_register_style( 'custom-style', plugins_url( 'kaipostyle.css', __FILE__ ), array(), '20120208', 'all' );
- wp_enqueue_style( 'custom-style' );
- }
- function registerScript(){
- wp_register_script('custom-script', plugins_url('jquery.js',__FILE__ ));
- wp_enqueue_script('custom-script');
- }
- add_shortcode( 'kaipo_iframe', 'kaipochat_iframe' );
- function kaipochat_iframe($atts) {
- extract( shortcode_atts( array(
- 'id' => ''
- ), $atts ) );
- $output = '<iframe id="kaipoid" width="300" height="415"
- src="'. $id .'"></iframe>';
- return $output;
- }
- add_action( 'wp_enqueue_scripts', 'registerStyle' );
- add_action( 'wp_enqueue_scripts', 'registerScript' );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement