| @@ -2,9 +2,9 @@ | ||
| 2 | 2 | /* |
| 3 | 3 | Plugin Name: iframe |
| 4 | 4 | Plugin URI: http://wordpress.org/plugins/iframe/ |
| 5 | 5 | Description: [iframe src="http://www.youtube.com/embed/7_nAZQt9qu0" width="100%" height="500"] shortcode |
| 6 | -Version: 6.0 | |
| 6 | +Version: 5.2 | |
| 7 | 7 | Author: webvitaly |
| 8 | 8 | Author URI: http://web-profile.net/wordpress/plugins/ |
| 9 | 9 | License: GPLv3 |
| 10 | 10 | */ |
| @@ -12,18 +12,12 @@ | ||
| 12 | 12 | if ( ! defined( 'ABSPATH' ) ) { // Avoid direct calls to this file and prevent full path disclosure |
| 13 | 13 | exit; |
| 14 | 14 | } |
| 15 | 15 | |
| 16 | -define('IFRAME_PLUGIN_VERSION', '6.0'); | |
| 16 | +define('IFRAME_PLUGIN_VERSION', '5.2'); | |
| 17 | 17 | |
| 18 | -// Load settings page functionality | |
| 19 | -require_once( plugin_dir_path( __FILE__ ) . 'iframe-settings.php' ); | |
| 20 | 18 | |
| 21 | - | |
| 22 | 19 | function iframe_plugin_add_shortcode_cb( $atts ) { |
| 23 | - // Get plugin settings | |
| 24 | - $settings = iframe_plugin_get_settings(); | |
| 25 | - | |
| 26 | 20 | $defaults = array( |
| 27 | 21 | //'src' => 'http://www.youtube.com/embed/7_nAZQt9qu0', |
| 28 | 22 | 'width' => '100%', |
| 29 | 23 | 'height' => '500', |
| @@ -28,10 +22,9 @@ | ||
| 28 | 22 | 'width' => '100%', |
| 29 | 23 | 'height' => '500', |
| 30 | 24 | 'scrolling' => 'yes', |
| 31 | 25 | 'class' => 'iframe-class', |
| 32 | - 'frameborder' => '0', | |
| 33 | - 'loading' => $settings['loading'] // Global setting from settings array | |
| 26 | + 'frameborder' => '0' | |
| 34 | 27 | ); |
| 35 | 28 | |
| 36 | 29 | if ( ! is_array( $atts ) ) { |
| 37 | 30 | $atts = array(); |
| @@ -56,13 +49,8 @@ | ||
| 56 | 49 | } |
| 57 | 50 | |
| 58 | 51 | // Skip attributes starting with "on". Examples: onload, onmouseover, onfocus, onpageshow, onclick |
| 59 | 52 | if ( strpos( strtolower( $attr ), 'on' ) === 0 ) { |
| 60 | - continue; | |
| 61 | - } | |
| 62 | - | |
| 63 | - // Skip loading attribute if set to 'none' (browser default) | |
| 64 | - if ( strtolower($attr) == 'loading' && strtolower($value) == 'none' ) { | |
| 65 | 53 | continue; |
| 66 | 54 | } |
| 67 | 55 | |
| 68 | 56 | if ($value !== '') { // adding all attributes |