Featured Image From URL - Version 1.5.1

Version Description

  • Genesis Framework integration, external JS minification and WooCommerce 3 note.

=

Download this release

Release Info

Developer marceljm
Plugin Icon 128x128 Featured Image From URL
Version 1.5.1
Comparing to
See all releases

Code changes from version 1.5.0 to 1.5.1

admin/html/live-preview.html CHANGED
@@ -3,4 +3,4 @@
3
  <a id="fifu_slider"
4
  class="blink_me"
5
  href="http://fifu.marceljm.com/"
6
- style="<?php echo $show_slider ?>" >Live preview</a>
3
  <a id="fifu_slider"
4
  class="blink_me"
5
  href="http://fifu.marceljm.com/"
6
+ style="" >Live preview</a>
admin/html/menu.html CHANGED
@@ -1,7 +1,7 @@
1
  <style><?php include 'css/menu.css' ?></style>
2
  <script><?php include 'js/menu.js' ?></script>
3
- <link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
4
- <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
5
  <div class="wrap">
6
  <div class="box">
7
  <h1>Featured Image From URL</h1>
@@ -113,12 +113,10 @@
113
  <div class="box">
114
  <h2>WooCommerce Full Integration</h2>
115
  <div class="greybox" style="background:#ffffbc">
116
- <b>Free feature (WooCommerce 2.4/5.X)</b><br>
117
- <b>Premium feature (WooCommerce 2.6.X)</b><br><br>
118
  <div id="tabs">
119
  <ul>
120
  <li><a href="#tabs-1">Full Integration</a></li>
121
- <li><a href="#tabs-2">Compatible Versions</a></li>
122
  </ul>
123
  <div id="tabs-1">
124
  Would you like to integrate WooCommerce to Featured Image From URL? For that, a script will be executed to overwrite some lines of code from WooCommerce plugin. It's safe and reversible but it will only work if your site is hosted on a Linux server. <br><br>So let me check...<br><br>
@@ -126,7 +124,7 @@
126
  </div>
127
  <div id="tabs-2">
128
  <b>Free</b>: supports WooCommerce 2.4.X and 2.5.X.<br><br>
129
- <b>Premium</b>: supports WooCommerce 2.6.X and later.
130
  </div>
131
  </div>
132
 
@@ -489,7 +487,7 @@
489
  <div class="box">
490
  <h2>About The Author</h2>
491
  <div class="greybox">
492
- Hi! I'm Marcel Jacques Machado. Graduated in Computer Science, I work as a Software Engineer for 10 years. I already worked with C, Python, Shell Script and other programming languages and technologies. Nowadays, I develop web applications in Brazil using Java. About PHP, this plugin, Featured Image From URL, is my first pratical experience. I also have a <a href="http://marceljm.com/" target="_blank">blog</a> in WordPress and I expect to post some useful content very soon.
493
  </div>
494
  </div>
495
  </div>
1
  <style><?php include 'css/menu.css' ?></style>
2
  <script><?php include 'js/menu.js' ?></script>
3
+ <link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.min.css">
4
+ <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.min.js"></script>
5
  <div class="wrap">
6
  <div class="box">
7
  <h1>Featured Image From URL</h1>
113
  <div class="box">
114
  <h2>WooCommerce Full Integration</h2>
115
  <div class="greybox" style="background:#ffffbc">
 
 
116
  <div id="tabs">
117
  <ul>
118
  <li><a href="#tabs-1">Full Integration</a></li>
119
+ <li><a href="#tabs-2">Compatibility</a></li>
120
  </ul>
121
  <div id="tabs-1">
122
  Would you like to integrate WooCommerce to Featured Image From URL? For that, a script will be executed to overwrite some lines of code from WooCommerce plugin. It's safe and reversible but it will only work if your site is hosted on a Linux server. <br><br>So let me check...<br><br>
124
  </div>
125
  <div id="tabs-2">
126
  <b>Free</b>: supports WooCommerce 2.4.X and 2.5.X.<br><br>
127
+ <b>Premium</b>: supports WooCommerce 2.6.X and 3.0.X.
128
  </div>
129
  </div>
130
 
487
  <div class="box">
488
  <h2>About The Author</h2>
489
  <div class="greybox">
490
+ Hi! I'm Marcel Jacques Machado. Graduated in Computer Science, I work as a Software Engineer for 10 years. I already worked with C, Python, Shell Script and other programming languages and technologies. Nowadays, I develop web applications in Brazil using Java. About PHP, this plugin, Featured Image From URL, is my first pratical experience.
491
  </div>
492
  </div>
493
  </div>
admin/html/meta-box.html CHANGED
@@ -45,4 +45,4 @@
45
  style="<?php echo $show_sirv?>">Choose Sirv image</a>
46
 
47
  <hr>
48
- <p style="border: 1px solid green; padding: 25px;"><b>New free feature</b>: now you can enable/disable <b>social tags</b> for external images in the plugin settings. The dafault value is off.</p>
45
  style="<?php echo $show_sirv?>">Choose Sirv image</a>
46
 
47
  <hr>
48
+ <p style="border: 1px solid red; padding: 25px;"><b><a href="http://fifu.marceljm.com/" targe="_blank">Featured Image From URL Premium</a></b> supports <b>WooCommerce 3.0.X</b> now.</p>
admin/html/slider-meta-box.html CHANGED
@@ -4,11 +4,11 @@
4
  type="text"
5
  name="fifu_slider_input_url_<?php echo $i; ?>"
6
  placeholder="URL"
7
- value="<?php echo $url[$i]; ?>"
8
- style="<?php echo $width, $margin, $show_url[$i] ?>" />
9
 
10
  <a disabled id="fifu_slider_button_<?php echo $i; ?>"
11
  class="button"
12
  onClick="sliderPreviewImage(<?php echo $i; ?>);"
13
- style="<?php echo $align, $margin, $show_button[$i] ?>" >Preview</a>
14
 
4
  type="text"
5
  name="fifu_slider_input_url_<?php echo $i; ?>"
6
  placeholder="URL"
7
+ value=""
8
+ style="<?php echo $width, $margin ?>" />
9
 
10
  <a disabled id="fifu_slider_button_<?php echo $i; ?>"
11
  class="button"
12
  onClick="sliderPreviewImage(<?php echo $i; ?>);"
13
+ style="<?php echo $align, $margin ?>" >Preview</a>
14
 
featured-image-from-url.php CHANGED
@@ -3,7 +3,7 @@
3
  /*
4
  * Plugin Name: Featured Image From URL
5
  * Description: Allows to use an external image as Featured Image of your post, page or Custom Post Type, such as WooCommerce Product (supports Product Gallery also).
6
- * Version: 1.5.0
7
  * Author: Marcel Jacques Machado
8
  * Author URI: http://marceljm.com/wordpress/featured-image-from-url-premium/
9
  */
3
  /*
4
  * Plugin Name: Featured Image From URL
5
  * Description: Allows to use an external image as Featured Image of your post, page or Custom Post Type, such as WooCommerce Product (supports Product Gallery also).
6
+ * Version: 1.5.1
7
  * Author: Marcel Jacques Machado
8
  * Author URI: http://marceljm.com/wordpress/featured-image-from-url-premium/
9
  */
includes/thumbnail.php CHANGED
@@ -83,3 +83,19 @@ function fifu_replace_attachment_url($att_url, $att_id) {
83
  return $att_url;
84
  }
85
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
83
  return $att_url;
84
  }
85
 
86
+ add_filter('wp_get_attachment_image_src', 'fifu_replace_attachment_image_src', 10, 2);
87
+
88
+ function fifu_replace_attachment_image_src($image, $attachment_id) {
89
+ if ($attachment_id == get_post_thumbnail_id(get_the_ID())) {
90
+ $url = get_post_meta(get_the_ID(), 'fifu_image_url', true);
91
+ if ($url) {
92
+ return array(
93
+ $url,
94
+ 0,
95
+ 0,
96
+ false
97
+ );
98
+ }
99
+ }
100
+ return $image;
101
+ }
readme.txt CHANGED
@@ -3,8 +3,8 @@ Contributors: marceljm
3
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=8BLDLZ3HDBGQG
4
  Tags: featured image, external featured image, featured image from url, url featured image, featured, image, external, url, flickr, s3, picasa, woocommerce, product image, product gallery, product, gallery, column, list, page, post, all, content, custom, type, custom post type, category, video, external video, youtube, featured video, hover, effects, hover effects, sirv, wp all import, css, style, slider, thumbnail, social, network, wp all import
5
  Requires at least: 4.0
6
- Tested up to: 4.7.3
7
- Stable tag: 4.7.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -281,6 +281,9 @@ was removed. To finish, a Premium version is now been presented.
281
  = 1.5.0 =
282
  * Social tags toggle.
283
 
 
 
 
284
  == Upgrade Notice ==
285
 
286
  = 1.0 =
@@ -388,3 +391,6 @@ was removed. To finish, a Premium version is now been presented.
388
 
389
  = 1.5.0 =
390
  * Social tags toggle.
 
 
 
3
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=8BLDLZ3HDBGQG
4
  Tags: featured image, external featured image, featured image from url, url featured image, featured, image, external, url, flickr, s3, picasa, woocommerce, product image, product gallery, product, gallery, column, list, page, post, all, content, custom, type, custom post type, category, video, external video, youtube, featured video, hover, effects, hover effects, sirv, wp all import, css, style, slider, thumbnail, social, network, wp all import
5
  Requires at least: 4.0
6
+ Tested up to: 4.7.5
7
+ Stable tag: 4.7.5
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
281
  = 1.5.0 =
282
  * Social tags toggle.
283
 
284
+ = 1.5.1 =
285
+ * Genesis Framework integration, external JS minification and WooCommerce 3 note.
286
+
287
  == Upgrade Notice ==
288
 
289
  = 1.0 =
391
 
392
  = 1.5.0 =
393
  * Social tags toggle.
394
+
395
+ = 1.5.1 =
396
+ * Genesis Framework integration, external JS minification and WooCommerce 3 note.