WD Instagram Feed – Instagram Gallery - Version 1.1.15

Version Description

New: Show hashtag media number in header
Fixed: Scripts dependency on underscore.js
Fixed: Compatibility issues with Yoast SEO

Download this release

Release Info

Developer webdorado
Plugin Icon 128x128 WD Instagram Feed – Instagram Gallery
Version 1.1.15
Comparing to
See all releases

Code changes from version 1.1.14 to 1.1.15

frontend/shortcode.php CHANGED
@@ -125,7 +125,8 @@ function wdi_load_frontend_scripts(){
125
 
126
  wp_enqueue_script('wdi_instagram',plugins_url('../js/wdi_instagram.js', __FILE__),array("jquery"), WDI_VERSION, true );
127
 
128
- wp_enqueue_script('wdi_frontend',plugins_url('../js/wdi_frontend.js', __FILE__),array("jquery",'wdi_instagram'), WDI_VERSION, true);
 
129
 
130
  wp_enqueue_script('wdi_responsive',plugins_url('../js/wdi_responsive.js', __FILE__),array("jquery","wdi_frontend"), WDI_VERSION, true);
131
  wp_localize_script("wdi_frontend", 'wdi_ajax',array( 'ajax_url' => admin_url( 'admin-ajax.php' )), WDI_VERSION);
@@ -139,7 +140,7 @@ function wdi_load_frontend_scripts(){
139
  'filter_title' => __('Click to filter images by this user','wdi')
140
  ), WDI_VERSION);
141
 
142
- wp_enqueue_script('underscore');
143
  wdi_front_end_scripts();
144
  }
145
 
125
 
126
  wp_enqueue_script('wdi_instagram',plugins_url('../js/wdi_instagram.js', __FILE__),array("jquery"), WDI_VERSION, true );
127
 
128
+ wp_enqueue_script('underscore');
129
+ wp_enqueue_script('wdi_frontend',plugins_url('../js/wdi_frontend.js', __FILE__),array("jquery",'wdi_instagram', 'underscore'), WDI_VERSION, true);
130
 
131
  wp_enqueue_script('wdi_responsive',plugins_url('../js/wdi_responsive.js', __FILE__),array("jquery","wdi_frontend"), WDI_VERSION, true);
132
  wp_localize_script("wdi_frontend", 'wdi_ajax',array( 'ajax_url' => admin_url( 'admin-ajax.php' )), WDI_VERSION);
140
  'filter_title' => __('Click to filter images by this user','wdi')
141
  ), WDI_VERSION);
142
 
143
+
144
  wdi_front_end_scripts();
145
  }
146
 
frontend/views/WDIViewImageBrowser_view.php CHANGED
@@ -159,9 +159,7 @@ public function generate_feed_styles($feed_row){
159
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_header_hashtag h3{
160
  margin-top: <?php echo (intval($style['user_img_width']) - intval($style['users_text_font_size']))/2?>px;
161
  }
162
- #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_header_hashtag .wdi_media_info{
163
- display: none;
164
- }
165
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_followers,
166
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_posts {
167
  display: inline-block;
159
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_header_hashtag h3{
160
  margin-top: <?php echo (intval($style['user_img_width']) - intval($style['users_text_font_size']))/2?>px;
161
  }
162
+
 
 
163
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_followers,
164
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_posts {
165
  display: inline-block;
frontend/views/WDIViewThumbnails_view.php CHANGED
@@ -169,9 +169,7 @@ public function generate_feed_styles($feed_row){
169
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_header_hashtag h3{
170
  margin-top: <?php echo (intval($style['user_img_width']) - intval($style['users_text_font_size']))/2?>px;
171
  }
172
- #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_header_hashtag .wdi_media_info{
173
- display: none;
174
- }
175
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_followers,
176
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_posts {
177
  display: inline-block;
169
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_header_hashtag h3{
170
  margin-top: <?php echo (intval($style['user_img_width']) - intval($style['users_text_font_size']))/2?>px;
171
  }
172
+
 
 
173
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_followers,
174
  #wdi_feed_<?php echo $wdi_feed_counter?> .wdi_posts {
175
  display: inline-block;
js/wdi_frontend.js CHANGED
@@ -828,6 +828,10 @@ wdi_front.getArrayContentLength = function (array, data)
828
  */
829
  wdi_front.displayFeedItems = function (data, currentFeed)
830
  {
 
 
 
 
831
 
832
  //gets ready data, gets data template, and appens it into feed_wrapper
833
  var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
@@ -1532,6 +1536,12 @@ wdi_front.getVideoTemplate = function (currentFeed)
1532
 
1533
  wdi_front.bindEvents = function (currentFeed)
1534
  {
 
 
 
 
 
 
1535
  if (currentFeed.feed_row.feed_display_view == 'load_more_btn') {
1536
  //binding load more event
1537
  jQuery('#wdi_feed_' + currentFeed.feed_row['wdi_feed_counter'] + ' .wdi_load_more_container').on(wdi_front.clickOrTouch, function ()
@@ -2144,20 +2154,25 @@ wdi_front.show = function (name, currentFeed)
2144
  }
2145
  else
2146
  if (_this.getInputType(_user.username) == 'hashtag') {
2147
- currentFeed.instagram.getTagRecentMedia(_this.stripHashtag(_user.username), {
 
2148
  success: function (response)
2149
  {
2150
  response = _this.checkMediaResponse(response);
2151
  if (response != false) {
2152
-
2153
  if (response['data'].length == 0) {
2154
- thumb_img = '';
 
2155
  } else {
2156
- thumb_img = response['data'][0]['images']['thumbnail']['url'];
 
 
2157
  }
 
2158
  var obj = {
2159
  name: users[i]['username'],
2160
  url: thumb_img,
 
2161
  };
2162
  i++;
2163
  currentFeed.headerUserinfo.push(obj);
@@ -2297,10 +2312,11 @@ wdi_front.getUserTemplate = function (currentFeed, username)
2297
  source += '<div class="wdi_user_controls">' +
2298
  '</div>' +
2299
  '<div class="wdi_media_info">' +
2300
- '<p class="wdi_posts"><span></span></p>' +
2301
  '<p class="wdi_followers"><span></span></p>' +
2302
  '</div>';
2303
  }
 
2304
 
2305
  if (usersCount == 1 && username[0] !== '#' && currentFeed.feed_row.display_user_info == '1') {
2306
  source += '<div class="wdi_bio"><%= bio%></div>';
828
  */
829
  wdi_front.displayFeedItems = function (data, currentFeed)
830
  {
831
+ if (jQuery('#wdi_feed_' + currentFeed.feed_row.wdi_feed_counter + " .wdi_feed_wrapper").length == 0) {
832
+ //no feed in DOM, ignore
833
+ return;
834
+ }
835
 
836
  //gets ready data, gets data template, and appens it into feed_wrapper
837
  var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
1536
 
1537
  wdi_front.bindEvents = function (currentFeed)
1538
  {
1539
+
1540
+ if (jQuery('#wdi_feed_' + currentFeed.feed_row.wdi_feed_counter + " .wdi_feed_wrapper").length == 0) {
1541
+ //no feed in DOM, ignore
1542
+ return;
1543
+ }
1544
+
1545
  if (currentFeed.feed_row.feed_display_view == 'load_more_btn') {
1546
  //binding load more event
1547
  jQuery('#wdi_feed_' + currentFeed.feed_row['wdi_feed_counter'] + ' .wdi_load_more_container').on(wdi_front.clickOrTouch, function ()
2154
  }
2155
  else
2156
  if (_this.getInputType(_user.username) == 'hashtag') {
2157
+ currentFeed.instagram.searchForTagsByName(_this.stripHashtag(_user.username), {
2158
+ /*currentFeed.instagram.getTagRecentMedia(_this.stripHashtag(_user.username), {*/
2159
  success: function (response)
2160
  {
2161
  response = _this.checkMediaResponse(response);
2162
  if (response != false) {
 
2163
  if (response['data'].length == 0) {
2164
+ var thumb_img = '';
2165
+ var counts = {media:''};
2166
  } else {
2167
+ var thumb_img = '';// we will get image src later when will have all the sources
2168
+ //thumb_img = response['data'][0]['images']['thumbnail']['url'];
2169
+ var counts = {media: response['data'][0]['media_count']};
2170
  }
2171
+
2172
  var obj = {
2173
  name: users[i]['username'],
2174
  url: thumb_img,
2175
+ counts: counts,
2176
  };
2177
  i++;
2178
  currentFeed.headerUserinfo.push(obj);
2312
  source += '<div class="wdi_user_controls">' +
2313
  '</div>' +
2314
  '<div class="wdi_media_info">' +
2315
+ '<p class="wdi_posts"><span class="fa fa-camera-retro"><%= counts.media%></span></p>' +
2316
  '<p class="wdi_followers"><span></span></p>' +
2317
  '</div>';
2318
  }
2319
+ source += '<div class="clear"></div>';
2320
 
2321
  if (usersCount == 1 && username[0] !== '#' && currentFeed.feed_row.display_user_info == '1') {
2322
  source += '<div class="wdi_bio"><%= bio%></div>';
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://web-dorado.com/products/wordpress-instagram-feed-wd.html
4
  Tags: : custom instagram feed, feed, instagram, hashtag, Instagram feed, instagram gallery, instagram posts, Instagram images, Instagram photos, Instagram wall, lightbox, photos
5
  Requires at least: 3.9
6
  Tested up to: 4.6
7
- Stable tag: 1.1.14
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -107,6 +107,11 @@ After downloading the ZIP file of the Instagram Feed WD plugin,
107
 
108
  == Changelog ==
109
 
 
 
 
 
 
110
  = 1.1.14 =
111
  Fixed: Single user bio not shown
112
  Changed: Plugin logo
4
  Tags: : custom instagram feed, feed, instagram, hashtag, Instagram feed, instagram gallery, instagram posts, Instagram images, Instagram photos, Instagram wall, lightbox, photos
5
  Requires at least: 3.9
6
  Tested up to: 4.6
7
+ Stable tag: 1.1.15
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
107
 
108
  == Changelog ==
109
 
110
+ = 1.1.15 =
111
+ New: Show hashtag media number in header
112
+ Fixed: Scripts dependency on underscore.js
113
+ Fixed: Compatibility issues with Yoast SEO
114
+
115
  = 1.1.14 =
116
  Fixed: Single user bio not shown
117
  Changed: Plugin logo
wd-instagram-feed.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Instagram Feed WD
4
  Plugin URI: https://web-dorado.com/products/wordpress-instagram-feed-wd.html
5
  Description: WD Instagram Feed is a user-friendly tool for displaying user or hashtag-based feeds on your website. You can create feeds with one of the available layouts. It allows displaying image metadata, open up images in lightbox, download them and even share in social networking websites.
6
- Version: 1.1.14
7
  Author: WebDorado
8
  Author URI: https://web-dorado.com
9
  License: GPLv2 or later
@@ -20,7 +20,7 @@ define("WDI_META", "_".WDI_VAR."_meta");
20
  //define("wdi",'wdi');
21
  define('WDI_FEED_TABLE','wdi_feeds');
22
  define('WDI_THEME_TABLE','wdi_themes');
23
- define('WDI_VERSION','1.1.14');
24
  define('WDI_IS_PRO','false');
25
 
26
 
3
  Plugin Name: Instagram Feed WD
4
  Plugin URI: https://web-dorado.com/products/wordpress-instagram-feed-wd.html
5
  Description: WD Instagram Feed is a user-friendly tool for displaying user or hashtag-based feeds on your website. You can create feeds with one of the available layouts. It allows displaying image metadata, open up images in lightbox, download them and even share in social networking websites.
6
+ Version: 1.1.15
7
  Author: WebDorado
8
  Author URI: https://web-dorado.com
9
  License: GPLv2 or later
20
  //define("wdi",'wdi');
21
  define('WDI_FEED_TABLE','wdi_feeds');
22
  define('WDI_THEME_TABLE','wdi_themes');
23
+ define('WDI_VERSION','1.1.15');
24
  define('WDI_IS_PRO','false');
25
 
26