WD Facebook Feed – Custom Facebook Feed Plugin - Version 1.0.10

Version Description

  • Added: Notice for appID and access token
  • Changed: Default tokens
Download this release

Release Info

Developer webdorado
Plugin Icon 128x128 WD Facebook Feed – Custom Facebook Feed Plugin
Version 1.0.10
Comparing to
See all releases

Code changes from version 1.0.9 to 1.0.10

Files changed (3) hide show
  1. facebook-feed-wd.php +24 -3
  2. framework/WDFacebookFeed.php +18 -5
  3. readme.txt +5 -1
facebook-feed-wd.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: Facebook Feed WD
5
  * Plugin URI: https://web-dorado.com/products/wordpress-facebook-feed-plugin.html
6
  * Description:Facebook Feed WD is a completely customizable, responsive solution to help you display your Facebook feed on your WordPress website.
7
- * Version: 1.0.9
8
  * Author: WebDorado
9
  * Author URI: https://web-dorado.com/
10
  * License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
@@ -81,6 +81,23 @@ function ffwd_menu()
81
  require_once(WD_FFWD_DIR . '/framework/WDW_FFWD_Library.php');
82
  $page = WDW_FFWD_Library::get('page');
83
  if (($page != '') && (($page == 'info_ffwd') || ($page == 'options_ffwd') || ($page == 'themes_ffwd') || ($page == 'uninstall_ffwd') || ($page == 'FFWDShortcode'))) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
84
  require_once(WD_FFWD_DIR . '/admin/controllers/FFWDController' . (($page == 'FFWDShortcode') ? $page : ucfirst(strtolower($page))) . '.php');
85
  $controller_class = 'FFWDController' . ucfirst(strtolower($page));
86
  $controller = new $controller_class();
@@ -658,7 +675,7 @@ add_action('init', 'ffwd_language_load');
658
  function ffwd_version()
659
  {
660
 
661
- $version = '1.0.9';
662
 
663
  if (get_option('ffwd_version') === false) {
664
  add_option('ffwd_version', $version);
@@ -691,4 +708,8 @@ if (is_admin() && (!defined('DOING_AJAX') || !DOING_AJAX)) {
691
  }
692
 
693
 
694
- ?>
 
 
 
 
4
  * Plugin Name: Facebook Feed WD
5
  * Plugin URI: https://web-dorado.com/products/wordpress-facebook-feed-plugin.html
6
  * Description:Facebook Feed WD is a completely customizable, responsive solution to help you display your Facebook feed on your WordPress website.
7
+ * Version: 1.0.10
8
  * Author: WebDorado
9
  * Author URI: https://web-dorado.com/
10
  * License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
81
  require_once(WD_FFWD_DIR . '/framework/WDW_FFWD_Library.php');
82
  $page = WDW_FFWD_Library::get('page');
83
  if (($page != '') && (($page == 'info_ffwd') || ($page == 'options_ffwd') || ($page == 'themes_ffwd') || ($page == 'uninstall_ffwd') || ($page == 'FFWDShortcode'))) {
84
+
85
+ $acc_tocken = $wpdb->get_var("SELECT access_token FROM " . $wpdb->prefix . "wd_fb_option WHERE id=1");
86
+ if($acc_tocken!='')
87
+ delete_option('ffwd_limit_notice');
88
+ $ffwd_limit_notice=get_option('ffwd_limit_notice');
89
+ if ($ffwd_limit_notice == 1) {
90
+ echo '<div style="width:99%">
91
+ <div class="error">
92
+ <p style="font-size:18px;"><strong>' . __("If you are getting errors please go to options and fill in App ID and App Secret.", "ffwd") . '</strong></p>
93
+ <p>' . __("For getting App ID and App Secret read more in", "ffwd") . '
94
+ <a href="https://web-dorado.com/wordpress-facebook-feed/options.html" target="_blank" style="color: #00A0D2;">' . __("User Manual", "ffwd") . '</a>.
95
+ </p>
96
+ </div>
97
+ </div>';
98
+ }
99
+
100
+
101
  require_once(WD_FFWD_DIR . '/admin/controllers/FFWDController' . (($page == 'FFWDShortcode') ? $page : ucfirst(strtolower($page))) . '.php');
102
  $controller_class = 'FFWDController' . ucfirst(strtolower($page));
103
  $controller = new $controller_class();
675
  function ffwd_version()
676
  {
677
 
678
+ $version = '1.0.10';
679
 
680
  if (get_option('ffwd_version') === false) {
681
  add_option('ffwd_version', $version);
708
  }
709
 
710
 
711
+
712
+
713
+
714
+
715
+ ?>
framework/WDFacebookFeed.php CHANGED
@@ -32,11 +32,13 @@ class WDFacebookFeed {
32
  // Existing app ids and app secrets
33
  protected static $access_tokens = array (
34
  // App 2.5 and higher doesn't support video name field
35
- '862375440517227|6UamCtWAt-Nn8JEL2vQSM0nKmII',
36
- '1509500312675877|d4f71636f520624105d7a8e82cc571df', // App version 2.4
37
- '948188131886213|d7e294429584e7fb5ec8a59a63cad8d8',
38
- '1697065397194692|65696e3e0679bf806c017cde2c5b4550',
39
- '1517697358543867|505629efa27c1a99a15f5978e019ef39', //11.03.2015
 
 
40
  );
41
 
42
  protected static $save = true;
@@ -577,6 +579,8 @@ $ffwd_info_options[$ffwd_option_db] =((isset($_POST[$ffwd_option_db])) ? esc_htm
577
  }
578
  // Check if exist error
579
  elseif(array_key_exists("error", $data)) {
 
 
580
  self::wd_fb_massage('error', $data['error']['message']);
581
  }
582
  }
@@ -600,6 +604,8 @@ $ffwd_info_options[$ffwd_option_db] =((isset($_POST[$ffwd_option_db])) ? esc_htm
600
  // Check if no errors with that id
601
  $data = self::decap_do_curl($fb_graph_url);
602
  if(array_key_exists("error", $data)) {
 
 
603
  self::wd_fb_massage('error', $data['error']['message']);
604
  }
605
  else {
@@ -613,6 +619,8 @@ $ffwd_info_options[$ffwd_option_db] =((isset($_POST[$ffwd_option_db])) ? esc_htm
613
  $data = self::decap_do_curl($fb_graph_url);
614
  // If error exist
615
  if(array_key_exists("error", $data)) {
 
 
616
  self::wd_fb_massage('error', $data['error']['message']);
617
  }
618
  // Set next page if it exists
@@ -756,6 +764,8 @@ $ffwd_info_options[$ffwd_option_db] =((isset($_POST[$ffwd_option_db])) ? esc_htm
756
 
757
 
758
  if(array_key_exists("error", $data)) {
 
 
759
  self::wd_fb_massage('error', $data['error']['message']);
760
  }
761
  else {
@@ -1249,6 +1259,9 @@ $ffwd_info_options[$ffwd_option_db] =((isset($_POST[$ffwd_option_db])) ? esc_htm
1249
  array('id' => 1)
1250
  );
1251
 
 
 
 
1252
  self::wd_fb_massage('error', $data['error']['message'].'asdasd');
1253
  }
1254
  else {
32
  // Existing app ids and app secrets
33
  protected static $access_tokens = array (
34
  // App 2.5 and higher doesn't support video name field
35
+ '1332501960106748|5c00e11412c36ce741e5bb051d3d948e',
36
+ '1303503889682231|6a947d424fc7e2fd373568ed92c3c9de', // App version 2.4
37
+ '1005694739559398|b32df5b3f7cecd1105e028abe1bc7ef6',
38
+ '274394046295054|2fbdbe248092c63f812e0e1d6dbe0f2b',
39
+ '1739880636336728|e786c42c6cbe13b28b8f4a83afbebbcd',
40
+ '1683088998649596|73282ca4410752d64621e693cc19524e',
41
+ '987113411398480|3e2d346234b086dba07e5c6f5c87caaa',
42
  );
43
 
44
  protected static $save = true;
579
  }
580
  // Check if exist error
581
  elseif(array_key_exists("error", $data)) {
582
+ if( $data['error']['code']==4)
583
+ update_option('ffwd_limit_notice',1);
584
  self::wd_fb_massage('error', $data['error']['message']);
585
  }
586
  }
604
  // Check if no errors with that id
605
  $data = self::decap_do_curl($fb_graph_url);
606
  if(array_key_exists("error", $data)) {
607
+ if( $data['error']['code']==4)
608
+ update_option('ffwd_limit_notice',1);
609
  self::wd_fb_massage('error', $data['error']['message']);
610
  }
611
  else {
619
  $data = self::decap_do_curl($fb_graph_url);
620
  // If error exist
621
  if(array_key_exists("error", $data)) {
622
+ if( $data['error']['code']==4)
623
+ update_option('ffwd_limit_notice',1);
624
  self::wd_fb_massage('error', $data['error']['message']);
625
  }
626
  // Set next page if it exists
764
 
765
 
766
  if(array_key_exists("error", $data)) {
767
+ if( $data['error']['code']==4)
768
+ update_option('ffwd_limit_notice',1);
769
  self::wd_fb_massage('error', $data['error']['message']);
770
  }
771
  else {
1259
  array('id' => 1)
1260
  );
1261
 
1262
+ if( $data['error']['code']==4)
1263
+ update_option('ffwd_limit_notice',1);
1264
+
1265
  self::wd_fb_massage('error', $data['error']['message'].'asdasd');
1266
  }
1267
  else {
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://web-dorado.com/products/wordpress-facebook-feed-plugin.html
4
  Tags: customizable, facebook, facebook events, facebook feed, facebook group, facebook like box, facebook likes, facebook page, facebook photos, facebook plugin, facebook posts, likebox
5
  Requires at least: 3.4
6
  Tested up to: 4.6
7
- Stable tag: 1.0.9
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -66,6 +66,10 @@ Upgrade to [Facebook Feed Pro](https://web-dorado.com/products/wordpress-faceboo
66
 
67
  == Changelog ==
68
 
 
 
 
 
69
  = 1.0.9 =
70
  * Fixed: Maximum Post message(description) Length option bug
71
  * Fixed: Minor bug
4
  Tags: customizable, facebook, facebook events, facebook feed, facebook group, facebook like box, facebook likes, facebook page, facebook photos, facebook plugin, facebook posts, likebox
5
  Requires at least: 3.4
6
  Tested up to: 4.6
7
+ Stable tag: 1.0.10
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
66
 
67
  == Changelog ==
68
 
69
+ = 1.0.10 =
70
+ * Added: Notice for appID and access token
71
+ * Changed: Default tokens
72
+
73
  = 1.0.9 =
74
  * Fixed: Maximum Post message(description) Length option bug
75
  * Fixed: Minor bug