WD Instagram Feed – Instagram Gallery - Version 1.3.3

Version Description

New: Cache debugging tools
New: WD library updated
New: GDPR compliance help

Download this release

Release Info

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

Code changes from version 1.3.2 to 1.3.3

changelog.txt CHANGED
@@ -1,3 +1,8 @@
 
 
 
 
 
1
  = 1.3.2 =
2
  New: Signing up with multiple accounts
3
  Fixed: Settings page layout when language is not English
1
+ = 1.3.3 =
2
+ New: Cache debugging tools
3
+ New: WD library updated
4
+ New: GDPR compliance help
5
+
6
  = 1.3.2 =
7
  New: Signing up with multiple accounts
8
  Fixed: Settings page layout when language is not English
frontend/shortcode.php CHANGED
@@ -177,10 +177,10 @@ function wdi_load_frontend_scripts()
177
  }
178
 
179
  $wdi_token_error_flag = get_option("wdi_token_error_flag");
180
-
181
  wp_localize_script("wdi_frontend", 'wdi_ajax', array(
182
  'ajax_url' => admin_url('admin-ajax.php'),
183
- 'wdi_nonce' => wp_create_nonce("wdi_cache")
 
184
  ), WDI_VERSION);
185
  wp_localize_script("wdi_frontend", 'wdi_url', array('plugin_url' => WDI_URL . '/',
186
  'ajax_url' => admin_url('admin-ajax.php')), WDI_VERSION);
177
  }
178
 
179
  $wdi_token_error_flag = get_option("wdi_token_error_flag");
 
180
  wp_localize_script("wdi_frontend", 'wdi_ajax', array(
181
  'ajax_url' => admin_url('admin-ajax.php'),
182
+ 'wdi_nonce' => wp_create_nonce("wdi_cache"),
183
+ 'WDI_MINIFY'=>(WDI_MINIFY) ? 'true' : 'false',
184
  ), WDI_VERSION);
185
  wp_localize_script("wdi_frontend", 'wdi_url', array('plugin_url' => WDI_URL . '/',
186
  'ajax_url' => admin_url('admin-ajax.php')), WDI_VERSION);
js/wdi_instagram.js CHANGED
@@ -1569,13 +1569,19 @@ function WDIInstagram(args)
1569
  data: {
1570
  wdi_cache_name:cache_name,
1571
  wdi_nonce:wdi_ajax.wdi_nonce,
 
1572
  action:"wdi_get_cache_data",
1573
  },
1574
  success: function(data){
1575
- if(data["success"] !== "false"){
1576
- if(typeof data["cache_data"] !== "undefined"){
 
 
 
1577
  var json_data = JSON.parse(data["cache_data"]);
1578
  callback(json_data);
 
 
1579
  }
1580
  }else {
1581
  callback(false);
@@ -1597,7 +1603,7 @@ function WDIInstagram(args)
1597
  action:"wdi_set_cache_data"
1598
  },
1599
  success: function(data){
1600
- console.log(data);
1601
  }
1602
  });
1603
  }
1569
  data: {
1570
  wdi_cache_name:cache_name,
1571
  wdi_nonce:wdi_ajax.wdi_nonce,
1572
+ WDI_MINIFY:wdi_ajax.WDI_MINIFY,
1573
  action:"wdi_get_cache_data",
1574
  },
1575
  success: function(data){
1576
+ if(data["wdi_debugging"]){
1577
+ console.log(data["wdi_debugging_data"]);
1578
+ }
1579
+ if(data["success"]){
1580
+ if(typeof data["cache_data"] !== "undefined" && data["cache_data"] !== null){
1581
  var json_data = JSON.parse(data["cache_data"]);
1582
  callback(json_data);
1583
+ }else{
1584
+ callback(false);
1585
  }
1586
  }else {
1587
  callback(false);
1603
  action:"wdi_set_cache_data"
1604
  },
1605
  success: function(data){
1606
+
1607
  }
1608
  });
1609
  }
js/wdi_instagram.min.js CHANGED
@@ -1 +1 @@
1
- function WDIInstagram(a){this.access_tokens=[];this.filters=[];if(typeof a!="undefined"){if(typeof a.access_tokens!="undefined"){this.access_tokens=a.access_tokens}if(typeof a.filters!="undefined"){this.filters=a.filters}}var c=this;this.statusCode={429:function(){console.log(" 429: Too many requests. Try after one hour")}};this.getFilter=function(d){var f=c.filters;if(typeof f=="undefined"){return false}for(var e=0;e<f.length;e++){if(f[e].where==d){if(typeof f[e].what=="object"&&f[e].what.length==2){if(typeof window[f[e].what[0]]!="undefined"){if(typeof window[f[e].what[0]][f[e].what[1]]=="function"){return window[f[e].what[0]][f[e].what[1]]}}}else{if(typeof f[e].what=="string"){if(typeof window[f[e].what]=="function"){return window[f[e].what]}}else{if(typeof f[e].what=="function"){return f[e].what}else{return false}}}}}return false};function b(){var d=c.access_tokens,e=parseInt(Math.random(0,1)*d.length);return d[e]}this.addToken=function(d){if(typeof d=="string"){c.access_tokens.push(d)}};this.resetTokens=function(){c.access_tokens=[]};this.getTagRecentMedia=function(m,k){var l=this,n=false,e=false,h=this.statusCode,f=false,j=false,d=this.getFilter("getTagRecentMedia"),i="https://api.instagram.com/v1/tags/"+m+"/media/recent?access_token="+b();if(typeof k=="undefined"||k.length===0){n=true}else{if("success" in k){e=true}if("statusCode" in k){h=k.statusCode}if("error" in k){f=true}if("args" in k){j=true}else{k.args={}}if("count" in k){k.count=parseInt(k.count);if(!Number.isInteger(k.count)||k.count<=0){k.count=33}}else{k.count=33}i+="&count="+k.count;if("min_tag_id" in k){i+="&min_tag_id="+k.min_tag_id}if("max_tag_id" in k){i+="&max_tag_id="+k.max_tag_id}}var g=function(o){if(o===false){jQuery.ajax({type:"POST",url:i,dataType:"jsonp",success:function(q){c.setDataToCache(i,q);p(q)},error:function(q){if(f){if(typeof k.error=="object"&&k.error.length==2){if(typeof window[k.error[0]][k.error[1]]=="function"){window[k.error[0]][k.error[1]](q)}}else{if(typeof k.error=="string"){if(typeof window[k.error]=="function"){window[k.error](q)}}else{if(typeof k.error=="function"){k.error(q)}}}}},statusCode:h})}else{p(o)}function p(q){if(typeof q.data==="undefined"){q.data=[]}if(e){if(typeof k.success=="object"&&k.success.length==2){if(typeof window[k.success[0]]!="undefined"){if(typeof window[k.success[0]][k.success[1]]=="function"){if(d){q=d(q,l.filterArguments,k.args)}window[k.success[0]][k.success[1]](q)}}}else{if(typeof k.success=="string"){if(typeof window[k.success]=="function"){if(d){q=d(q,l.filterArguments,k.args)}window[k.success](q)}}else{if(typeof k.success=="function"){if(d){q=d(q,l.filterArguments,k.args)}k.success(q)}}}}}};c.getDataFromCache(g,i)};this.searchForTagsByName=function(k,i){var j=this,l=false,d=false,h=this.statusCode,e=false;filter=this.getFilter("searchForTagsByName");if(typeof i=="undefined"||i.length===0){l=true}else{if("success" in i){d=true}if("error" in i){e=true}if("statusCode" in i){h=i.statusCode}}var f="https://api.instagram.com/v1/tags/search?q="+k+"&access_token="+b();var g=function(m){if(m===false){jQuery.ajax({type:"POST",url:f,dataType:"jsonp",success:function(o){c.setDataToCache(f,o);n(o)},error:function(o){if(e){if(typeof i.error=="object"&&i.error.length==2){if(typeof window[i.error[0]][i.error[1]]=="function"){window[i.error[0]][i.error[1]](o)}}else{if(typeof i.error=="string"){if(typeof window[i.error]=="function"){window[i.error](o)}}else{if(typeof i.error=="function"){i.error(o)}}}}},statusCode:h})}else{n(m)}function n(o){if(d){if(typeof i.success=="object"&&i.success.length==2){if(typeof window[i.success[0]]!="undefined"){if(typeof window[i.success[0]][i.success[1]]=="function"){if(filter){o=filter(o,j.filterArguments)}window[i.success[0]][i.success[1]](o)}}}else{if(typeof i.success=="string"){if(typeof window[i.success]=="function"){if(filter){o=filter(o,j.filterArguments)}window[i.success](o)}}else{if(typeof i.success=="function"){if(filter){o=filter(o,j.filterArguments)}i.success(o)}}}}}};c.getDataFromCache(g,f)};this.searchForUsersByName=function(k,g){var d=this,j=false,e=false,i=this.statusCode,f=false,h=this.getFilter("searchForUsersByName");if(typeof g=="undefined"||g.length===0){j=true}else{if("success" in g){e=true}if("error" in g){f=true}if("statusCode" in g){i=g.statusCode}}jQuery.ajax({type:"POST",dataType:"jsonp",url:"https://api.instagram.com/v1/users/search?q="+k+"&access_token="+b(),success:function(l){if(e){if(typeof g.success=="object"&&g.success.length==2){if(typeof window[g.success[0]]!="undefined"){if(typeof window[g.success[0]][g.success[1]]=="function"){if(h){l=h(l,d.filterArguments)}l.args=g;window[g.success[0]][g.success[1]](l)}}}else{if(typeof g.success=="string"){if(typeof window[g.success]=="function"){if(h){l=h(l,d.filterArguments)}l.args=g;window[g.success](l)}}else{if(typeof g.success=="function"){if(h){l=h(l,d.filterArguments)}l.args=g;g.success(l)}}}}},error:function(l){if(f){if(typeof g.error=="object"&&g.error.length==2){if(typeof window[g.error[0]][g.error[1]]=="function"){window[g.error[0]][g.error[1]](l)}}else{if(typeof g.error=="string"){if(typeof window[g.error]=="function"){window[g.error](l)}}else{if(typeof g.error=="function"){g.error(l)}}}}},statusCode:this.statusCode})};this.getRecentLikedMedia=function(g){var d=this,k=false,e=false,i=this.statusCode,f=false,h=this.getFilter("getRecentLikedMedia"),j="https://api.instagram.com/v1/users/self/media/liked?access_token="+b();if(typeof g=="undefined"||g.length===0){k=true}else{if("success" in g){e=true}if("error" in g){f=true}if("statusCode" in g){i=g.statusCode}if("args" in g){argFlag=true}else{g.args={}}if("count" in g){g.count=parseInt(g.count);if(!Number.isInteger(g.count)||g.count<=0){g.count=20}}else{g.count=20}j+="&count="+g.count;if("next_max_like_id" in g){j+="&next_max_like_id="+g.next_max_like_id}}jQuery.ajax({type:"POST",dataType:"jsonp",url:j,success:function(l){if(e){if(typeof g.success=="object"&&g.success.length==2){if(typeof window[g.success[0]]!="undefined"){if(typeof window[g.success[0]][g.success[1]]=="function"){if(h){l=h(l,d.filterArguments,g.args)}window[g.success[0]][g.success[1]](l)}}}else{if(typeof g.success=="string"){if(typeof window[g.success]=="function"){if(h){l=h(l,d.filterArguments,g.args)}window[g.success](l)}}else{if(typeof g.success=="function"){if(h){l=h(l,d.filterArguments,g.args)}g.success(l)}}}}},error:function(l){if(f){if(typeof g.error=="object"&&g.error.length==2){if(typeof window[g.error[0]][g.error[1]]=="function"){window[g.error[0]][g.error[1]](l)}}else{if(typeof g.error=="string"){if(typeof window[g.error]=="function"){window[g.error](l)}}else{if(typeof g.error=="function"){g.error(l)}}}}},statusCode:i})};this.getUserRecentMedia=function(l,j){var k=this,m=false,e=false,i=false,g=this.statusCode,f=false,d=this.getFilter("getUserRecentMedia"),h="https://api.instagram.com/v1/users/"+l+"/media/recent/?access_token="+b();if(typeof j=="undefined"||j.length===0){m=true}else{if("success" in j){e=true}if("statusCode" in j){g=j.statusCode}if("args" in j){i=true}else{j.args={}}if("error" in j){f=true}if("count" in j){j.count=parseInt(j.count);if(!Number.isInteger(j.count)||j.count<=0){j.count=33}}else{j.count=33}h+="&count="+j.count;if("min_id" in j){h+="&min_id="+j.min_id}if("max_id" in j){h+="&max_id="+j.max_id}}jQuery.ajax({type:"POST",dataType:"jsonp",url:h,success:function(n){if(typeof n.data==="undefined"){n.data=[]}if(e){if(typeof j.success=="object"&&j.success.length==2){if(typeof window[j.success[0]]!="undefined"){if(typeof window[j.success[0]][j.success[1]]=="function"){if(d){n=d(n,k.filterArguments,j.args)}window[j.success[0]][j.success[1]](n)}}}else{if(typeof j.success=="string"){if(typeof window[j.success]=="function"){if(d){n=d(n,k.filterArguments,j.args)}window[j.success](n)}}else{if(typeof j.success=="function"){if(d){n=d(n,k.filterArguments,j.args)}j.success(n)}}}}},error:function(n){if(f){if(typeof j.error=="object"&&j.error.length==2){if(typeof window[j.error[0]][j.error[1]]=="function"){window[j.error[0]][j.error[1]](n)}}else{if(typeof j.error=="string"){if(typeof window[j.error]=="function"){window[j.error](n)}}else{if(typeof j.error=="function"){j.error(n)}}}}},statusCode:g})};this.getSelfRecentMedia=function(k){var l=this,m=false,e=false,h=this.statusCode,f=false,j=false,d=this.getFilter("getSelfRecentMedia"),i="https://api.instagram.com/v1/users/self/media/recent/?access_token="+b();if(typeof k=="undefined"||k.length===0){m=true}else{if("success" in k){e=true}if("error" in k){f=true}if("statusCode" in k){h=k.statusCode}if("args" in k){j=true}else{k.args={}}if("count" in k){k.count=parseInt(k.count);if(!Number.isInteger(k.count)||k.count<=0){k.count=20}}else{k.count=20}i+="&count="+k.count;if("min_id" in k){i+="&min_id="+k.min_id}if("max_id" in k){i+="&max_id="+k.max_id}}var g=function(n){if(n===false){jQuery.ajax({type:"POST",dataType:"jsonp",url:i,success:function(p){c.setDataToCache(i,p);o(p)},error:function(p){if(f){if(typeof k.error=="object"&&k.error.length==2){if(typeof window[k.error[0]][k.error[1]]=="function"){window[k.error[0]][k.error[1]](p)}}else{if(typeof k.error=="string"){if(typeof window[k.error]=="function"){window[k.error](p)}}else{if(typeof k.error=="function"){k.error(p)}}}}},statusCode:h})}else{o(n)}function o(p){if(e){if(typeof k.success=="object"&&k.success.length==2){if(typeof window[k.success[0]]!="undefined"){if(typeof window[k.success[0]][k.success[1]]=="function"){if(d){p=d(p,l.filterArguments,k)}window[k.success[0]][k.success[1]](p)}}}else{if(typeof k.success=="string"){if(typeof window[k.success]=="function"){if(d){p=d(p,l.filterArguments,k)}window[k.success](p)}}else{if(typeof k.success=="function"){if(d){p=d(p,l.filterArguments,k)}k.success(p)}}}}}};c.getDataFromCache(g,i)};this.getUserInfo=function(e,h){var d=this,k=false,f=false,j=this.statusCode,g=false,i=this.getFilter("getUserInfo");if(typeof h=="undefined"||h.length===0){k=true}else{if("success" in h){f=true}if("error" in h){g=true}if("statusCode" in h){j=h.statusCode}}jQuery.ajax({type:"POST",dataType:"jsonp",url:"https://api.instagram.com/v1/users/"+e+"/?access_token="+b(),success:function(l){if(f){if(typeof h.success=="object"&&h.success.length==2){if(typeof window[h.success[0]]!="undefined"){if(typeof window[h.success[0]][h.success[1]]=="function"){if(i){l=i(l,d.filterArguments)}window[h.success[0]][h.success[1]](l)}}}else{if(typeof h.success=="string"){if(typeof window[h.success]=="function"){if(i){l=i(l,d.filterArguments)}window[h.success](l)}}else{if(typeof h.success=="function"){if(i){l=i(l,d.filterArguments)}h.success(l)}}}}},error:function(l){if(g){if(typeof h.error=="object"&&h.error.length==2){if(typeof window[h.error[0]][h.error[1]]=="function"){window[h.error[0]][h.error[1]](l)}}else{if(typeof h.error=="string"){if(typeof window[h.error]=="function"){window[h.error](l)}}else{if(typeof h.error=="function"){h.error(l)}}}}},statusCode:j})};this.getSelfInfo=function(j){var k=this,l=false,e=false,i=this.statusCode,f=false,d=this.getFilter("getSelfInfo");if(typeof j=="undefined"||j.length===0){l=true}else{if("success" in j){e=true}if("error" in j){f=true}if("statusCode" in j){i=j.statusCode}}var g="https://api.instagram.com/v1/users/self/?access_token="+b();var h=function(m){if(m===false){jQuery.ajax({type:"POST",dataType:"jsonp",url:g,success:function(o){c.setDataToCache(g,o);if(e){if(typeof j.success=="object"&&j.success.length==2){if(typeof window[j.success[0]]!="undefined"){if(typeof window[j.success[0]][j.success[1]]=="function"){if(d){o=d(o,k.filterArguments)}window[j.success[0]][j.success[1]](o)}}}else{if(typeof j.success=="string"){if(typeof window[j.success]=="function"){if(d){o=d(o,k.filterArguments)}window[j.success](o)}}else{if(typeof j.success=="function"){if(d){o=d(o,k.filterArguments)}j.success(o)}}}}},error:function(o){if(f){if(typeof j.error=="object"&&j.error.length==2){if(typeof window[j.error[0]][j.error[1]]=="function"){window[j.error[0]][j.error[1]](o)}}else{if(typeof j.error=="string"){if(typeof window[j.error]=="function"){window[j.error](o)}}else{if(typeof j.error=="function"){j.error(o)}}}}},statusCode:i})}else{n(m)}function n(o){if(e){if(typeof j.success=="object"&&j.success.length==2){if(typeof window[j.success[0]]!="undefined"){if(typeof window[j.success[0]][j.success[1]]=="function"){if(d){o=d(o,k.filterArguments)}window[j.success[0]][j.success[1]](o)}}}else{if(typeof j.success=="string"){if(typeof window[j.success]=="function"){if(d){o=d(o,k.filterArguments)}window[j.success](o)}}else{if(typeof j.success=="function"){if(d){o=d(o,k.filterArguments)}j.success(o)}}}}}};c.getDataFromCache(h,g)};this.getRecentMediaComments=function(f,k){var l=this,m=false,e=false,j=this.statusCode,h=false,d=this.getFilter("getRecentMediaComments");if(typeof k=="undefined"||k.length===0){m=true}else{if("success" in k){e=true}if("error" in k){h=true}if("statusCode" in k){j=k.statusCode}}var g="https://api.instagram.com/v1/media/"+f+"/comments?access_token="+b();var i=function(n){if(n===false){jQuery.ajax({type:"POST",dataType:"jsonp",url:g,success:function(p){c.setDataToCache(g,p);o(p)},error:function(p){if(h){if(typeof k.error=="object"&&k.error.length==2){if(typeof window[k.error[0]][k.error[1]]=="function"){window[k.error[0]][k.error[1]](p)}}else{if(typeof k.error=="string"){if(typeof window[k.error]=="function"){window[k.error](p)}}else{if(typeof k.error=="function"){k.error(p)}}}}},statusCode:j})}else{o(n)}function o(p){if(e){if(typeof k.success=="object"&&k.success.length==2){if(typeof window[k.success[0]]!="undefined"){if(typeof window[k.success[0]][k.success[1]]=="function"){if(d){p=d(p,l.filterArguments)}window[k.success[0]][k.success[1]](p)}}}else{if(typeof k.success=="string"){if(typeof window[k.success]=="function"){if(d){p=d(p,l.filterArguments)}window[k.success](p)}}else{if(typeof k.success=="function"){if(d){p=d(p,l.filterArguments)}k.success(p)}}}}}};c.getDataFromCache(i,g)};this.getRecentMediaLikes=function(j,g){var d=this,k=false,e=false,i=this.statusCode,f=false,h=this.getFilter("getRecentMediaLikes");if(typeof g=="undefined"||g.length===0){k=true}else{if("success" in g){e=true}if("error" in g){f=true}if("statusCode" in g){i=g.statusCode}}jQuery.ajax({type:"POST",dataType:"jsonp",url:"https://api.instagram.com/v1/media/"+j+"/likes?access_token="+b(),success:function(l){if(e){if(typeof g.success=="object"&&g.success.length==2){if(typeof window[g.success[0]]!="undefined"){if(typeof window[g.success[0]][g.success[1]]=="function"){if(h){l=h(l,d.filterArguments)}window[g.success[0]][g.success[1]](l)}}}else{if(typeof g.success=="string"){if(typeof window[g.success]=="function"){if(h){l=h(l,d.filterArguments)}window[g.success](l)}}else{if(typeof g.success=="function"){if(h){l=h(l,d.filterArguments)}g.success(l)}}}}},error:function(l){if(f){if(typeof g.error=="object"&&g.error.length==2){if(typeof window[g.error[0]][g.error[1]]=="function"){window[g.error[0]][g.error[1]](l)}}else{if(typeof g.error=="string"){if(typeof window[g.error]=="function"){window[g.error](l)}}else{if(typeof g.error=="function"){g.error(l)}}}}},statusCode:i})};this.requestByUrl=function(o,n){var p=this,q=false,f=false,g=false,m=false,k=this.statusCode,e=this.getFilter("requestByUrl"),d,l;d=o.split("?")[1].split("&");for(var j=0;j<d.length;j++){d[j]=d[j].split("=");if(d[j][0]=="access_token"){d[j][1]=b()}d[j]=d[j].join("=")}d=d.join("&");o=o.split("?")[0]+"?"+d;if(typeof n=="undefined"||n.length===0){q=true}else{if("success" in n){f=true}if("args" in n){m=true}else{n.args={}}if("error" in n){g=true}if("statusCode" in n){k=n.statusCode}}var h=function(i){if(i===false){jQuery.ajax({type:"POST",dataType:"jsonp",url:o,success:function(s){c.setDataToCache(o,s);if(f){if(typeof n.success=="object"&&n.success.length==2){if(typeof window[n.success[0]]!="undefined"){if(typeof window[n.success[0]][n.success[1]]=="function"){if(e){s=e(s,p.filterArguments,n.args)}window[n.success[0]][n.success[1]](s)}}}else{if(typeof n.success=="string"){if(typeof window[n.success]=="function"){if(e){s=e(s,p.filterArguments,n.args)}window[n.success](s)}}else{if(typeof n.success=="function"){if(e){s=e(s,p.filterArguments,n.args)}n.success(s)}}}}},error:function(s){if(g){if(typeof n.error=="object"&&n.error.length==2){if(typeof window[n.error[0]][n.error[1]]=="function"){window[n.error[0]][n.error[1]](s)}}else{if(typeof n.error=="string"){if(typeof window[n.error]=="function"){window[n.error](s)}}else{if(typeof n.error=="function"){n.error(s)}}}}},statusCode:k})}else{r(i)}function r(s){if(f){if(typeof n.success=="object"&&n.success.length==2){if(typeof window[n.success[0]]!="undefined"){if(typeof window[n.success[0]][n.success[1]]=="function"){if(e){s=e(s,p.filterArguments,n.args)}window[n.success[0]][n.success[1]](s)}}}else{if(typeof n.success=="string"){if(typeof window[n.success]=="function"){if(e){s=e(s,p.filterArguments,n.args)}window[n.success](s)}}else{if(typeof n.success=="function"){if(e){s=e(s,p.filterArguments,n.args)}n.success(s)}}}}}};c.getDataFromCache(h,o)};this.getDataFromCache=function(e,d){jQuery.ajax({type:"POST",async:true,url:wdi_ajax.ajax_url,dataType:"json",data:{wdi_cache_name:d,wdi_nonce:wdi_ajax.wdi_nonce,action:"wdi_get_cache_data"},success:function(g){if(g.success!=="false"){if(typeof g.cache_data!=="undefined"){var f=JSON.parse(g.cache_data);e(f)}}else{e(false)}}})};this.setDataToCache=function(e,d){jQuery.ajax({type:"POST",url:wdi_ajax.ajax_url,dataType:"json",data:{wdi_cache_name:e,wdi_cache_response:JSON.stringify(d),wdi_nonce:wdi_ajax.wdi_nonce,action:"wdi_set_cache_data"},success:function(f){console.log(f)}})}};
1
+ function WDIInstagram(a){this.access_tokens=[];this.filters=[];if(typeof a!="undefined"){if(typeof a.access_tokens!="undefined"){this.access_tokens=a.access_tokens}if(typeof a.filters!="undefined"){this.filters=a.filters}}var c=this;this.statusCode={429:function(){console.log(" 429: Too many requests. Try after one hour")}};this.getFilter=function(d){var f=c.filters;if(typeof f=="undefined"){return false}for(var e=0;e<f.length;e++){if(f[e].where==d){if(typeof f[e].what=="object"&&f[e].what.length==2){if(typeof window[f[e].what[0]]!="undefined"){if(typeof window[f[e].what[0]][f[e].what[1]]=="function"){return window[f[e].what[0]][f[e].what[1]]}}}else{if(typeof f[e].what=="string"){if(typeof window[f[e].what]=="function"){return window[f[e].what]}}else{if(typeof f[e].what=="function"){return f[e].what}else{return false}}}}}return false};function b(){var d=c.access_tokens,e=parseInt(Math.random(0,1)*d.length);return d[e]}this.addToken=function(d){if(typeof d=="string"){c.access_tokens.push(d)}};this.resetTokens=function(){c.access_tokens=[]};this.getTagRecentMedia=function(m,k){var l=this,n=false,e=false,h=this.statusCode,f=false,j=false,d=this.getFilter("getTagRecentMedia"),i="https://api.instagram.com/v1/tags/"+m+"/media/recent?access_token="+b();if(typeof k=="undefined"||k.length===0){n=true}else{if("success" in k){e=true}if("statusCode" in k){h=k.statusCode}if("error" in k){f=true}if("args" in k){j=true}else{k.args={}}if("count" in k){k.count=parseInt(k.count);if(!Number.isInteger(k.count)||k.count<=0){k.count=33}}else{k.count=33}i+="&count="+k.count;if("min_tag_id" in k){i+="&min_tag_id="+k.min_tag_id}if("max_tag_id" in k){i+="&max_tag_id="+k.max_tag_id}}var g=function(o){if(o===false){jQuery.ajax({type:"POST",url:i,dataType:"jsonp",success:function(q){c.setDataToCache(i,q);p(q)},error:function(q){if(f){if(typeof k.error=="object"&&k.error.length==2){if(typeof window[k.error[0]][k.error[1]]=="function"){window[k.error[0]][k.error[1]](q)}}else{if(typeof k.error=="string"){if(typeof window[k.error]=="function"){window[k.error](q)}}else{if(typeof k.error=="function"){k.error(q)}}}}},statusCode:h})}else{p(o)}function p(q){if(typeof q.data==="undefined"){q.data=[]}if(e){if(typeof k.success=="object"&&k.success.length==2){if(typeof window[k.success[0]]!="undefined"){if(typeof window[k.success[0]][k.success[1]]=="function"){if(d){q=d(q,l.filterArguments,k.args)}window[k.success[0]][k.success[1]](q)}}}else{if(typeof k.success=="string"){if(typeof window[k.success]=="function"){if(d){q=d(q,l.filterArguments,k.args)}window[k.success](q)}}else{if(typeof k.success=="function"){if(d){q=d(q,l.filterArguments,k.args)}k.success(q)}}}}}};c.getDataFromCache(g,i)};this.searchForTagsByName=function(k,i){var j=this,l=false,d=false,h=this.statusCode,e=false;filter=this.getFilter("searchForTagsByName");if(typeof i=="undefined"||i.length===0){l=true}else{if("success" in i){d=true}if("error" in i){e=true}if("statusCode" in i){h=i.statusCode}}var f="https://api.instagram.com/v1/tags/search?q="+k+"&access_token="+b();var g=function(m){if(m===false){jQuery.ajax({type:"POST",url:f,dataType:"jsonp",success:function(o){c.setDataToCache(f,o);n(o)},error:function(o){if(e){if(typeof i.error=="object"&&i.error.length==2){if(typeof window[i.error[0]][i.error[1]]=="function"){window[i.error[0]][i.error[1]](o)}}else{if(typeof i.error=="string"){if(typeof window[i.error]=="function"){window[i.error](o)}}else{if(typeof i.error=="function"){i.error(o)}}}}},statusCode:h})}else{n(m)}function n(o){if(d){if(typeof i.success=="object"&&i.success.length==2){if(typeof window[i.success[0]]!="undefined"){if(typeof window[i.success[0]][i.success[1]]=="function"){if(filter){o=filter(o,j.filterArguments)}window[i.success[0]][i.success[1]](o)}}}else{if(typeof i.success=="string"){if(typeof window[i.success]=="function"){if(filter){o=filter(o,j.filterArguments)}window[i.success](o)}}else{if(typeof i.success=="function"){if(filter){o=filter(o,j.filterArguments)}i.success(o)}}}}}};c.getDataFromCache(g,f)};this.searchForUsersByName=function(k,g){var d=this,j=false,e=false,i=this.statusCode,f=false,h=this.getFilter("searchForUsersByName");if(typeof g=="undefined"||g.length===0){j=true}else{if("success" in g){e=true}if("error" in g){f=true}if("statusCode" in g){i=g.statusCode}}jQuery.ajax({type:"POST",dataType:"jsonp",url:"https://api.instagram.com/v1/users/search?q="+k+"&access_token="+b(),success:function(l){if(e){if(typeof g.success=="object"&&g.success.length==2){if(typeof window[g.success[0]]!="undefined"){if(typeof window[g.success[0]][g.success[1]]=="function"){if(h){l=h(l,d.filterArguments)}l.args=g;window[g.success[0]][g.success[1]](l)}}}else{if(typeof g.success=="string"){if(typeof window[g.success]=="function"){if(h){l=h(l,d.filterArguments)}l.args=g;window[g.success](l)}}else{if(typeof g.success=="function"){if(h){l=h(l,d.filterArguments)}l.args=g;g.success(l)}}}}},error:function(l){if(f){if(typeof g.error=="object"&&g.error.length==2){if(typeof window[g.error[0]][g.error[1]]=="function"){window[g.error[0]][g.error[1]](l)}}else{if(typeof g.error=="string"){if(typeof window[g.error]=="function"){window[g.error](l)}}else{if(typeof g.error=="function"){g.error(l)}}}}},statusCode:this.statusCode})};this.getRecentLikedMedia=function(g){var d=this,k=false,e=false,i=this.statusCode,f=false,h=this.getFilter("getRecentLikedMedia"),j="https://api.instagram.com/v1/users/self/media/liked?access_token="+b();if(typeof g=="undefined"||g.length===0){k=true}else{if("success" in g){e=true}if("error" in g){f=true}if("statusCode" in g){i=g.statusCode}if("args" in g){argFlag=true}else{g.args={}}if("count" in g){g.count=parseInt(g.count);if(!Number.isInteger(g.count)||g.count<=0){g.count=20}}else{g.count=20}j+="&count="+g.count;if("next_max_like_id" in g){j+="&next_max_like_id="+g.next_max_like_id}}jQuery.ajax({type:"POST",dataType:"jsonp",url:j,success:function(l){if(e){if(typeof g.success=="object"&&g.success.length==2){if(typeof window[g.success[0]]!="undefined"){if(typeof window[g.success[0]][g.success[1]]=="function"){if(h){l=h(l,d.filterArguments,g.args)}window[g.success[0]][g.success[1]](l)}}}else{if(typeof g.success=="string"){if(typeof window[g.success]=="function"){if(h){l=h(l,d.filterArguments,g.args)}window[g.success](l)}}else{if(typeof g.success=="function"){if(h){l=h(l,d.filterArguments,g.args)}g.success(l)}}}}},error:function(l){if(f){if(typeof g.error=="object"&&g.error.length==2){if(typeof window[g.error[0]][g.error[1]]=="function"){window[g.error[0]][g.error[1]](l)}}else{if(typeof g.error=="string"){if(typeof window[g.error]=="function"){window[g.error](l)}}else{if(typeof g.error=="function"){g.error(l)}}}}},statusCode:i})};this.getUserRecentMedia=function(l,j){var k=this,m=false,e=false,i=false,g=this.statusCode,f=false,d=this.getFilter("getUserRecentMedia"),h="https://api.instagram.com/v1/users/"+l+"/media/recent/?access_token="+b();if(typeof j=="undefined"||j.length===0){m=true}else{if("success" in j){e=true}if("statusCode" in j){g=j.statusCode}if("args" in j){i=true}else{j.args={}}if("error" in j){f=true}if("count" in j){j.count=parseInt(j.count);if(!Number.isInteger(j.count)||j.count<=0){j.count=33}}else{j.count=33}h+="&count="+j.count;if("min_id" in j){h+="&min_id="+j.min_id}if("max_id" in j){h+="&max_id="+j.max_id}}jQuery.ajax({type:"POST",dataType:"jsonp",url:h,success:function(n){if(typeof n.data==="undefined"){n.data=[]}if(e){if(typeof j.success=="object"&&j.success.length==2){if(typeof window[j.success[0]]!="undefined"){if(typeof window[j.success[0]][j.success[1]]=="function"){if(d){n=d(n,k.filterArguments,j.args)}window[j.success[0]][j.success[1]](n)}}}else{if(typeof j.success=="string"){if(typeof window[j.success]=="function"){if(d){n=d(n,k.filterArguments,j.args)}window[j.success](n)}}else{if(typeof j.success=="function"){if(d){n=d(n,k.filterArguments,j.args)}j.success(n)}}}}},error:function(n){if(f){if(typeof j.error=="object"&&j.error.length==2){if(typeof window[j.error[0]][j.error[1]]=="function"){window[j.error[0]][j.error[1]](n)}}else{if(typeof j.error=="string"){if(typeof window[j.error]=="function"){window[j.error](n)}}else{if(typeof j.error=="function"){j.error(n)}}}}},statusCode:g})};this.getSelfRecentMedia=function(k){var l=this,m=false,e=false,h=this.statusCode,f=false,j=false,d=this.getFilter("getSelfRecentMedia"),i="https://api.instagram.com/v1/users/self/media/recent/?access_token="+b();if(typeof k=="undefined"||k.length===0){m=true}else{if("success" in k){e=true}if("error" in k){f=true}if("statusCode" in k){h=k.statusCode}if("args" in k){j=true}else{k.args={}}if("count" in k){k.count=parseInt(k.count);if(!Number.isInteger(k.count)||k.count<=0){k.count=20}}else{k.count=20}i+="&count="+k.count;if("min_id" in k){i+="&min_id="+k.min_id}if("max_id" in k){i+="&max_id="+k.max_id}}var g=function(n){if(n===false){jQuery.ajax({type:"POST",dataType:"jsonp",url:i,success:function(p){c.setDataToCache(i,p);o(p)},error:function(p){if(f){if(typeof k.error=="object"&&k.error.length==2){if(typeof window[k.error[0]][k.error[1]]=="function"){window[k.error[0]][k.error[1]](p)}}else{if(typeof k.error=="string"){if(typeof window[k.error]=="function"){window[k.error](p)}}else{if(typeof k.error=="function"){k.error(p)}}}}},statusCode:h})}else{o(n)}function o(p){if(e){if(typeof k.success=="object"&&k.success.length==2){if(typeof window[k.success[0]]!="undefined"){if(typeof window[k.success[0]][k.success[1]]=="function"){if(d){p=d(p,l.filterArguments,k)}window[k.success[0]][k.success[1]](p)}}}else{if(typeof k.success=="string"){if(typeof window[k.success]=="function"){if(d){p=d(p,l.filterArguments,k)}window[k.success](p)}}else{if(typeof k.success=="function"){if(d){p=d(p,l.filterArguments,k)}k.success(p)}}}}}};c.getDataFromCache(g,i)};this.getUserInfo=function(e,h){var d=this,k=false,f=false,j=this.statusCode,g=false,i=this.getFilter("getUserInfo");if(typeof h=="undefined"||h.length===0){k=true}else{if("success" in h){f=true}if("error" in h){g=true}if("statusCode" in h){j=h.statusCode}}jQuery.ajax({type:"POST",dataType:"jsonp",url:"https://api.instagram.com/v1/users/"+e+"/?access_token="+b(),success:function(l){if(f){if(typeof h.success=="object"&&h.success.length==2){if(typeof window[h.success[0]]!="undefined"){if(typeof window[h.success[0]][h.success[1]]=="function"){if(i){l=i(l,d.filterArguments)}window[h.success[0]][h.success[1]](l)}}}else{if(typeof h.success=="string"){if(typeof window[h.success]=="function"){if(i){l=i(l,d.filterArguments)}window[h.success](l)}}else{if(typeof h.success=="function"){if(i){l=i(l,d.filterArguments)}h.success(l)}}}}},error:function(l){if(g){if(typeof h.error=="object"&&h.error.length==2){if(typeof window[h.error[0]][h.error[1]]=="function"){window[h.error[0]][h.error[1]](l)}}else{if(typeof h.error=="string"){if(typeof window[h.error]=="function"){window[h.error](l)}}else{if(typeof h.error=="function"){h.error(l)}}}}},statusCode:j})};this.getSelfInfo=function(j){var k=this,l=false,e=false,i=this.statusCode,f=false,d=this.getFilter("getSelfInfo");if(typeof j=="undefined"||j.length===0){l=true}else{if("success" in j){e=true}if("error" in j){f=true}if("statusCode" in j){i=j.statusCode}}var g="https://api.instagram.com/v1/users/self/?access_token="+b();var h=function(m){if(m===false){jQuery.ajax({type:"POST",dataType:"jsonp",url:g,success:function(o){c.setDataToCache(g,o);if(e){if(typeof j.success=="object"&&j.success.length==2){if(typeof window[j.success[0]]!="undefined"){if(typeof window[j.success[0]][j.success[1]]=="function"){if(d){o=d(o,k.filterArguments)}window[j.success[0]][j.success[1]](o)}}}else{if(typeof j.success=="string"){if(typeof window[j.success]=="function"){if(d){o=d(o,k.filterArguments)}window[j.success](o)}}else{if(typeof j.success=="function"){if(d){o=d(o,k.filterArguments)}j.success(o)}}}}},error:function(o){if(f){if(typeof j.error=="object"&&j.error.length==2){if(typeof window[j.error[0]][j.error[1]]=="function"){window[j.error[0]][j.error[1]](o)}}else{if(typeof j.error=="string"){if(typeof window[j.error]=="function"){window[j.error](o)}}else{if(typeof j.error=="function"){j.error(o)}}}}},statusCode:i})}else{n(m)}function n(o){if(e){if(typeof j.success=="object"&&j.success.length==2){if(typeof window[j.success[0]]!="undefined"){if(typeof window[j.success[0]][j.success[1]]=="function"){if(d){o=d(o,k.filterArguments)}window[j.success[0]][j.success[1]](o)}}}else{if(typeof j.success=="string"){if(typeof window[j.success]=="function"){if(d){o=d(o,k.filterArguments)}window[j.success](o)}}else{if(typeof j.success=="function"){if(d){o=d(o,k.filterArguments)}j.success(o)}}}}}};c.getDataFromCache(h,g)};this.getRecentMediaComments=function(f,k){var l=this,m=false,e=false,j=this.statusCode,h=false,d=this.getFilter("getRecentMediaComments");if(typeof k=="undefined"||k.length===0){m=true}else{if("success" in k){e=true}if("error" in k){h=true}if("statusCode" in k){j=k.statusCode}}var g="https://api.instagram.com/v1/media/"+f+"/comments?access_token="+b();var i=function(n){if(n===false){jQuery.ajax({type:"POST",dataType:"jsonp",url:g,success:function(p){c.setDataToCache(g,p);o(p)},error:function(p){if(h){if(typeof k.error=="object"&&k.error.length==2){if(typeof window[k.error[0]][k.error[1]]=="function"){window[k.error[0]][k.error[1]](p)}}else{if(typeof k.error=="string"){if(typeof window[k.error]=="function"){window[k.error](p)}}else{if(typeof k.error=="function"){k.error(p)}}}}},statusCode:j})}else{o(n)}function o(p){if(e){if(typeof k.success=="object"&&k.success.length==2){if(typeof window[k.success[0]]!="undefined"){if(typeof window[k.success[0]][k.success[1]]=="function"){if(d){p=d(p,l.filterArguments)}window[k.success[0]][k.success[1]](p)}}}else{if(typeof k.success=="string"){if(typeof window[k.success]=="function"){if(d){p=d(p,l.filterArguments)}window[k.success](p)}}else{if(typeof k.success=="function"){if(d){p=d(p,l.filterArguments)}k.success(p)}}}}}};c.getDataFromCache(i,g)};this.getRecentMediaLikes=function(j,g){var d=this,k=false,e=false,i=this.statusCode,f=false,h=this.getFilter("getRecentMediaLikes");if(typeof g=="undefined"||g.length===0){k=true}else{if("success" in g){e=true}if("error" in g){f=true}if("statusCode" in g){i=g.statusCode}}jQuery.ajax({type:"POST",dataType:"jsonp",url:"https://api.instagram.com/v1/media/"+j+"/likes?access_token="+b(),success:function(l){if(e){if(typeof g.success=="object"&&g.success.length==2){if(typeof window[g.success[0]]!="undefined"){if(typeof window[g.success[0]][g.success[1]]=="function"){if(h){l=h(l,d.filterArguments)}window[g.success[0]][g.success[1]](l)}}}else{if(typeof g.success=="string"){if(typeof window[g.success]=="function"){if(h){l=h(l,d.filterArguments)}window[g.success](l)}}else{if(typeof g.success=="function"){if(h){l=h(l,d.filterArguments)}g.success(l)}}}}},error:function(l){if(f){if(typeof g.error=="object"&&g.error.length==2){if(typeof window[g.error[0]][g.error[1]]=="function"){window[g.error[0]][g.error[1]](l)}}else{if(typeof g.error=="string"){if(typeof window[g.error]=="function"){window[g.error](l)}}else{if(typeof g.error=="function"){g.error(l)}}}}},statusCode:i})};this.requestByUrl=function(o,n){var p=this,q=false,f=false,g=false,m=false,k=this.statusCode,e=this.getFilter("requestByUrl"),d,l;d=o.split("?")[1].split("&");for(var j=0;j<d.length;j++){d[j]=d[j].split("=");if(d[j][0]=="access_token"){d[j][1]=b()}d[j]=d[j].join("=")}d=d.join("&");o=o.split("?")[0]+"?"+d;if(typeof n=="undefined"||n.length===0){q=true}else{if("success" in n){f=true}if("args" in n){m=true}else{n.args={}}if("error" in n){g=true}if("statusCode" in n){k=n.statusCode}}var h=function(i){if(i===false){jQuery.ajax({type:"POST",dataType:"jsonp",url:o,success:function(s){c.setDataToCache(o,s);if(f){if(typeof n.success=="object"&&n.success.length==2){if(typeof window[n.success[0]]!="undefined"){if(typeof window[n.success[0]][n.success[1]]=="function"){if(e){s=e(s,p.filterArguments,n.args)}window[n.success[0]][n.success[1]](s)}}}else{if(typeof n.success=="string"){if(typeof window[n.success]=="function"){if(e){s=e(s,p.filterArguments,n.args)}window[n.success](s)}}else{if(typeof n.success=="function"){if(e){s=e(s,p.filterArguments,n.args)}n.success(s)}}}}},error:function(s){if(g){if(typeof n.error=="object"&&n.error.length==2){if(typeof window[n.error[0]][n.error[1]]=="function"){window[n.error[0]][n.error[1]](s)}}else{if(typeof n.error=="string"){if(typeof window[n.error]=="function"){window[n.error](s)}}else{if(typeof n.error=="function"){n.error(s)}}}}},statusCode:k})}else{r(i)}function r(s){if(f){if(typeof n.success=="object"&&n.success.length==2){if(typeof window[n.success[0]]!="undefined"){if(typeof window[n.success[0]][n.success[1]]=="function"){if(e){s=e(s,p.filterArguments,n.args)}window[n.success[0]][n.success[1]](s)}}}else{if(typeof n.success=="string"){if(typeof window[n.success]=="function"){if(e){s=e(s,p.filterArguments,n.args)}window[n.success](s)}}else{if(typeof n.success=="function"){if(e){s=e(s,p.filterArguments,n.args)}n.success(s)}}}}}};c.getDataFromCache(h,o)};this.getDataFromCache=function(e,d){jQuery.ajax({type:"POST",async:true,url:wdi_ajax.ajax_url,dataType:"json",data:{wdi_cache_name:d,wdi_nonce:wdi_ajax.wdi_nonce,WDI_MINIFY:wdi_ajax.WDI_MINIFY,action:"wdi_get_cache_data"},success:function(g){if(g.wdi_debugging){console.log(g.wdi_debugging_data)}if(g.success){if(typeof g.cache_data!=="undefined"&&g.cache_data!==null){var f=JSON.parse(g.cache_data);e(f)}else{e(false)}}else{e(false)}}})};this.setDataToCache=function(e,d){jQuery.ajax({type:"POST",url:wdi_ajax.ajax_url,dataType:"json",data:{wdi_cache_name:e,wdi_cache_response:JSON.stringify(d),wdi_nonce:wdi_ajax.wdi_nonce,action:"wdi_set_cache_data"},success:function(f){}})}};
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: custom instagram feed, feed, instagram, hashtag, Instagram feed, instagram
4
  Requires at least: 3.9
5
  Requires PHP: 5.2
6
  Tested up to: 4.9
7
- Stable tag: 1.3.2
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -498,6 +498,11 @@ Please make sure you don't have any important information before you proceed.
498
 
499
  == Changelog ==
500
 
 
 
 
 
 
501
  = 1.3.2 =
502
  New: Signing up with multiple accounts
503
  Fixed: Settings page layout when language is not English
4
  Requires at least: 3.9
5
  Requires PHP: 5.2
6
  Tested up to: 4.9
7
+ Stable tag: 1.3.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
498
 
499
  == Changelog ==
500
 
501
+ = 1.3.3 =
502
+ New: Cache debugging tools
503
+ New: WD library updated
504
+ New: GDPR compliance help
505
+
506
  = 1.3.2 =
507
  New: Signing up with multiple accounts
508
  Fixed: Settings page layout when language is not English
wd-instagram-feed.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: WD Instagram Feed
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.3.2
7
  Author: WebDorado
8
  Author URI: https://web-dorado.com/wordpress-plugins-bundle.html
9
  License: GPLv2 or later
@@ -21,7 +21,7 @@ define("WDI_META", "_".WDI_VAR."_meta");
21
  //define("wdi",'wdi');
22
  define('WDI_FEED_TABLE','wdi_feeds');
23
  define('WDI_THEME_TABLE','wdi_themes');
24
- define('WDI_VERSION','1.3.2');
25
  define('WDI_IS_PRO','false');
26
  $wdi_minify = ((isset($_GET['wdi_no_minify']) && $_GET['wdi_no_minify'] == "true") ? false : true);
27
  define('WDI_MINIFY', $wdi_minify);
@@ -78,17 +78,55 @@ function wdi_get_cache_data(){
78
  if(isset($_POST["wdi_cache_name"])){
79
  $transient_key = "wdi_cache_data_".md5($_POST["wdi_cache_name"]);
80
  $cache_data = get_transient($transient_key);
81
- if(isset($cache_data) && $cache_data!=false){
82
- echo json_encode(
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
83
  array(
84
- "success"=>"true",
85
- "cache_data"=>stripslashes($cache_data)
 
 
86
  )
87
  );
88
- die;
 
89
  }
90
  }
91
- echo json_encode(array("success"=>"false"));die;
92
  }
93
  }
94
  function wdi_set_cache_data(){
@@ -101,8 +139,10 @@ function wdi_set_cache_data(){
101
  $wdi_transient_time = 60;
102
  }
103
 
 
104
 
105
  $wdi_cache_response = $_POST["wdi_cache_response"];
 
106
  $transient_key = "wdi_cache_data_".md5($_POST["wdi_cache_name"]);
107
  $expiration_time = $wdi_transient_time * 60;
108
 
@@ -111,9 +151,24 @@ function wdi_set_cache_data(){
111
  $wdi_cache_response = utf8_encode($wdi_cache_response);
112
  }
113
 
114
- set_transient($transient_key, $wdi_cache_response, $expiration_time);
 
 
 
 
 
 
 
 
115
  }
 
116
  }
 
 
 
 
 
 
117
  }
118
 
119
 
@@ -441,7 +496,8 @@ function wdi_load_scripts($hook){
441
  'ajax_url' => admin_url( 'admin-ajax.php' ),
442
  'uninstall_url' => $uninstall_url,
443
  'wdi_nonce' => wp_create_nonce("wdi_cache"),
444
- 'is_pro' => WDI_IS_PRO
 
445
  ));
446
  wp_localize_script("wdi_admin", 'wdi_version',array('is_pro'=>WDI_IS_PRO));
447
  wp_localize_script("wdi_admin", 'wdi_messages',array(
@@ -952,4 +1008,20 @@ function wdi_filter_var_notice(){
952
  <p>Some functionality may be broken. Please enable PHP Filters extension or make sure you have PHP version not older than 5.2.</p>
953
  </div>";
954
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
955
  }
3
  Plugin Name: WD Instagram Feed
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.3.3
7
  Author: WebDorado
8
  Author URI: https://web-dorado.com/wordpress-plugins-bundle.html
9
  License: GPLv2 or later
21
  //define("wdi",'wdi');
22
  define('WDI_FEED_TABLE','wdi_feeds');
23
  define('WDI_THEME_TABLE','wdi_themes');
24
+ define('WDI_VERSION','1.3.3');
25
  define('WDI_IS_PRO','false');
26
  $wdi_minify = ((isset($_GET['wdi_no_minify']) && $_GET['wdi_no_minify'] == "true") ? false : true);
27
  define('WDI_MINIFY', $wdi_minify);
78
  if(isset($_POST["wdi_cache_name"])){
79
  $transient_key = "wdi_cache_data_".md5($_POST["wdi_cache_name"]);
80
  $cache_data = get_transient($transient_key);
81
+
82
+ if(isset($cache_data) && $cache_data!=false && isset($cache_data["cache_response"])){
83
+
84
+ $wdi_debugging = false;
85
+ $wdi_debugging_data = array();
86
+
87
+ if(isset($_POST["WDI_MINIFY"])&& $_POST["WDI_MINIFY"] === "false"){
88
+
89
+
90
+ $wdi_debugging = true;
91
+
92
+
93
+ $current_date = (date('Y-m-d H:i:s'));
94
+ $cache_date = $cache_data["wdi_debugging_data"]["cache_date"];
95
+ $wdi_transient_time = $cache_data["wdi_debugging_data"]["wdi_transient_time"];
96
+
97
+
98
+ $current_date_strtotime = strtotime($current_date);
99
+ $cache_date_strtotime = strtotime($cache_date);
100
+ $seconds_diff = $current_date_strtotime - $cache_date_strtotime;
101
+ $date_diff_min = $seconds_diff/60;
102
+
103
+
104
+
105
+
106
+ $wdi_debugging_data = array(
107
+ 'current_date' => $current_date,
108
+ 'cache_date' => $cache_date,
109
+ 'date_diff_min' => $date_diff_min,
110
+ 'transient_key' => $_POST["wdi_cache_name"],
111
+ 'wdi_transient_time' => $wdi_transient_time,
112
+ );
113
+
114
+
115
+ }
116
+ $cache_data = stripslashes($cache_data["cache_response"]);
117
+ wdi_send_response(
118
  array(
119
+ "success"=>true,
120
+ "wdi_debugging" => $wdi_debugging,
121
+ "wdi_debugging_data" => $wdi_debugging_data,
122
+ "cache_data"=>$cache_data
123
  )
124
  );
125
+ }else{
126
+ wdi_send_response(array("success"=>false));
127
  }
128
  }
129
+ wdi_send_response(array("success"=>false));
130
  }
131
  }
132
  function wdi_set_cache_data(){
139
  $wdi_transient_time = 60;
140
  }
141
 
142
+ $cache_date = (date('Y-m-d H:i:s'));
143
 
144
  $wdi_cache_response = $_POST["wdi_cache_response"];
145
+
146
  $transient_key = "wdi_cache_data_".md5($_POST["wdi_cache_name"]);
147
  $expiration_time = $wdi_transient_time * 60;
148
 
151
  $wdi_cache_response = utf8_encode($wdi_cache_response);
152
  }
153
 
154
+ $data = array(
155
+ 'cache_response' => $wdi_cache_response,
156
+ 'wdi_debugging_data' => array(
157
+ 'cache_date' => $cache_date,
158
+ 'wdi_transient_time' => $wdi_transient_time,
159
+ ),
160
+ );
161
+ set_transient($transient_key, $data, $expiration_time);
162
+ wdi_send_response(array('success'=>true));
163
  }
164
+ wdi_send_response(array('success'=>false));
165
  }
166
+ wdi_send_response(array('success'=>false));
167
+ }
168
+
169
+ function wdi_send_response($data){
170
+ echo json_encode($data);
171
+ die;
172
  }
173
 
174
 
496
  'ajax_url' => admin_url( 'admin-ajax.php' ),
497
  'uninstall_url' => $uninstall_url,
498
  'wdi_nonce' => wp_create_nonce("wdi_cache"),
499
+ 'WDI_MINIFY'=>(WDI_MINIFY) ? 'true' : 'false',
500
+ 'is_pro' => WDI_IS_PRO,
501
  ));
502
  wp_localize_script("wdi_admin", 'wdi_version',array('is_pro'=>WDI_IS_PRO));
503
  wp_localize_script("wdi_admin", 'wdi_messages',array(
1008
  <p>Some functionality may be broken. Please enable PHP Filters extension or make sure you have PHP version not older than 5.2.</p>
1009
  </div>";
1010
  }
1011
+ }
1012
+
1013
+ add_filter('wp_get_default_privacy_policy_content', 'wdi_privacy_policy');
1014
+ function wdi_privacy_policy($content){
1015
+ $title = __('Instagram Feed WD', "wd-instagram-feed");
1016
+
1017
+ $pp_link = '<a target="_blank" href="https://instagram.com/legal/privacy">' . __('Privacy Policy', "wd-instagram-feed") . '</a>';
1018
+ $text = __('Use this suggested text to inform visitors about privacy:', "wd-instagram-feed");
1019
+ $text .= "<br/>";
1020
+ $text .= sprintf(__('"Instagram Feed WD plugin uses Instagram API on website front end. All the data received from Instagram via API is cached in WordPress database for some short period to provide front end optimization. You may request us to delete your Instagram data if it is accidentally cached in our website database with hashtag feed data. Instagram saves some cookies in browsers of website visitors via API data. These cookies are mostly used for security purposes. They are regulated under terms of Instagram’s %s."', "wd-instagram-feed"), $pp_link);
1021
+ $text .= "<br/>";
1022
+ $text .= __('Web-Dorado Disclaimer: The above text is for informational purposes only and is not a legal advice. You must not rely on it as an alternative to legal advice. You should contact your legal counsel to obtain advice with respect to your particular case.', "wd-instagram-feed");
1023
+ $pp_text = '<h3>' . $title . '</h3>' . '<p class="wp-policy-help">' . $text . '</p>';
1024
+
1025
+ $content .= $pp_text;
1026
+ return $content;
1027
  }
wd/README.md CHANGED
@@ -1,4 +1,4 @@
1
- Version: 1.0.13
2
 
3
 
4
 
1
+ Version: 1.0.15
2
 
3
 
4
 
wd/assets/css/deactivate_popup.css CHANGED
@@ -63,12 +63,20 @@
63
  margin: 14px 0px 5px;
64
  }
65
  .wd-popup-active1{
66
- height: 523px !important;
67
  }
68
 
69
  .wd-popup-active2{
70
  height: 426px !important
71
  }
 
 
 
 
 
 
 
 
72
  .wd-deactivate-popup-opacity{
73
  width: 100%;
74
  height: 100%;
@@ -87,4 +95,17 @@
87
  bottom: 0;
88
  margin: auto;
89
  z-index: 63;
 
 
 
 
 
 
 
 
 
 
 
 
 
90
  }
63
  margin: 14px 0px 5px;
64
  }
65
  .wd-popup-active1{
66
+ height: 583px !important;
67
  }
68
 
69
  .wd-popup-active2{
70
  height: 426px !important
71
  }
72
+
73
+ .wd-popup-active3{
74
+ height: 479px !important
75
+ }
76
+
77
+ .wd-popup-active4{
78
+ height: 340px !important
79
+ }
80
  .wd-deactivate-popup-opacity{
81
  width: 100%;
82
  height: 100%;
95
  bottom: 0;
96
  margin: auto;
97
  z-index: 63;
98
+ }
99
+
100
+ .wd-deactivate-popup-close-btn{
101
+ background-image: url(img/close.svg);
102
+ background-repeat: no-repeat;
103
+ background-size: 16px;
104
+ display: inline-block;
105
+ width: 16px;
106
+ height: 16px;
107
+ position: absolute;
108
+ top: 7px;
109
+ right: 8px;
110
+ cursor: pointer;
111
  }
wd/assets/css/img/close.svg ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="6917.521 490.293 11.414 11.414">
2
+ <defs>
3
+ <style>
4
+ .cls-1 {
5
+ fill: none;
6
+ stroke: #cbcbcb;
7
+ stroke-linecap: round;
8
+ stroke-linejoin: round;
9
+ }
10
+ </style>
11
+ </defs>
12
+ <g id="if_misc-_close__1276877_3_" data-name="if_misc-_close__1276877 (3)" transform="translate(6917.229 490)">
13
+ <line id="Line_262" data-name="Line 262" class="cls-1" y1="10" x2="10" transform="translate(1 1)"/>
14
+ <line id="Line_263" data-name="Line 263" class="cls-1" x2="10" y2="10" transform="translate(1 1)"/>
15
+ </g>
16
+ </svg>
wd/assets/js/deactivate_popup.js CHANGED
@@ -21,7 +21,13 @@ var btnVal = 3;
21
  ////////////////////////////////////////////////////////////////////////////////////////
22
  function wdReady(prefix){
23
 
 
 
24
  jQuery(document).on("click", "." + window[prefix + "WDDeactivateVars"].deactivate_class, function(){
 
 
 
 
25
  jQuery(".wd-" + prefix + "-opacity").show();
26
  jQuery(".wd-" + prefix + "-deactivate-popup").show();
27
  if(jQuery(this).attr("data-uninstall") == "1"){
@@ -30,17 +36,19 @@ function wdReady(prefix){
30
 
31
  return false;
32
  });
33
-
34
- jQuery(document).on("change", "[name=" + prefix + "_reasons]", function(){
35
 
36
- jQuery("." + prefix + "_additional_details_wrap").html("");
37
- jQuery(".wd-" + prefix + "-deactivate-popup").removeClass("wd-popup-active1 wd-popup-active2");
 
 
 
 
38
  if(jQuery(this).val() == "reason_plugin_is_hard_to_use_technical_problems"){
39
 
40
  additionalInfo = '<div class="wd-additional-active"><div><strong>Please describe your issue.</strong></div><br>' +
41
  '<textarea name="' + prefix + '_additional_details" rows = "4"></textarea><br>' +
42
  '<div>Our support will contact <input type="text" name="' + prefix + '_email" value="' + window[prefix + "WDDeactivateVars"].email + '"> shortly.</div>'+
43
- '<br><div><button class="button button-primary wd-' + prefix + '-deactivate" data-val="' + btnVal + '">Submit support ticket</button></div></div>';
44
  jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
45
  jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active1");
46
 
@@ -57,11 +65,22 @@ function wdReady(prefix){
57
  additionalInfo = '<div class="wd-additional-active">' +
58
  '<div><strong>We have a special offer for you.</strong></div>' +
59
  '<div>Submit this form to get the offer to <input type="text" name="' + prefix + '_email" value="' + window[prefix + "WDDeactivateVars"].email + '"></div>' +
60
- '<br><div><button class="button button-primary wd-' + prefix + '-deactivate" data-val="' + btnVal + '">Submit</button></div></div>';
61
 
62
  jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
63
- jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active2");
64
- }
 
 
 
 
 
 
 
 
 
 
 
65
 
66
  jQuery("#wd-" + prefix + "-deactivate").hide();
67
  jQuery("#wd-" + prefix + "-submit-and-deactivate").show();
@@ -78,7 +97,27 @@ function wdReady(prefix){
78
  }
79
 
80
  });
81
- jQuery(document).on("click", ".wd-" + prefix + "-deactivate", function(){
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
82
  jQuery(".wd-deactivate-popup-opacity-" + prefix).show();
83
  if(jQuery(this).hasClass("wd-clicked") == false){
84
  jQuery(this).addClass("wd-clicked");
@@ -88,12 +127,25 @@ function wdReady(prefix){
88
  return false;
89
  });
90
 
91
- jQuery(document).on("click", ".wd-" + prefix + "-cancel, .wd-opacity", function(){
92
  jQuery(".wd-" + prefix + "-opacity").hide();
93
  jQuery(".wd-" + prefix + "-deactivate-popup").hide();
 
 
94
  return false;
95
  });
96
 
 
 
 
 
 
 
 
 
 
 
 
97
  }
98
 
99
  ////////////////////////////////////////////////////////////////////////////////////////
21
  ////////////////////////////////////////////////////////////////////////////////////////
22
  function wdReady(prefix){
23
 
24
+ var agree_with_pp = false;
25
+
26
  jQuery(document).on("click", "." + window[prefix + "WDDeactivateVars"].deactivate_class, function(){
27
+ agree_with_pp = false;
28
+ if (!jQuery('#wd-' + prefix + '-submit-and-deactivate').hasClass('button-primary-disabled')) {
29
+ jQuery('#wd-' + prefix + '-submit-and-deactivate').addClass('button-primary-disabled')
30
+ }
31
  jQuery(".wd-" + prefix + "-opacity").show();
32
  jQuery(".wd-" + prefix + "-deactivate-popup").show();
33
  if(jQuery(this).attr("data-uninstall") == "1"){
36
 
37
  return false;
38
  });
 
 
39
 
40
+ jQuery(document).on("change", "[name=" + prefix + "_reasons]", function(){
41
+
42
+ var disabled_class = (agree_with_pp === false) ? "button-primary-disabled" : "";
43
+
44
+ jQuery("." + prefix + "_additional_details_wrap").html("");
45
+ jQuery(".wd-" + prefix + "-deactivate-popup").removeClass("wd-popup-active1 wd-popup-active2 wd-popup-active3 wd-popup-active4");
46
  if(jQuery(this).val() == "reason_plugin_is_hard_to_use_technical_problems"){
47
 
48
  additionalInfo = '<div class="wd-additional-active"><div><strong>Please describe your issue.</strong></div><br>' +
49
  '<textarea name="' + prefix + '_additional_details" rows = "4"></textarea><br>' +
50
  '<div>Our support will contact <input type="text" name="' + prefix + '_email" value="' + window[prefix + "WDDeactivateVars"].email + '"> shortly.</div>'+
51
+ '<br><div><button class="button button-primary ' + disabled_class + ' wd-' + prefix + '-deactivate" data-val="' + btnVal + '">Submit support ticket</button></div></div>';
52
  jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
53
  jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active1");
54
 
65
  additionalInfo = '<div class="wd-additional-active">' +
66
  '<div><strong>We have a special offer for you.</strong></div>' +
67
  '<div>Submit this form to get the offer to <input type="text" name="' + prefix + '_email" value="' + window[prefix + "WDDeactivateVars"].email + '"></div>' +
68
+ '<br><div><button class="button button-primary ' + disabled_class + ' wd-' + prefix + '-deactivate" data-val="' + btnVal + '">Submit</button></div></div>';
69
 
70
  jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
71
+ jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active3");
72
+ }else{
73
+ jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active4");
74
+ }
75
+
76
+ var checked = (agree_with_pp === true) ? "checked" : "";
77
+ var agree_checkbox =
78
+ "<div style='margin-top: 5px;'>" +
79
+ "<input type='checkbox' " + checked + " name='" + prefix + "_agree_with_pp" + "' id='" + prefix + "_agree_with_pp" + "'/>" +
80
+ "By submitting this form your email and website URL will be sent to Web-Dorado. Click the checkbox if you consent to usage of mentioned data by Web-Dorado in accordance with our <a target='_blank' href='https://web-dorado.com/web-dorado-privacy-statement.html'>Privacy Policy</a>."+
81
+ "</div>";
82
+
83
+ jQuery("." + prefix + "_additional_details_wrap").prepend(agree_checkbox);
84
 
85
  jQuery("#wd-" + prefix + "-deactivate").hide();
86
  jQuery("#wd-" + prefix + "-submit-and-deactivate").show();
97
  }
98
 
99
  });
100
+
101
+ jQuery(document).on("change", "[name=" + prefix + "_agree_with_pp]", function () {
102
+ if(jQuery(this).prop('checked')){
103
+ jQuery(".wd-" + prefix + "-deactivate").removeClass('button-primary-disabled');
104
+ agree_with_pp = true;
105
+ }else{
106
+ jQuery(".wd-" + prefix + "-deactivate").addClass('button-primary-disabled');
107
+ agree_with_pp = false;
108
+ }
109
+ });
110
+
111
+ jQuery(document).on("click", ".wd-" + prefix + "-deactivate", function(e){
112
+
113
+ var data_val = jQuery(this).data('val');
114
+ var checkbox = jQuery("#" + prefix + "_agree_with_pp");
115
+
116
+
117
+ if (data_val !== 1 && (checkbox.length === 0 || checkbox.prop('checked') === false)) {
118
+ return false;
119
+ }
120
+
121
  jQuery(".wd-deactivate-popup-opacity-" + prefix).show();
122
  if(jQuery(this).hasClass("wd-clicked") == false){
123
  jQuery(this).addClass("wd-clicked");
127
  return false;
128
  });
129
 
130
+ jQuery(document).on("click", ".wd-" + prefix + "-cancel, .wd-opacity, .wd-deactivate-popup-close-btn", function(){
131
  jQuery(".wd-" + prefix + "-opacity").hide();
132
  jQuery(".wd-" + prefix + "-deactivate-popup").hide();
133
+ reset_popup();
134
+
135
  return false;
136
  });
137
 
138
+ function reset_popup() {
139
+ jQuery("." + prefix + "_additional_details_wrap").html("");
140
+ jQuery(".wd-" + prefix + "-deactivate-popup").removeClass("wd-popup-active1 wd-popup-active2 wd-popup-active3 wd-popup-active4");
141
+
142
+ jQuery("#wd-" + prefix + "-deactivate").removeClass("button-primary-disabled");
143
+ jQuery("#wd-" + prefix + "-deactivate").show();
144
+ jQuery("#wd-" + prefix + "-submit-and-deactivate").hide();
145
+ jQuery('#' + prefix + '_deactivate_form input[name="' + prefix + '_reasons' + '"]').prop('checked', false);
146
+
147
+ }
148
+
149
  }
150
 
151
  ////////////////////////////////////////////////////////////////////////////////////////
wd/config.php CHANGED
@@ -36,6 +36,7 @@
36
  public $custom_post = null;
37
  public $menu_capability = null;
38
  public $menu_position = null;
 
39
 
40
  public function set_options( $options ){
41
 
@@ -108,7 +109,10 @@
108
  }
109
  if(isset( $options["menu_position"] )) {
110
  $this->menu_position = $options["menu_position"];
111
- }
 
 
 
112
 
113
  // directories
114
  $this->wd_dir = dirname( $this->plugin_main_file ) . '/wd';
36
  public $custom_post = null;
37
  public $menu_capability = null;
38
  public $menu_position = null;
39
+ public $start_using_url = null;
40
 
41
  public function set_options( $options ){
42
 
109
  }
110
  if(isset( $options["menu_position"] )) {
111
  $this->menu_position = $options["menu_position"];
112
+ }
113
+ if(isset( $options["start_using_url"] )) {
114
+ $this->start_using_url = $options["start_using_url"];
115
+ }
116
 
117
  // directories
118
  $this->wd_dir = dirname( $this->plugin_main_file ) . '/wd';
wd/includes/deactivate.php CHANGED
@@ -44,7 +44,7 @@
44
  ),
45
  4 => array(
46
  'id' => self::REASON_UPGRADING_TO_PAID_VERSION,
47
- 'text' => __( 'Upgrading to premium version', $wd_options->prefix ),
48
  ),
49
  5 => array(
50
  'id' => self::REASON_TEMPORARY_DEACTIVATION,
44
  ),
45
  4 => array(
46
  'id' => self::REASON_UPGRADING_TO_PAID_VERSION,
47
+ 'text' => __( 'Upgrading to paid version', $wd_options->prefix ),
48
  ),
49
  5 => array(
50
  'id' => self::REASON_TEMPORARY_DEACTIVATION,
wd/includes/overview.php CHANGED
@@ -66,6 +66,9 @@
66
  $start_using_url = menu_page_url($this->config->custom_post, false);
67
  }
68
  }
 
 
 
69
  require_once( $wd_options->wd_dir_templates . "/display_overview.php" );
70
  }
71
  public function wd_overview_welcome(){
66
  $start_using_url = menu_page_url($this->config->custom_post, false);
67
  }
68
  }
69
+ if(!empty($this->config->start_using_url)){
70
+ $start_using_url = $this->config->start_using_url;
71
+ }
72
  require_once( $wd_options->wd_dir_templates . "/display_overview.php" );
73
  }
74
  public function wd_overview_welcome(){
wd/templates/display_deactivation_popup.php CHANGED
@@ -5,7 +5,8 @@
5
  </div>
6
  <form method="post" id="<?php echo $wd_options->prefix; ?>_deactivate_form">
7
  <div class="wd-deactivate-popup-header">
8
- <?php _e( "Please let us know why you are deactivating. Your answer will help us to serve you better (Optional)", $wd_options->prefix ); ?>:
 
9
  </div>
10
 
11
  <div class="wd-deactivate-popup-body">
@@ -19,7 +20,7 @@
19
  </div>
20
  <div class="wd-btns">
21
  <a href="<?php echo $deactivate_url; ?>" data-val="1" class="button button-primary button-close wd-<?php echo $wd_options->prefix; ?>-deactivate" id="wd-<?php echo $wd_options->prefix; ?>-deactivate"><?php _e( "Skip and Deactivate" , $wd_options->prefix ); ?></a>
22
- <a href="<?php echo $deactivate_url; ?>" data-val="2" class="button button-primary button-close wd-<?php echo $wd_options->prefix; ?>-deactivate" id="wd-<?php echo $wd_options->prefix; ?>-submit-and-deactivate" style="display:none;"><?php _e( "Submit and Deactivate" , $wd_options->prefix ); ?></a>
23
  </div>
24
  <input type="hidden" name="<?php echo $wd_options->prefix . "_submit_and_deactivate"; ?>" value="" >
25
  <?php wp_nonce_field( $wd_options->prefix . '_save_form', $wd_options->prefix . '_save_form_fild'); ?>
5
  </div>
6
  <form method="post" id="<?php echo $wd_options->prefix; ?>_deactivate_form">
7
  <div class="wd-deactivate-popup-header">
8
+ <?php _e( "Please let us know why you are deactivating. Your answer will help us to provide you support or sometimes offer discounts. (Optional)", $wd_options->prefix ); ?>:
9
+ <span class="wd-deactivate-popup-close-btn"></span>
10
  </div>
11
 
12
  <div class="wd-deactivate-popup-body">
20
  </div>
21
  <div class="wd-btns">
22
  <a href="<?php echo $deactivate_url; ?>" data-val="1" class="button button-primary button-close wd-<?php echo $wd_options->prefix; ?>-deactivate" id="wd-<?php echo $wd_options->prefix; ?>-deactivate"><?php _e( "Skip and Deactivate" , $wd_options->prefix ); ?></a>
23
+ <a href="<?php echo $deactivate_url; ?>" data-val="2" class="button button-primary button-primary-disabled button-close wd-<?php echo $wd_options->prefix; ?>-deactivate" id="wd-<?php echo $wd_options->prefix; ?>-submit-and-deactivate" style="display:none;"><?php _e( "Submit and Deactivate" , $wd_options->prefix ); ?></a>
24
  </div>
25
  <input type="hidden" name="<?php echo $wd_options->prefix . "_submit_and_deactivate"; ?>" value="" >
26
  <?php wp_nonce_field( $wd_options->prefix . '_save_form', $wd_options->prefix . '_save_form_fild'); ?>
wd/templates/display_overview_support.php CHANGED
@@ -27,8 +27,24 @@
27
  echo '&#13;&#10;&#13;&#10;';
28
  foreach( $gd_info as $key => $val ){
29
  echo $key . ": " . $val . '&#13;&#10;';
30
- }
31
- ?></textarea>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
32
  </div>
33
  </div>
34
  <?php
27
  echo '&#13;&#10;&#13;&#10;';
28
  foreach( $gd_info as $key => $val ){
29
  echo $key . ": " . $val . '&#13;&#10;';
30
+ }
31
+ echo '&#13;&#10;';
32
+ _e("Active Plugins", $wd_options->prefix);
33
+ echo '&#13;&#10;';
34
+ $activepl = get_option('active_plugins');
35
+ $plugins = get_plugins();
36
+ $activated_plugins = array();
37
+ foreach ( $activepl as $p ) {
38
+ if ( isset($plugins[$p]) ) {
39
+ array_push($activated_plugins, $plugins[$p]);
40
+ echo '&#13;&#10;' . $plugins[$p]['Name'];
41
+ }
42
+ }
43
+ echo '&#13;&#10;&#13;&#10;';
44
+ _e("Active theme", $wd_options->prefix);
45
+ echo '&#13;&#10;&#13;&#10;';
46
+ echo wp_get_theme();
47
+ ?></textarea>
48
  </div>
49
  </div>
50
  <?php
wd/templates/display_subscribe.php CHANGED
@@ -8,7 +8,10 @@
8
  <div class="texts">
9
  <p><?php _e( "Hi there", $wd_options->prefix ); ?>,</p>
10
  <p>
11
- <?php echo sprintf( __( "Allow %s to collect some usage data. This will allow you to get more out of your plugin experience - get awesome customer support, receive exclusive deals and discounts on premium products and more. You can choose to skip this step, %s will still work just fine.", $wd_options->prefix ), '<strong>Web-Dorado</strong>', $wd_options->plugin_title ); ?>
 
 
 
12
  </p>
13
  </div>
14
  <div class="btns">
8
  <div class="texts">
9
  <p><?php _e( "Hi there", $wd_options->prefix ); ?>,</p>
10
  <p>
11
+ <?php
12
+ $pp_text = "<a target='_blank' href='https://web-dorado.com/web-dorado-privacy-statement.html'>" . __("Privacy Policy", $wd_options->prefix) . "</a>";
13
+ echo sprintf(__("Allow %s to collect some usage data, to be able to provide you more out of your plugin experience - awesome customer support and more. Check how we handle your personal data in our %s. You can always customize your preferences from the emails your receive from us. You can choose to skip this step, %s will still work just fine.", $wd_options->prefix), '<strong>Web-Dorado</strong>', $pp_text, $wd_options->plugin_title);
14
+ ?>
15
  </p>
16
  </div>
17
  <div class="btns">
wd/wd.php CHANGED
@@ -17,7 +17,7 @@
17
  public $overview_instance;
18
  public $subscribe_instance;
19
  public $config;
20
- private $version = "1.0.13";
21
 
22
  ////////////////////////////////////////////////////////////////////////////////////////
23
  // Constructor & Destructor //
17
  public $overview_instance;
18
  public $subscribe_instance;
19
  public $config;
20
+ private $version = "1.0.15";
21
 
22
  ////////////////////////////////////////////////////////////////////////////////////////
23
  // Constructor & Destructor //