iframe - Version 1.1.0

Version Description

  • Parameter allowtransparency added (thanks to Kent);
Download this release

Release Info

Developer webvitaly
Plugin Icon wp plugin iframe
Version 1.1.0
Comparing to
See all releases

Code changes from version 1.0.0 to 1.1.0

Files changed (2) hide show
  1. iframe.php +7 -6
  2. readme.txt +43 -40
iframe.php CHANGED
@@ -4,15 +4,15 @@
4
  Plugin Name: Iframe
5
  Plugin URI: http://web-profile.com.ua/wordpress/plugins/iframe/
6
  Description: Plugin shows iframe with [iframe width="640" height="480" src="http://player.vimeo.com/video/3261363"] shortcode.
7
- Version: 1.0.0
8
  Author: webvitaly
9
  Author Email: webvitaly(at)gmail.com
10
  Author URI: http://web-profile.com.ua/
11
  */
12
 
13
 
14
- if ( !function_exists( 'iframe_embed_sortcode' ) ) {
15
- function iframe_embed_sortcode($atts, $content = null) {
16
  extract(shortcode_atts(array(
17
  'width' => '640',
18
  'height' => '480',
@@ -20,10 +20,11 @@ if ( !function_exists( 'iframe_embed_sortcode' ) ) {
20
  'frameborder' => '0',
21
  'scrolling' => 'no',
22
  'marginheight' => '0',
23
- 'marginwidth' => '0'
 
24
  ), $atts));
25
- return '<iframe width="'.$width.'" height="'.$height.'" frameborder="'.$frameborder.'" scrolling="'.$scrolling.'" marginheight="'.$marginheight.'" marginwidth="'.$marginwidth.'" src="'.$src.'" ></iframe>';
26
  // &amp;output=embed
27
  }
28
- add_shortcode('iframe', 'iframe_embed_sortcode');
29
  }
4
  Plugin Name: Iframe
5
  Plugin URI: http://web-profile.com.ua/wordpress/plugins/iframe/
6
  Description: Plugin shows iframe with [iframe width="640" height="480" src="http://player.vimeo.com/video/3261363"] shortcode.
7
+ Version: 1.1.0
8
  Author: webvitaly
9
  Author Email: webvitaly(at)gmail.com
10
  Author URI: http://web-profile.com.ua/
11
  */
12
 
13
 
14
+ if ( !function_exists( 'iframe_embed_shortcode' ) ) {
15
+ function iframe_embed_shortcode($atts, $content = null) {
16
  extract(shortcode_atts(array(
17
  'width' => '640',
18
  'height' => '480',
20
  'frameborder' => '0',
21
  'scrolling' => 'no',
22
  'marginheight' => '0',
23
+ 'marginwidth' => '0',
24
+ 'allowtransparency' => 'true'
25
  ), $atts));
26
+ return '<iframe width="'.$width.'" height="'.$height.'" frameborder="'.$frameborder.'" scrolling="'.$scrolling.'" marginheight="'.$marginheight.'" marginwidth="'.$marginwidth.'" allowtransparency="'.$allowtransparency.'" src="'.$src.'"></iframe>';
27
  // &amp;output=embed
28
  }
29
+ add_shortcode('iframe', 'iframe_embed_shortcode');
30
  }
readme.txt CHANGED
@@ -1,40 +1,43 @@
1
- === Iframe ===
2
- Contributors: webvitaly
3
- Donate link: http://web-profile.com.ua/wordpress/plugins/iframe/
4
- Plugin URI: http://web-profile.com.ua/wordpress/plugins/iframe/
5
- Tags: iframe, embed
6
- Author URI: http://web-profile.com.ua/wordpress/
7
- Requires at least: 3.0
8
- Tested up to: 3.1.1
9
- Stable tag: 1.0.0
10
-
11
- You may embed iframe with [iframe width="640" height="480" src="http://vimeo.com/123"] shortcode.
12
-
13
- == Description ==
14
-
15
- Iframes are needed to embed video from youtube or to embed Google Map or just to embed content from external page.
16
- WordPress removes iframe when you switch from "HTML" to "Visual" tab because of the security reasons.
17
- So you can embed iframe code using this shortcode **`[iframe width="640" height="480" src="http://player.vimeo.com/video/3261363"]`**.
18
-
19
- = Usage =
20
- * You can set various parameters:
21
- * width - width of the iframe in pixels `[iframe width="640" src="http://player.vimeo.com/video/3261363"]` (by default width="640");
22
- * height - height of the iframe in pixels `[iframe height="480" src="http://player.vimeo.com/video/3261363"]` (by default height="480");
23
- * src - source of the iframe `[iframe src="http://player.vimeo.com/video/3261363"]` (by default src="");
24
- * frameborder - frameborder parameter of the iframe `[iframe frameborder="0" src="http://player.vimeo.com/video/3261363"]` (by default frameborder="0");
25
- * scrolling - scrolling parameter of the iframe `[iframe scrolling="no" src="http://player.vimeo.com/video/3261363"]` (by default scrolling="no");
26
- * marginheight - marginheight parameter of the iframe `[iframe marginheight="0" src="http://player.vimeo.com/video/3261363"]` (by default marginheight="0");
27
- * marginwidth - marginwidth parameter of the iframe `[iframe marginwidth="0" src="http://player.vimeo.com/video/3261363"]` (by default marginwidth="0");
28
-
29
- [WordPress stuff](http://web-profile.com.ua/wordpress/)
30
-
31
- == Changelog ==
32
-
33
- = 1.0.0 =
34
- * Initial release;
35
-
36
- == Installation ==
37
-
38
- 1. Install plugin and activate it on the Plugins page;
39
- 2. Add shortcode **`[iframe width="640" height="480" src="http://player.vimeo.com/video/3261363"]`** to page content;
40
-
 
 
 
1
+ === Iframe ===
2
+ Contributors: webvitaly
3
+ Plugin URI: http://web-profile.com.ua/wordpress/plugins/iframe/
4
+ Tags: iframe, embed
5
+ Author URI: http://web-profile.com.ua/wordpress/
6
+ Requires at least: 3.0
7
+ Tested up to: 3.2
8
+ Stable tag: 1.1.0
9
+
10
+ You can embed iframe with [iframe width="640" height="480" src="http://vimeo.com/123"] shortcode.
11
+
12
+ == Description ==
13
+
14
+ Iframes are needed to embed video from youtube or to embed Google Map or just to embed content from external page.
15
+ WordPress removes iframe when you switch from "HTML" to "Visual" tab because of the security reasons.
16
+ So you can embed iframe code using this shortcode `[iframe width="640" height="480" src="http://player.vimeo.com/video/3261363"]`.
17
+
18
+ = Usage (allowed parameters) =
19
+ * width - width of the iframe in pixels `[iframe width="640" src="http://player.vimeo.com/video/3261363"]` (by default width="640");
20
+ * height - height of the iframe in pixels `[iframe height="480" src="http://player.vimeo.com/video/3261363"]` (by default height="480");
21
+ * src - source of the iframe `[iframe src="http://player.vimeo.com/video/3261363"]` (by default src="");
22
+ * frameborder - frameborder parameter of the iframe `[iframe frameborder="0" src="http://player.vimeo.com/video/3261363"]` (by default frameborder="0");
23
+ * scrolling - scrolling parameter of the iframe `[iframe scrolling="no" src="http://player.vimeo.com/video/3261363"]` (by default scrolling="no");
24
+ * marginheight - marginheight parameter of the iframe `[iframe marginheight="0" src="http://player.vimeo.com/video/3261363"]` (by default marginheight="0");
25
+ * marginwidth - marginwidth parameter of the iframe `[iframe marginwidth="0" src="http://player.vimeo.com/video/3261363"]` (by default marginwidth="0");
26
+ * allowtransparency - allowing transparency of the iframe `[iframe allowtransparency="true" src="http://player.vimeo.com/video/3261363"]` (by default allowtransparency="true");
27
+
28
+ [Iframe plugin page](http://web-profile.com.ua/wordpress/plugins/iframe/)
29
+
30
+ [WordPress stuff](http://web-profile.com.ua/wordpress/)
31
+
32
+ == Changelog ==
33
+
34
+ = 1.1.0 =
35
+ * Parameter allowtransparency added (thanks to Kent);
36
+
37
+ = 1.0.0 =
38
+ * Initial release;
39
+
40
+ == Installation ==
41
+
42
+ 1. Install plugin and activate it on the Plugins page;
43
+ 2. Add shortcode `[iframe width="640" height="480" src="http://player.vimeo.com/video/3261363"]` to page content;