Blog2Social: Social Media Auto Post & Scheduler - Version 6.9.6

Version Description

Additional Security Update

Download this release

Release Info

Developer PR-Gateway
Plugin Icon 128x128 Blog2Social: Social Media Auto Post & Scheduler
Version 6.9.6
Comparing to
See all releases

Code changes from version 6.9.5 to 6.9.6

blog2social.php CHANGED
@@ -6,12 +6,12 @@
6
  * Author: Blog2Social, Adenion
7
  * Text Domain: blog2social
8
  * Domain Path: /languages
9
- * Version: 6.9.5
10
  * Author URI: https://www.blog2social.com
11
  * License: GPL2+
12
  */
13
 
14
- define('B2S_PLUGIN_VERSION', '695');
15
  define('B2S_PLUGIN_LANGUAGE', serialize(array('de_DE', 'en_US')));
16
  define('B2S_PLUGIN_DIR', plugin_dir_path(__FILE__));
17
  define('B2S_PLUGIN_URL', plugin_dir_url(__FILE__));
6
  * Author: Blog2Social, Adenion
7
  * Text Domain: blog2social
8
  * Domain Path: /languages
9
+ * Version: 6.9.6
10
  * Author URI: https://www.blog2social.com
11
  * License: GPL2+
12
  */
13
 
14
+ define('B2S_PLUGIN_VERSION', '696');
15
  define('B2S_PLUGIN_LANGUAGE', serialize(array('de_DE', 'en_US')));
16
  define('B2S_PLUGIN_DIR', plugin_dir_path(__FILE__));
17
  define('B2S_PLUGIN_URL', plugin_dir_url(__FILE__));
includes/Ajax/Get.php CHANGED
@@ -62,11 +62,11 @@ class Ajax_Get {
62
  public function scrapeUrl() {
63
  if (isset($_POST['b2s_security_nonce']) && (int) wp_verify_nonce(sanitize_text_field(wp_unslash($_POST['b2s_security_nonce'])), 'b2s_security_nonce') > 0) {
64
  if (isset($_POST['url']) && !empty($_POST['url'])) {
65
- $data = B2S_Util::scrapeUrl(esc_url(wp_unslash($_POST['url'])));
66
  $scrapeError = ($data !== false) ? false : true;
67
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Curation/View.php');
68
  $curation = new B2S_Curation_View();
69
- $preview = $curation->getCurationPreviewHtml(esc_url(wp_unslash($_POST['url'])), $data);
70
  if (!empty($preview)) {
71
  if (isset($_POST['loadSettings']) && filter_var(wp_unslash($_POST['loadSettings']), FILTER_VALIDATE_BOOLEAN)) {
72
  $result = json_decode(B2S_Api_Post::post(B2S_PLUGIN_API_ENDPOINT, array('action' => 'getProfileUserAuth', 'token' => B2S_PLUGIN_TOKEN)));
@@ -470,10 +470,10 @@ class Ajax_Get {
470
  $postUrl = (get_permalink($postData->ID) !== false ? get_permalink($postData->ID) : $postData->guid);
471
  $metaInfo = array('title' => B2S_Util::getExcerpt(B2S_Util::remove4byte($postData->post_title), 50) . ' - ' . get_option('blogname'), 'description' => B2S_Util::getExcerpt(B2S_Util::prepareContent($postData->ID, $postData->post_content, $postUrl, false, false), 150));
472
  } else {
473
- $metaInfo = B2S_Util::getMetaTags((int) sanitize_text_field(wp_unslash($_POST['postId'])), esc_url(wp_unslash($_POST['url'])), (int) sanitize_text_field(wp_unslash($_POST['networkId'])));
474
  }
475
  } else {
476
- $metaInfo = B2S_Util::getMetaTags(0, esc_url(wp_unslash($_POST['url'])), (int) sanitize_text_field(wp_unslash($_POST['networkId'])));
477
  }
478
  echo json_encode(array('result' => true, 'networkId' => (int) $_POST['networkId'], 'networkAuthId' => (int) $_POST['networkAuthId'], 'title' => isset($metaInfo['title']) ? (function_exists('htmlspecialchars_decode') ? htmlspecialchars_decode($metaInfo['title']) : $metaInfo['title']) : '', 'description' => isset($metaInfo['description']) ? (function_exists('htmlspecialchars_decode') ? htmlspecialchars_decode($metaInfo['description']): $metaInfo['description']) : '', 'image' => isset($metaInfo['image']) ? $metaInfo['image'] : ''));
479
  wp_die();
62
  public function scrapeUrl() {
63
  if (isset($_POST['b2s_security_nonce']) && (int) wp_verify_nonce(sanitize_text_field(wp_unslash($_POST['b2s_security_nonce'])), 'b2s_security_nonce') > 0) {
64
  if (isset($_POST['url']) && !empty($_POST['url'])) {
65
+ $data = B2S_Util::scrapeUrl(esc_url_raw(wp_unslash($_POST['url'])));
66
  $scrapeError = ($data !== false) ? false : true;
67
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Curation/View.php');
68
  $curation = new B2S_Curation_View();
69
+ $preview = $curation->getCurationPreviewHtml(esc_url_raw(wp_unslash($_POST['url'])), $data);
70
  if (!empty($preview)) {
71
  if (isset($_POST['loadSettings']) && filter_var(wp_unslash($_POST['loadSettings']), FILTER_VALIDATE_BOOLEAN)) {
72
  $result = json_decode(B2S_Api_Post::post(B2S_PLUGIN_API_ENDPOINT, array('action' => 'getProfileUserAuth', 'token' => B2S_PLUGIN_TOKEN)));
470
  $postUrl = (get_permalink($postData->ID) !== false ? get_permalink($postData->ID) : $postData->guid);
471
  $metaInfo = array('title' => B2S_Util::getExcerpt(B2S_Util::remove4byte($postData->post_title), 50) . ' - ' . get_option('blogname'), 'description' => B2S_Util::getExcerpt(B2S_Util::prepareContent($postData->ID, $postData->post_content, $postUrl, false, false), 150));
472
  } else {
473
+ $metaInfo = B2S_Util::getMetaTags((int) sanitize_text_field(wp_unslash($_POST['postId'])), esc_url_raw(wp_unslash($_POST['url'])), (int) sanitize_text_field(wp_unslash($_POST['networkId'])));
474
  }
475
  } else {
476
+ $metaInfo = B2S_Util::getMetaTags(0, esc_url_raw(wp_unslash($_POST['url'])), (int) sanitize_text_field(wp_unslash($_POST['networkId'])));
477
  }
478
  echo json_encode(array('result' => true, 'networkId' => (int) $_POST['networkId'], 'networkAuthId' => (int) $_POST['networkAuthId'], 'title' => isset($metaInfo['title']) ? (function_exists('htmlspecialchars_decode') ? htmlspecialchars_decode($metaInfo['title']) : $metaInfo['title']) : '', 'description' => isset($metaInfo['description']) ? (function_exists('htmlspecialchars_decode') ? htmlspecialchars_decode($metaInfo['description']): $metaInfo['description']) : '', 'image' => isset($metaInfo['image']) ? $metaInfo['image'] : ''));
479
  wp_die();
includes/Ajax/Post.php CHANGED
@@ -83,7 +83,7 @@ class Ajax_Post {
83
  }
84
  } else if ((int) $_POST['postFormat'] == 0) { //Linkpost
85
  if (isset($_POST['title']) && !empty($_POST['title']) && isset($_POST['comment']) && !empty($_POST['comment']) && isset($_POST['url']) && !empty($_POST['url'])) {
86
- $data = array('title' => sanitize_text_field($_POST['title']), 'url' => esc_url($_POST['url']), 'content' => (isset($_POST['comment']) ? sanitize_textarea_field($_POST['comment']) : ''), 'author_id' => B2S_PLUGIN_BLOG_USER_ID);
87
  } else {
88
  echo json_encode(array('result' => false, 'error' => 'NO_DATA'));
89
  wp_die();
@@ -160,7 +160,7 @@ class Ajax_Post {
160
  }
161
  } else if ((int) $_POST['postFormat'] == 0) { //Linkpost
162
  if (isset($_POST['title']) && !empty($_POST['title']) && isset($_POST['comment']) && !empty($_POST['comment']) && isset($_POST['url']) && !empty($_POST['url'])) {
163
- $data = array('title' => sanitize_text_field($_POST['title']), 'url' => esc_url($_POST['url']), 'content' => (isset($_POST['comment']) ? sanitize_textarea_field($_POST['comment']) : ''), 'author_id' => B2S_PLUGIN_BLOG_USER_ID);
164
  } else {
165
  echo json_encode(array('result' => false, 'error' => 'NO_DATA'));
166
  wp_die();
@@ -193,14 +193,14 @@ class Ajax_Post {
193
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/QuickPost.php');
194
  $quickPost = new B2S_QuickPost($data['content'], $data['title']);
195
  $defaultShareData = array('default_titel' => sanitize_text_field($data['title']),
196
- 'image_url' => (!empty($_POST['image_url'])) ? esc_url(trim(urldecode($_POST['image_url']))) : ((!empty($_POST['link_image_url']) ? esc_url(trim(urldecode($_POST['link_image_url']))) : '')),
197
  'lang' => trim(strtolower(substr(B2S_LANGUAGE, 0, 2))),
198
  'board' => '',
199
  'group' => '',
200
  'post_id' => $postId,
201
  'blog_user_id' => B2S_PLUGIN_BLOG_USER_ID,
202
  'tags' => array(),
203
- 'url' => ((isset($_POST['url']) && !empty($_POST['url'])) ? esc_url($_POST['url']) : ''),
204
  'no_cache' => 0,
205
  'token' => B2S_PLUGIN_TOKEN,
206
  'user_timezone' => (isset($_POST['b2s_user_timezone']) ? (int) $_POST['b2s_user_timezone'] : 0 ),
@@ -337,15 +337,15 @@ class Ajax_Post {
337
  if ((int) $_POST['postFormat'] == 1) { //Imagepost
338
  if (isset($_POST['image_id']) && !empty($_POST['image_id']) && isset($_POST['comment_image']) && !empty($_POST['comment_image'])) {
339
  $data = array('title' => sanitize_text_field($_POST['comment_image']), 'content' => sanitize_text_field(wp_unslash($_POST['comment_image'])), 'image_id' => (int) $_POST['image_id'], 'author_id' => B2S_PLUGIN_BLOG_USER_ID);
340
- $imgUrl = (isset($_POST['image_url']) && !empty($_POST['image_url'])) ? esc_url(wp_unslash($_POST['image_url'])) : '';
341
  } else {
342
  echo json_encode(array('result' => false, 'error' => 'NO_DATA'));
343
  wp_die();
344
  }
345
  } else if ((int) $_POST['postFormat'] == 0) { //Linkpost
346
  if (isset($_POST['title']) && !empty($_POST['title']) && isset($_POST['comment']) && !empty($_POST['comment']) && isset($_POST['url']) && !empty($_POST['url'])) {
347
- $data = array('title' => sanitize_text_field($_POST['title']), 'url' => esc_url($_POST['url']), 'content' => (isset($_POST['comment']) ? sanitize_textarea_field($_POST['comment']) : ''), 'author_id' => B2S_PLUGIN_BLOG_USER_ID);
348
- $imgUrl = (isset($_POST['link_image_url']) && !empty($_POST['link_image_url'])) ? esc_url(wp_unslash($_POST['link_image_url'])) : '';
349
  } else {
350
  echo json_encode(array('result' => false, 'error' => 'NO_DATA'));
351
  wp_die();
@@ -447,7 +447,7 @@ class Ajax_Post {
447
  'email_presse' => sanitize_text_field($_POST['email_presse']),
448
  'telefon_presse' => sanitize_text_field($_POST['telefon_presse']),
449
  'fax_presse' => isset($_POST['fax_presse']) ? sanitize_text_field($_POST['fax_presse']) : '',
450
- 'url_presse' => esc_url($_POST['url_presse'])
451
  );
452
 
453
  if (!$userEntry) {
@@ -583,7 +583,7 @@ class Ajax_Post {
583
  $meta->setMeta('og_desc', sanitize_text_field($data['og_desc']));
584
  }
585
  if (isset($data['image_url']) && !empty($data['image_url'])) {
586
- $meta->setMeta('og_image', trim(esc_url($data['image_url'])));
587
  $meta->setMeta('og_image_alt', '');
588
  }
589
  $meta->updateMeta((int) $post['post_id']);
@@ -614,7 +614,7 @@ class Ajax_Post {
614
  $meta->setMeta('card_desc', sanitize_text_field($data['card_desc']));
615
  }
616
  if (isset($data['image_url']) && !empty($data['image_url'])) {
617
- $meta->setMeta('card_image', trim(esc_url($data['image_url'])));
618
  }
619
  $meta->updateMeta((int) $post['post_id']);
620
  }
@@ -629,8 +629,8 @@ class Ajax_Post {
629
  "group" => isset($data['group']) ? sanitize_text_field($data['group']) : '',
630
  "custom_title" => isset($data['custom_title']) ? sanitize_text_field($data['custom_title']) : '',
631
  "content" => (isset($data['content']) && !empty($data['content'])) ? strip_tags(preg_replace("/(<[\/]*)em(>)/", "$1i$2", html_entity_decode(sanitize_textarea_field($data['content']))), '<p><h1><h2><br><i><b><a><img>') : '',
632
- 'url' => isset($data['url']) ? htmlspecialchars_decode(esc_url($data['url'])) : '',
633
- 'image_url' => isset($data['image_url']) ? trim(esc_url($data['image_url'])) : '',
634
  'tags' => isset($data['tags']) ? $data['tags'] : array(),
635
  'network_id' => isset($data['network_id']) ? (int) $data['network_id'] : 0,
636
  'instant_sharing' => isset($data['instant_sharing']) ? (int) $data['instant_sharing'] : 0,
@@ -771,7 +771,7 @@ class Ajax_Post {
771
  $options->_setOption('og_active', $og_active);
772
  $options->_setOption('og_default_title', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_og_default_title']) : ''));
773
  $options->_setOption('og_default_desc', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_og_default_desc']) : ''));
774
- $options->_setOption('og_default_image', ((B2S_PLUGIN_USER_VERSION >= 1) ? esc_url($_POST['b2s_og_default_image']) : ''));
775
  $options->_setOption('og_imagedata_active', ((B2S_PLUGIN_USER_VERSION >= 1) ? (int) $_POST['b2s_og_imagedata_active'] : 1));
776
  $options->_setOption('og_objecttype_active', ((B2S_PLUGIN_USER_VERSION >= 1) ? (int) $_POST['b2s_og_objecttype_active'] : 1));
777
  $options->_setOption('og_locale_active', ((B2S_PLUGIN_USER_VERSION >= 1) ? (int) $_POST['b2s_og_locale_active'] : 1));
@@ -782,7 +782,7 @@ class Ajax_Post {
782
  $options->_setOption('card_default_type', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_card_default_type']) : 0));
783
  $options->_setOption('card_default_title', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_card_default_title']) : ''));
784
  $options->_setOption('card_default_desc', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_card_default_desc']) : ''));
785
- $options->_setOption('card_default_image', ((B2S_PLUGIN_USER_VERSION >= 1) ? esc_url($_POST['b2s_card_default_image']) : ''));
786
 
787
  $oembed_active = (!isset($_POST['b2s_oembed_active'])) ? 0 : 1;
788
  $options->_setOption('oembed_active', $oembed_active);
@@ -1317,7 +1317,7 @@ class Ajax_Post {
1317
  'vorname' => sanitize_text_field($_POST['vorname']),
1318
  'nachname' => sanitize_text_field($_POST['nachname']),
1319
  'email' => sanitize_text_field($_POST['email']),
1320
- 'url' => esc_url($_POST['url']),
1321
  'lang' => trim(strtolower(substr(B2S_LANGUAGE, 0, 2))));
1322
  $trailResult = json_decode(B2S_Api_Post::post(B2S_PLUGIN_API_ENDPOINT, $data));
1323
  if ($trailResult->result == true) {
@@ -1514,7 +1514,7 @@ class Ajax_Post {
1514
  . "SET sched_date = '0000-00-00 00:00:00', "
1515
  . "sched_date_utc = '0000-00-00 00:00:00', "
1516
  . "publish_date = '" . B2S_Util::getbyIdentLocalDate($userTimeZoneOffset) . "', "
1517
- . "publish_link = '" . ((isset($_POST['publish_link']) && !empty($_POST['publish_link'])) ? esc_url($_POST['publish_link']) : '') . "', "
1518
  . "publish_error_code = '" . ((isset($_POST['publish_error_code']) && !empty($_POST['publish_error_code'])) ? addslashes(sanitize_text_field($_POST['publish_error_code'])) : '') . "', "
1519
  . "post_for_approve = 0 "
1520
  . "WHERE id = " . (int) $_POST['post_id'];
@@ -1687,7 +1687,7 @@ class Ajax_Post {
1687
  $meta->setMeta('og_desc', sanitize_text_field($data['og_desc']));
1688
  }
1689
  if (isset($data['image_url']) && !empty($data['image_url'])) {
1690
- $meta->setMeta('og_image', trim(esc_url($data['image_url'])));
1691
  $meta->setMeta('og_image_alt', '');
1692
  }
1693
  $meta->updateMeta((int) $post['post_id']);
@@ -1718,7 +1718,7 @@ class Ajax_Post {
1718
  $meta->setMeta('card_desc', sanitize_text_field($data['card_desc']));
1719
  }
1720
  if (isset($data['image_url']) && !empty($data['image_url'])) {
1721
- $meta->setMeta('card_image', trim(esc_url($data['image_url'])));
1722
  }
1723
  $meta->updateMeta((int) $post['post_id']);
1724
  }
@@ -1727,8 +1727,8 @@ class Ajax_Post {
1727
  "group" => isset($data['group']) ? sanitize_text_field($data['group']) : '',
1728
  "custom_title" => isset($data['custom_title']) ? sanitize_text_field($data['custom_title']) : '',
1729
  "content" => (isset($data['content']) && !empty($data['content'])) ? strip_tags(preg_replace("/(<[\/]*)em(>)/", "$1i$2", html_entity_decode($data['content'])), '<p><h1><h2><br><i><b><a><img>') : '',
1730
- 'url' => isset($data['url']) ? htmlspecialchars_decode(esc_url($data['url'])) : '',
1731
- 'image_url' => isset($data['image_url']) ? trim(esc_url($data['image_url'])) : '',
1732
  'tags' => isset($data['tags']) ? $data['tags'] : array(),
1733
  'network_id' => isset($data['network_id']) ? (int) $data['network_id'] : '',
1734
  'network_type' => isset($data['network_type']) ? (int) $data['network_type'] : '',
83
  }
84
  } else if ((int) $_POST['postFormat'] == 0) { //Linkpost
85
  if (isset($_POST['title']) && !empty($_POST['title']) && isset($_POST['comment']) && !empty($_POST['comment']) && isset($_POST['url']) && !empty($_POST['url'])) {
86
+ $data = array('title' => sanitize_text_field($_POST['title']), 'url' => esc_url_raw($_POST['url']), 'content' => (isset($_POST['comment']) ? sanitize_textarea_field($_POST['comment']) : ''), 'author_id' => B2S_PLUGIN_BLOG_USER_ID);
87
  } else {
88
  echo json_encode(array('result' => false, 'error' => 'NO_DATA'));
89
  wp_die();
160
  }
161
  } else if ((int) $_POST['postFormat'] == 0) { //Linkpost
162
  if (isset($_POST['title']) && !empty($_POST['title']) && isset($_POST['comment']) && !empty($_POST['comment']) && isset($_POST['url']) && !empty($_POST['url'])) {
163
+ $data = array('title' => sanitize_text_field($_POST['title']), 'url' => esc_url_raw($_POST['url']), 'content' => (isset($_POST['comment']) ? sanitize_textarea_field($_POST['comment']) : ''), 'author_id' => B2S_PLUGIN_BLOG_USER_ID);
164
  } else {
165
  echo json_encode(array('result' => false, 'error' => 'NO_DATA'));
166
  wp_die();
193
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/QuickPost.php');
194
  $quickPost = new B2S_QuickPost($data['content'], $data['title']);
195
  $defaultShareData = array('default_titel' => sanitize_text_field($data['title']),
196
+ 'image_url' => (!empty($_POST['image_url'])) ? esc_url_raw(trim(urldecode($_POST['image_url']))) : ((!empty($_POST['link_image_url']) ? esc_url_raw(trim(urldecode($_POST['link_image_url']))) : '')),
197
  'lang' => trim(strtolower(substr(B2S_LANGUAGE, 0, 2))),
198
  'board' => '',
199
  'group' => '',
200
  'post_id' => $postId,
201
  'blog_user_id' => B2S_PLUGIN_BLOG_USER_ID,
202
  'tags' => array(),
203
+ 'url' => ((isset($_POST['url']) && !empty($_POST['url'])) ? esc_url_raw($_POST['url']) : ''),
204
  'no_cache' => 0,
205
  'token' => B2S_PLUGIN_TOKEN,
206
  'user_timezone' => (isset($_POST['b2s_user_timezone']) ? (int) $_POST['b2s_user_timezone'] : 0 ),
337
  if ((int) $_POST['postFormat'] == 1) { //Imagepost
338
  if (isset($_POST['image_id']) && !empty($_POST['image_id']) && isset($_POST['comment_image']) && !empty($_POST['comment_image'])) {
339
  $data = array('title' => sanitize_text_field($_POST['comment_image']), 'content' => sanitize_text_field(wp_unslash($_POST['comment_image'])), 'image_id' => (int) $_POST['image_id'], 'author_id' => B2S_PLUGIN_BLOG_USER_ID);
340
+ $imgUrl = (isset($_POST['image_url']) && !empty($_POST['image_url'])) ? esc_url_raw(wp_unslash($_POST['image_url'])) : '';
341
  } else {
342
  echo json_encode(array('result' => false, 'error' => 'NO_DATA'));
343
  wp_die();
344
  }
345
  } else if ((int) $_POST['postFormat'] == 0) { //Linkpost
346
  if (isset($_POST['title']) && !empty($_POST['title']) && isset($_POST['comment']) && !empty($_POST['comment']) && isset($_POST['url']) && !empty($_POST['url'])) {
347
+ $data = array('title' => sanitize_text_field($_POST['title']), 'url' => esc_url_raw($_POST['url']), 'content' => (isset($_POST['comment']) ? sanitize_textarea_field($_POST['comment']) : ''), 'author_id' => B2S_PLUGIN_BLOG_USER_ID);
348
+ $imgUrl = (isset($_POST['link_image_url']) && !empty($_POST['link_image_url'])) ? esc_url_raw(wp_unslash($_POST['link_image_url'])) : '';
349
  } else {
350
  echo json_encode(array('result' => false, 'error' => 'NO_DATA'));
351
  wp_die();
447
  'email_presse' => sanitize_text_field($_POST['email_presse']),
448
  'telefon_presse' => sanitize_text_field($_POST['telefon_presse']),
449
  'fax_presse' => isset($_POST['fax_presse']) ? sanitize_text_field($_POST['fax_presse']) : '',
450
+ 'url_presse' => esc_url_raw($_POST['url_presse'])
451
  );
452
 
453
  if (!$userEntry) {
583
  $meta->setMeta('og_desc', sanitize_text_field($data['og_desc']));
584
  }
585
  if (isset($data['image_url']) && !empty($data['image_url'])) {
586
+ $meta->setMeta('og_image', trim(esc_url_raw($data['image_url'])));
587
  $meta->setMeta('og_image_alt', '');
588
  }
589
  $meta->updateMeta((int) $post['post_id']);
614
  $meta->setMeta('card_desc', sanitize_text_field($data['card_desc']));
615
  }
616
  if (isset($data['image_url']) && !empty($data['image_url'])) {
617
+ $meta->setMeta('card_image', trim(esc_url_raw($data['image_url'])));
618
  }
619
  $meta->updateMeta((int) $post['post_id']);
620
  }
629
  "group" => isset($data['group']) ? sanitize_text_field($data['group']) : '',
630
  "custom_title" => isset($data['custom_title']) ? sanitize_text_field($data['custom_title']) : '',
631
  "content" => (isset($data['content']) && !empty($data['content'])) ? strip_tags(preg_replace("/(<[\/]*)em(>)/", "$1i$2", html_entity_decode(sanitize_textarea_field($data['content']))), '<p><h1><h2><br><i><b><a><img>') : '',
632
+ 'url' => isset($data['url']) ? htmlspecialchars_decode(esc_url_raw($data['url'])) : '',
633
+ 'image_url' => isset($data['image_url']) ? trim(esc_url_raw($data['image_url'])) : '',
634
  'tags' => isset($data['tags']) ? $data['tags'] : array(),
635
  'network_id' => isset($data['network_id']) ? (int) $data['network_id'] : 0,
636
  'instant_sharing' => isset($data['instant_sharing']) ? (int) $data['instant_sharing'] : 0,
771
  $options->_setOption('og_active', $og_active);
772
  $options->_setOption('og_default_title', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_og_default_title']) : ''));
773
  $options->_setOption('og_default_desc', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_og_default_desc']) : ''));
774
+ $options->_setOption('og_default_image', ((B2S_PLUGIN_USER_VERSION >= 1) ? esc_url_raw($_POST['b2s_og_default_image']) : ''));
775
  $options->_setOption('og_imagedata_active', ((B2S_PLUGIN_USER_VERSION >= 1) ? (int) $_POST['b2s_og_imagedata_active'] : 1));
776
  $options->_setOption('og_objecttype_active', ((B2S_PLUGIN_USER_VERSION >= 1) ? (int) $_POST['b2s_og_objecttype_active'] : 1));
777
  $options->_setOption('og_locale_active', ((B2S_PLUGIN_USER_VERSION >= 1) ? (int) $_POST['b2s_og_locale_active'] : 1));
782
  $options->_setOption('card_default_type', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_card_default_type']) : 0));
783
  $options->_setOption('card_default_title', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_card_default_title']) : ''));
784
  $options->_setOption('card_default_desc', ((B2S_PLUGIN_USER_VERSION >= 1) ? sanitize_text_field($_POST['b2s_card_default_desc']) : ''));
785
+ $options->_setOption('card_default_image', ((B2S_PLUGIN_USER_VERSION >= 1) ? esc_url_raw($_POST['b2s_card_default_image']) : ''));
786
 
787
  $oembed_active = (!isset($_POST['b2s_oembed_active'])) ? 0 : 1;
788
  $options->_setOption('oembed_active', $oembed_active);
1317
  'vorname' => sanitize_text_field($_POST['vorname']),
1318
  'nachname' => sanitize_text_field($_POST['nachname']),
1319
  'email' => sanitize_text_field($_POST['email']),
1320
+ 'url' => esc_url_raw($_POST['url']),
1321
  'lang' => trim(strtolower(substr(B2S_LANGUAGE, 0, 2))));
1322
  $trailResult = json_decode(B2S_Api_Post::post(B2S_PLUGIN_API_ENDPOINT, $data));
1323
  if ($trailResult->result == true) {
1514
  . "SET sched_date = '0000-00-00 00:00:00', "
1515
  . "sched_date_utc = '0000-00-00 00:00:00', "
1516
  . "publish_date = '" . B2S_Util::getbyIdentLocalDate($userTimeZoneOffset) . "', "
1517
+ . "publish_link = '" . ((isset($_POST['publish_link']) && !empty($_POST['publish_link'])) ? esc_url_raw($_POST['publish_link']) : '') . "', "
1518
  . "publish_error_code = '" . ((isset($_POST['publish_error_code']) && !empty($_POST['publish_error_code'])) ? addslashes(sanitize_text_field($_POST['publish_error_code'])) : '') . "', "
1519
  . "post_for_approve = 0 "
1520
  . "WHERE id = " . (int) $_POST['post_id'];
1687
  $meta->setMeta('og_desc', sanitize_text_field($data['og_desc']));
1688
  }
1689
  if (isset($data['image_url']) && !empty($data['image_url'])) {
1690
+ $meta->setMeta('og_image', trim(esc_url_raw($data['image_url'])));
1691
  $meta->setMeta('og_image_alt', '');
1692
  }
1693
  $meta->updateMeta((int) $post['post_id']);
1718
  $meta->setMeta('card_desc', sanitize_text_field($data['card_desc']));
1719
  }
1720
  if (isset($data['image_url']) && !empty($data['image_url'])) {
1721
+ $meta->setMeta('card_image', trim(esc_url_raw($data['image_url'])));
1722
  }
1723
  $meta->updateMeta((int) $post['post_id']);
1724
  }
1727
  "group" => isset($data['group']) ? sanitize_text_field($data['group']) : '',
1728
  "custom_title" => isset($data['custom_title']) ? sanitize_text_field($data['custom_title']) : '',
1729
  "content" => (isset($data['content']) && !empty($data['content'])) ? strip_tags(preg_replace("/(<[\/]*)em(>)/", "$1i$2", html_entity_decode($data['content'])), '<p><h1><h2><br><i><b><a><img>') : '',
1730
+ 'url' => isset($data['url']) ? htmlspecialchars_decode(esc_url_raw($data['url'])) : '',
1731
+ 'image_url' => isset($data['image_url']) ? trim(esc_url_raw($data['image_url'])) : '',
1732
  'tags' => isset($data['tags']) ? $data['tags'] : array(),
1733
  'network_id' => isset($data['network_id']) ? (int) $data['network_id'] : '',
1734
  'network_type' => isset($data['network_type']) ? (int) $data['network_type'] : '',
includes/B2S/PostBox.php CHANGED
@@ -139,7 +139,7 @@ class B2S_PostBox {
139
  }
140
  }
141
 
142
- $content = '<div class="b2s-post-meta-box">
143
  <div id="b2s-server-connection-fail" class="b2s-info-error"><button class="b2s-btn-close-meta-box b2s-close-icon" data-area-id="b2s-server-connection-fail" title="close notice"></button>' . esc_html__('The connection to the server failed. Please try again! You can find more information and solutions in the', 'blog2social') . '<a target="_blank" href="' . esc_url(B2S_Tools::getSupportLink('connection_guide')) . '"> ' . esc_html__('guide for server connection', 'blog2social') . '</a>.</div>
144
  <div id="b2s-heartbeat-fail" class="b2s-info-error"><button class="b2s-btn-close-meta-box b2s-close-icon" data-area-id="b2s-heartbeat-fail" title="close notice"></button>' . esc_html__('WordPress uses heartbeats by default, Blog2Social as well. Please enable heartbeats for using Blog2Social!', 'blog2social') . $b2sHeartbeatFaqLink . ' </div>
145
  <div id="b2s-post-meta-box-state-no-publish-future-customize" class="b2s-info-error"><button class="b2s-btn-close-meta-box b2s-close-icon" data-area-id="b2s-post-meta-box-state-no-publish-future-customize" title="close notice"></button>' . esc_html__('Your post is still on draft or pending status. Please make sure that your post is published or scheduled to be published on this blog. You can then auto-post or schedule and customize your social media posts with Blog2Social.', 'blog2social') . '</div>
@@ -176,7 +176,7 @@ class B2S_PostBox {
176
  <div class="b2s-options" style="display:none;">
177
  <br>
178
  <input type="checkbox" class="b2s-enable-auto-post" id="b2s-enable-auto-post" name="b2s-enable-auto-post" value="1" ' . (($autoPostActive) ? 'checked' : '') . '><label for="b2s-enable-auto-post">' . esc_html__('enable Auto-Posting', 'blog2social') . '</label>
179
- ' . ((isset($advancedOptions)) ? esc_attr($advancedOptions) : '') . '
180
  <a href="#b2s-post-box-calendar-header" id="b2s-post-box-calendar-btn">' . esc_html__('show calendar', 'blog2social') . '</a>
181
  <input type="hidden" name="b2s-profile-selected" value="' . ((isset($selectedProfileId)) ? esc_attr($selectedProfileId) : '-1') . '">
182
  <input type="hidden" name="b2s-profile-default" value="' . ((isset($defaultProfile)) ? esc_attr($defaultProfile) : '-1') . '">
139
  }
140
  }
141
 
142
+ $content = '<div class="b2s-post-meta-box">
143
  <div id="b2s-server-connection-fail" class="b2s-info-error"><button class="b2s-btn-close-meta-box b2s-close-icon" data-area-id="b2s-server-connection-fail" title="close notice"></button>' . esc_html__('The connection to the server failed. Please try again! You can find more information and solutions in the', 'blog2social') . '<a target="_blank" href="' . esc_url(B2S_Tools::getSupportLink('connection_guide')) . '"> ' . esc_html__('guide for server connection', 'blog2social') . '</a>.</div>
144
  <div id="b2s-heartbeat-fail" class="b2s-info-error"><button class="b2s-btn-close-meta-box b2s-close-icon" data-area-id="b2s-heartbeat-fail" title="close notice"></button>' . esc_html__('WordPress uses heartbeats by default, Blog2Social as well. Please enable heartbeats for using Blog2Social!', 'blog2social') . $b2sHeartbeatFaqLink . ' </div>
145
  <div id="b2s-post-meta-box-state-no-publish-future-customize" class="b2s-info-error"><button class="b2s-btn-close-meta-box b2s-close-icon" data-area-id="b2s-post-meta-box-state-no-publish-future-customize" title="close notice"></button>' . esc_html__('Your post is still on draft or pending status. Please make sure that your post is published or scheduled to be published on this blog. You can then auto-post or schedule and customize your social media posts with Blog2Social.', 'blog2social') . '</div>
176
  <div class="b2s-options" style="display:none;">
177
  <br>
178
  <input type="checkbox" class="b2s-enable-auto-post" id="b2s-enable-auto-post" name="b2s-enable-auto-post" value="1" ' . (($autoPostActive) ? 'checked' : '') . '><label for="b2s-enable-auto-post">' . esc_html__('enable Auto-Posting', 'blog2social') . '</label>
179
+ ' . ((isset($advancedOptions)) ? $advancedOptions : '') . '
180
  <a href="#b2s-post-box-calendar-header" id="b2s-post-box-calendar-btn">' . esc_html__('show calendar', 'blog2social') . '</a>
181
  <input type="hidden" name="b2s-profile-selected" value="' . ((isset($selectedProfileId)) ? esc_attr($selectedProfileId) : '-1') . '">
182
  <input type="hidden" name="b2s-profile-default" value="' . ((isset($defaultProfile)) ? esc_attr($defaultProfile) : '-1') . '">
readme.txt CHANGED
@@ -5,7 +5,7 @@ Tags: auto post, auto publish, social media scheduling, social media calendar, s
5
  Donate link: https://paypal.me/adenion
6
  Requires at least: 4.7.0
7
  Tested up to: 5.9
8
- Stable tag: 6.9.5
9
  License: GPLv3
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
@@ -234,6 +234,8 @@ To get started with the basics of Blog2Social and maybe find some useful tips an
234
  7. Keep track of your shared posts and scheduling plan with the Social Media Calendar.
235
 
236
  == Changelog ==
 
 
237
  = 6.9.5 =
238
  Instagram multi image & additional Security Update
239
  = 6.9.4 =
@@ -318,6 +320,8 @@ Usability Optimization, Rebrandly integration, url parameter settings
318
  New Image Posts, Imgur, Animated Gifs and Emojis
319
 
320
  == Upgrade Notice ==
 
 
321
  = 6.9.5 =
322
  Instagram multi image & additional Security Update
323
  = 6.9.4 =
5
  Donate link: https://paypal.me/adenion
6
  Requires at least: 4.7.0
7
  Tested up to: 5.9
8
+ Stable tag: 6.9.6
9
  License: GPLv3
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
234
  7. Keep track of your shared posts and scheduling plan with the Social Media Calendar.
235
 
236
  == Changelog ==
237
+ = 6.9.6 =
238
+ Additional Security Update
239
  = 6.9.5 =
240
  Instagram multi image & additional Security Update
241
  = 6.9.4 =
320
  New Image Posts, Imgur, Animated Gifs and Emojis
321
 
322
  == Upgrade Notice ==
323
+ = 6.9.6 =
324
+ Additional Security Update
325
  = 6.9.5 =
326
  Instagram multi image & additional Security Update
327
  = 6.9.4 =
views/b2s/curation.php CHANGED
@@ -6,7 +6,7 @@ $options = new B2S_Options(B2S_PLUGIN_BLOG_USER_ID);
6
  $optionUserTimeZone = $options->_getOption('user_time_zone');
7
  $userTimeZone = ($optionUserTimeZone !== false) ? $optionUserTimeZone : get_option('timezone_string');
8
  $userTimeZoneOffset = (empty($userTimeZone)) ? get_option('gmt_offset') : B2S_Util::getOffsetToUtcByTimeZone($userTimeZone);
9
- $selSchedDate = (isset($_GET['schedDate']) && !empty($_GET['schedDate'])) ? date("Y-m-d H:i:s", (strtotime($_GET['schedDate'] . ' ' . gmdate('H:i:s')))) : ""; //routing from calendar
10
  ?>
11
  <div class="b2s-container">
12
  <div class="b2s-inbox">
@@ -77,7 +77,7 @@ $selSchedDate = (isset($_GET['schedDate']) && !empty($_GET['schedDate'])) ? date
77
  </div>
78
  <div class="b2s-curation-result-area">
79
  <div class="col-md-12">
80
- <input type="hidden" id="b2s_user_timezone" name="b2s_user_timezone" value="<?php echo $userTimeZoneOffset ?>">
81
  <div class="b2s-curation-preview-area"></div>
82
  <div class="clearfix"></div>
83
  </div>
@@ -85,7 +85,7 @@ $selSchedDate = (isset($_GET['schedDate']) && !empty($_GET['schedDate'])) ? date
85
  </div>
86
  <div class="row b2s-curation-image-area">
87
  <div class="col-md-12">
88
- <input type="hidden" id="b2s_user_timezone" name="b2s_user_timezone" value="<?php echo $userTimeZoneOffset ?>">
89
  <div class="b2s-curation-form-area">
90
  <div class="col-xs-12 col-sm-5 col-lg-3">
91
  <button class="btn btn-primary btn-circle b2s-image-remove-btn" style="display:none;" type="button"><i class="glyphicon glyphicon-trash"></i></button>
6
  $optionUserTimeZone = $options->_getOption('user_time_zone');
7
  $userTimeZone = ($optionUserTimeZone !== false) ? $optionUserTimeZone : get_option('timezone_string');
8
  $userTimeZoneOffset = (empty($userTimeZone)) ? get_option('gmt_offset') : B2S_Util::getOffsetToUtcByTimeZone($userTimeZone);
9
+ $selSchedDate = (isset($_GET['schedDate']) && !empty($_GET['schedDate'])) ? date("Y-m-d H:i:s", (strtotime(sanitize_text_field(wp_unslash($_GET['schedDate'])) . ' ' . gmdate('H:i:s')))) : ""; //routing from calendar
10
  ?>
11
  <div class="b2s-container">
12
  <div class="b2s-inbox">
77
  </div>
78
  <div class="b2s-curation-result-area">
79
  <div class="col-md-12">
80
+ <input type="hidden" id="b2s_user_timezone" name="b2s_user_timezone" value="<?php echo esc_attr($userTimeZoneOffset) ?>">
81
  <div class="b2s-curation-preview-area"></div>
82
  <div class="clearfix"></div>
83
  </div>
85
  </div>
86
  <div class="row b2s-curation-image-area">
87
  <div class="col-md-12">
88
+ <input type="hidden" id="b2s_user_timezone" name="b2s_user_timezone" value="<?php echo esc_attr($userTimeZoneOffset) ?>">
89
  <div class="b2s-curation-form-area">
90
  <div class="col-xs-12 col-sm-5 col-lg-3">
91
  <button class="btn btn-primary btn-circle b2s-image-remove-btn" style="display:none;" type="button"><i class="glyphicon glyphicon-trash"></i></button>
views/b2s/html/header.php CHANGED
@@ -5,7 +5,7 @@ $wpUserData = wp_get_current_user();
5
  $meta = B2S_Meta::getInstance();
6
  $generalOptions = get_option('B2S_PLUGIN_GENERAL_OPTIONS');
7
  $b2sActive = $meta->is_b2s_active();
8
- $showYoast = ($_GET['page'] == 'blog2social-settings' && $meta->is_yoast_seo_active() && $b2sActive) ? 'block' : 'none';
9
  $showAioseop = ($meta->is_aioseop_active() && $b2sActive) ? 'block' : 'none';
10
  $showWebdaos = ($meta->is_webdados_active() && $b2sActive) ? 'block' : 'none';
11
  $getPages = unserialize(B2S_PLUGIN_PAGE_TITLE);
@@ -46,7 +46,7 @@ $hide7DayTrail = $options->_getOption('hide_7_day_trail');
46
  $hideFinalTrailModal = $options->_getOption('hide_final_trail');
47
 
48
  ?>
49
- <h1><?php echo (!empty($curPageTitle) ? $curPageTitle : ((isset($getPages[$_GET['page']]) && !empty($getPages[$_GET['page']])) ? $getPages[$_GET['page']] : '' )); ?></h1>
50
 
51
  <div class="b2s-support-area hidden-md hidden-lg">
52
  <a href="admin.php?page=blog2social-support" class="btn btn-primary btn-block"> <?php esc_html_e('Help & Support', 'blog2social'); ?></a>
@@ -86,7 +86,7 @@ $hideFinalTrailModal = $options->_getOption('hide_final_trail');
86
  </div>
87
 
88
  <!--Info Auto Post-->
89
- <div class="panel panel-group b2s-auto-posting" style="display: <?php echo $autoPostLimit; ?>;">
90
  <div class="panel-body">
91
  <span class="glyphicon glyphicon-remove glyphicon-danger"></span> <?php esc_html_e('Autoposter limit has been reached', 'blog2social') ?> <br> <?php esc_html_e('Your daily limit for posting automatically has been reached.', 'blog2social'); ?>
92
  </div>
@@ -104,7 +104,7 @@ $hideFinalTrailModal = $options->_getOption('hide_final_trail');
104
  </div>
105
  </div>
106
 
107
- <div class="panel panel-group b2s-meta-tags-yoast b2s-meta-tags-success" style="display:<?php echo $showYoast; ?>;">
108
  <div class="panel-body">
109
  <span class="glyphicon glyphicon-remove glyphicon-danger"></span> <?php echo esc_html__('How to use plugin settings for meta tags', 'blog2social'); ?>
110
  <br>
@@ -114,13 +114,13 @@ $hideFinalTrailModal = $options->_getOption('hide_final_trail');
114
  </div>
115
  </div>
116
 
117
- <div class="panel panel-group b2s-meta-tags-aioseop b2s-meta-tags-danger" style="display:<?php echo $showAioseop; ?>;">
118
  <div class="panel-body">
119
  <span class="glyphicon glyphicon-remove glyphicon-danger"></span> <?php esc_html_e('You currently have both Blog2Social Social Meta Tags and All in One SEO Pack plugins active. To make sure that your Social Meta Tags are set correctly, please deactivate All in One Seo Social Meta settings. If they are already deactivated, you can ignore this message.', 'blog2social'); ?>
120
  </div>
121
  </div>
122
 
123
- <div class="panel panel-group b2s-meta-tags-webdados b2s-meta-tags-danger" style="display:<?php echo $showWebdaos; ?>;">
124
  <div class="panel-body">
125
  <span class="glyphicon glyphicon-remove glyphicon-danger"></span> <?php esc_html_e('Blog2Social has detected another plugin that is setting Social Meta tags for your blog posts. To ensure that your Social Meta tags are set correctly for your social media posts shared with Blog2Social, please deactivate the Facebook Open Graph and Twitter Card Tags settings in your other plugins.', 'blog2social'); ?>
126
  </div>
@@ -302,7 +302,7 @@ if (!B2S_System::isblockedArea('B2S_MENU_MODUL_RATING', B2S_PLUGIN_ADMIN)) {
302
  <?php esc_html_e('Your free Blog2Social Premium trial version is activated for ', 'blog2social'); ?>
303
  <?php
304
  $days = B2S_Util::getTrialRemainingDays(B2S_PLUGIN_TRAIL_END, date_default_timezone_get());
305
- echo $days > 0 ? ("<span style='color:#79B232'>" . $days . "</span>" . esc_html__(' Days', 'blog2social')) : "<span style='color:#f33'>" . esc_html__(' today', 'blog2social') . "</span>";
306
  ?>
307
  </h2>
308
  <p>
@@ -379,15 +379,15 @@ if (!B2S_System::isblockedArea('B2S_MENU_MODUL_RATING', B2S_PLUGIN_ADMIN)) {
379
  </div>
380
  <div class="form-group col-xs-12">
381
  <label for="trial_email"><?php esc_html_e('E-Mail', 'blog2social'); ?></label>
382
- <input id="trial_email" class="form-control" type="email" value="<?php echo $wpUserData->user_email; ?>" name="trial_email">
383
  </div>
384
  <div class="form-group col-xs-12 col-md-6">
385
  <label for="trial_vorname"><?php esc_html_e('First Name', 'blog2social'); ?></label>
386
- <input id="trial_vorname" class="form-control" type="text" value="<?php echo $wpUserData->user_firstname; ?>" name="trial_vorname">
387
  </div>
388
  <div class="form-group col-xs-12 col-md-6">
389
  <label for="trial_nachname"><?php esc_html_e('Last Name', 'blog2social'); ?></label>
390
- <input id="trial_nachname" class="form-control" type="text" value="<?php echo $wpUserData->user_lastname; ?>" name="trial_nachname">
391
  </div>
392
  <div class="col-xs-12">
393
  <p>
5
  $meta = B2S_Meta::getInstance();
6
  $generalOptions = get_option('B2S_PLUGIN_GENERAL_OPTIONS');
7
  $b2sActive = $meta->is_b2s_active();
8
+ $showYoast = (sanitize_text_field(wp_unslash($_GET['page'])) == 'blog2social-settings' && $meta->is_yoast_seo_active() && $b2sActive) ? 'block' : 'none';
9
  $showAioseop = ($meta->is_aioseop_active() && $b2sActive) ? 'block' : 'none';
10
  $showWebdaos = ($meta->is_webdados_active() && $b2sActive) ? 'block' : 'none';
11
  $getPages = unserialize(B2S_PLUGIN_PAGE_TITLE);
46
  $hideFinalTrailModal = $options->_getOption('hide_final_trail');
47
 
48
  ?>
49
+ <h1><?php echo (!empty($curPageTitle) ? esc_html($curPageTitle) : ((isset($getPages[$_GET['page']]) && !empty($getPages[$_GET['page']])) ? $getPages[sanitize_text_field(wp_unslash($_GET['page']))] : '' )); ?></h1>
50
 
51
  <div class="b2s-support-area hidden-md hidden-lg">
52
  <a href="admin.php?page=blog2social-support" class="btn btn-primary btn-block"> <?php esc_html_e('Help & Support', 'blog2social'); ?></a>
86
  </div>
87
 
88
  <!--Info Auto Post-->
89
+ <div class="panel panel-group b2s-auto-posting" style="display: <?php echo esc_attr($autoPostLimit); ?>;">
90
  <div class="panel-body">
91
  <span class="glyphicon glyphicon-remove glyphicon-danger"></span> <?php esc_html_e('Autoposter limit has been reached', 'blog2social') ?> <br> <?php esc_html_e('Your daily limit for posting automatically has been reached.', 'blog2social'); ?>
92
  </div>
104
  </div>
105
  </div>
106
 
107
+ <div class="panel panel-group b2s-meta-tags-yoast b2s-meta-tags-success" style="display:<?php echo esc_attr($showYoast); ?>;">
108
  <div class="panel-body">
109
  <span class="glyphicon glyphicon-remove glyphicon-danger"></span> <?php echo esc_html__('How to use plugin settings for meta tags', 'blog2social'); ?>
110
  <br>
114
  </div>
115
  </div>
116
 
117
+ <div class="panel panel-group b2s-meta-tags-aioseop b2s-meta-tags-danger" style="display:<?php echo esc_attr($showAioseop); ?>;">
118
  <div class="panel-body">
119
  <span class="glyphicon glyphicon-remove glyphicon-danger"></span> <?php esc_html_e('You currently have both Blog2Social Social Meta Tags and All in One SEO Pack plugins active. To make sure that your Social Meta Tags are set correctly, please deactivate All in One Seo Social Meta settings. If they are already deactivated, you can ignore this message.', 'blog2social'); ?>
120
  </div>
121
  </div>
122
 
123
+ <div class="panel panel-group b2s-meta-tags-webdados b2s-meta-tags-danger" style="display:<?php echo esc_attr($showWebdaos); ?>;">
124
  <div class="panel-body">
125
  <span class="glyphicon glyphicon-remove glyphicon-danger"></span> <?php esc_html_e('Blog2Social has detected another plugin that is setting Social Meta tags for your blog posts. To ensure that your Social Meta tags are set correctly for your social media posts shared with Blog2Social, please deactivate the Facebook Open Graph and Twitter Card Tags settings in your other plugins.', 'blog2social'); ?>
126
  </div>
302
  <?php esc_html_e('Your free Blog2Social Premium trial version is activated for ', 'blog2social'); ?>
303
  <?php
304
  $days = B2S_Util::getTrialRemainingDays(B2S_PLUGIN_TRAIL_END, date_default_timezone_get());
305
+ echo $days > 0 ? ("<span style='color:#79B232'>" . esc_html($days) . "</span>" . esc_html__(' Days', 'blog2social')) : "<span style='color:#f33'>" . esc_html__(' today', 'blog2social') . "</span>";
306
  ?>
307
  </h2>
308
  <p>
379
  </div>
380
  <div class="form-group col-xs-12">
381
  <label for="trial_email"><?php esc_html_e('E-Mail', 'blog2social'); ?></label>
382
+ <input id="trial_email" class="form-control" type="email" value="<?php echo esc_html($wpUserData->user_email); ?>" name="trial_email">
383
  </div>
384
  <div class="form-group col-xs-12 col-md-6">
385
  <label for="trial_vorname"><?php esc_html_e('First Name', 'blog2social'); ?></label>
386
+ <input id="trial_vorname" class="form-control" type="text" value="<?php echo esc_html($wpUserData->user_firstname); ?>" name="trial_vorname">
387
  </div>
388
  <div class="form-group col-xs-12 col-md-6">
389
  <label for="trial_nachname"><?php esc_html_e('Last Name', 'blog2social'); ?></label>
390
+ <input id="trial_nachname" class="form-control" type="text" value="<?php echo esc_html($wpUserData->user_lastname); ?>" name="trial_nachname">
391
  </div>
392
  <div class="col-xs-12">
393
  <p>
views/b2s/html/post.navbar.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
- $getPage = $_GET['page'];
3
- $getType = (isset($_GET['type']) && !empty($_GET['type'])) ? $_GET['type'] : 'link';
4
  $isPremiumInfo = (B2S_PLUGIN_USER_VERSION == 0) ? 'b2s-btn-disabled' : '';
5
  require_once(B2S_PLUGIN_DIR . 'includes/B2S/Post/Tools.php');
6
  $noticeCount = B2S_Post_Tools::countNewNotifications(B2S_PLUGIN_BLOG_USER_ID);
1
  <?php
2
+ $getPage = sanitize_text_field(wp_unslash($_GET['page']));
3
+ $getType = (isset($_GET['type']) && !empty($_GET['type'])) ? sanitize_text_field(wp_unslash($_GET['type'])) : 'link';
4
  $isPremiumInfo = (B2S_PLUGIN_USER_VERSION == 0) ? 'b2s-btn-disabled' : '';
5
  require_once(B2S_PLUGIN_DIR . 'includes/B2S/Post/Tools.php');
6
  $noticeCount = B2S_Post_Tools::countNewNotifications(B2S_PLUGIN_BLOG_USER_ID);
views/b2s/html/sidebar.php CHANGED
@@ -2,7 +2,7 @@
2
  $b2sLastVersion = get_option('b2s_plugin_version');
3
  $customizeArea = B2S_System::customizeArea();
4
 
5
- $getPage = (isset($_GET['page']) && !empty($_GET['page'])) ? $_GET['page'] : '';
6
  ?>
7
  <!-- Sidebar|Start -Include-->
8
  <div class="col-md-3 col-xs-12 del-padding-left del-padding-right b2s-sidebar hidden-xs hidden-sm b2s-margin-right-20">
@@ -13,7 +13,7 @@ $getPage = (isset($_GET['page']) && !empty($_GET['page'])) ? $_GET['page'] : '';
13
  <div class="media">
14
  <?php if (is_array($customizeArea) && isset($customizeArea['image_path']) && !empty($customizeArea['image_path'])) { ?>
15
  <div class="col-md-12 del-padding-left">
16
- <img class="img-responsive" src="<?php echo $customizeArea['image_path']; ?>" alt="logo">
17
  </div>
18
  <?php } else { ?>
19
  <div class="col-md-2 del-padding-left">
@@ -34,9 +34,9 @@ $getPage = (isset($_GET['page']) && !empty($_GET['page'])) ? $_GET['page'] : '';
34
  <?php
35
  $versionType = unserialize(B2S_PLUGIN_VERSION_TYPE);
36
  if (defined("B2S_PLUGIN_TRAIL_END") && strtotime(B2S_PLUGIN_TRAIL_END) > time()) {
37
- echo 'FREE-TRIAL (' . $versionType[B2S_PLUGIN_USER_VERSION] . ')';
38
  } else {
39
- echo $versionType[B2S_PLUGIN_USER_VERSION];
40
  }
41
  ?><i class="b2s-sidebar-licence-btn-edit glyphicon glyphicon-pencil"></i>
42
  </a>
2
  $b2sLastVersion = get_option('b2s_plugin_version');
3
  $customizeArea = B2S_System::customizeArea();
4
 
5
+ $getPage = (isset($_GET['page']) && !empty($_GET['page'])) ? sanitize_text_field(wp_unslash($_GET['page'])) : '';
6
  ?>
7
  <!-- Sidebar|Start -Include-->
8
  <div class="col-md-3 col-xs-12 del-padding-left del-padding-right b2s-sidebar hidden-xs hidden-sm b2s-margin-right-20">
13
  <div class="media">
14
  <?php if (is_array($customizeArea) && isset($customizeArea['image_path']) && !empty($customizeArea['image_path'])) { ?>
15
  <div class="col-md-12 del-padding-left">
16
+ <img class="img-responsive" src="<?php echo esc_url($customizeArea['image_path']); ?>" alt="logo">
17
  </div>
18
  <?php } else { ?>
19
  <div class="col-md-2 del-padding-left">
34
  <?php
35
  $versionType = unserialize(B2S_PLUGIN_VERSION_TYPE);
36
  if (defined("B2S_PLUGIN_TRAIL_END") && strtotime(B2S_PLUGIN_TRAIL_END) > time()) {
37
+ echo 'FREE-TRIAL (' . esc_html($versionType[B2S_PLUGIN_USER_VERSION]) . ')';
38
  } else {
39
+ echo esc_html($versionType[B2S_PLUGIN_USER_VERSION]);
40
  }
41
  ?><i class="b2s-sidebar-licence-btn-edit glyphicon glyphicon-pencil"></i>
42
  </a>
views/b2s/html/sidebar.ship.php CHANGED
@@ -10,7 +10,7 @@ $customizeArea = B2S_System::customizeArea();
10
  <div class="media">
11
  <?php if (is_array($customizeArea) && isset($customizeArea['image_path']) && !empty($customizeArea['image_path'])) { ?>
12
  <div class="col-md-12 del-padding-left">
13
- <img class="img-responsive" src="<?php echo $customizeArea['image_path']; ?>" alt="logo">
14
  </div>
15
  <?php } else { ?>
16
  <div class="col-md-2 del-padding-left">
@@ -31,9 +31,9 @@ $customizeArea = B2S_System::customizeArea();
31
  <?php
32
  $versionType = unserialize(B2S_PLUGIN_VERSION_TYPE);
33
  if (defined("B2S_PLUGIN_TRAIL_END") && strtotime(B2S_PLUGIN_TRAIL_END) > time()) {
34
- echo 'FREE-TRIAL (' . $versionType[B2S_PLUGIN_USER_VERSION] . ')';
35
  } else {
36
- echo $versionType[B2S_PLUGIN_USER_VERSION];
37
  }
38
  ?><i class="b2s-sidebar-licence-btn-edit glyphicon glyphicon-pencil"></i>
39
  </a>
10
  <div class="media">
11
  <?php if (is_array($customizeArea) && isset($customizeArea['image_path']) && !empty($customizeArea['image_path'])) { ?>
12
  <div class="col-md-12 del-padding-left">
13
+ <img class="img-responsive" src="<?php echo esc_url($customizeArea['image_path']); ?>" alt="logo">
14
  </div>
15
  <?php } else { ?>
16
  <div class="col-md-2 del-padding-left">
31
  <?php
32
  $versionType = unserialize(B2S_PLUGIN_VERSION_TYPE);
33
  if (defined("B2S_PLUGIN_TRAIL_END") && strtotime(B2S_PLUGIN_TRAIL_END) > time()) {
34
+ echo 'FREE-TRIAL (' . esc_html($versionType[B2S_PLUGIN_USER_VERSION]) . ')';
35
  } else {
36
+ echo esc_html($versionType[B2S_PLUGIN_USER_VERSION]);
37
  }
38
  ?><i class="b2s-sidebar-licence-btn-edit glyphicon glyphicon-pencil"></i>
39
  </a>
views/b2s/post.approve.php CHANGED
@@ -4,7 +4,7 @@ wp_nonce_field('b2s_security_nonce', 'b2s_security_nonce');
4
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
5
  require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
6
  require_once B2S_PLUGIN_DIR . 'includes/B2S/Settings/Item.php';
7
- $b2sShowByDate = isset($_GET['b2sShowByDate']) ? (preg_match("#^[0-9\-.\]]+$#", trim($_GET['b2sShowByDate'])) ? trim($_GET['b2sShowByDate']) : "") : ""; //YYYY-mm-dd
8
  $b2sUserAuthId = isset($_GET['b2sUserAuthId']) ? (int) $_GET['b2sUserAuthId'] : 0;
9
  $b2sPostBlogId = isset($_GET['b2sPostBlogId']) ? (int) $_GET['b2sPostBlogId'] : 0;
10
  ?>
4
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
5
  require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
6
  require_once B2S_PLUGIN_DIR . 'includes/B2S/Settings/Item.php';
7
+ $b2sShowByDate = isset($_GET['b2sShowByDate']) ? (preg_match("#^[0-9\-.\]]+$#", trim($_GET['b2sShowByDate'])) ? trim(sanitize_text_field(wp_unslash($_GET['b2sShowByDate']))) : "") : ""; //YYYY-mm-dd
8
  $b2sUserAuthId = isset($_GET['b2sUserAuthId']) ? (int) $_GET['b2sUserAuthId'] : 0;
9
  $b2sPostBlogId = isset($_GET['b2sPostBlogId']) ? (int) $_GET['b2sPostBlogId'] : 0;
10
  ?>
views/b2s/post.calendar.php CHANGED
@@ -1,344 +1,388 @@
1
- <?php
2
- wp_nonce_field('b2s_security_nonce', 'b2s_security_nonce');
3
- /* Data */
4
- require_once (B2S_PLUGIN_DIR . 'includes/B2S/Calendar/Filter.php');
5
- require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
6
- require_once (B2S_PLUGIN_DIR . 'includes/B2S/Ship/Image.php');
7
- require_once (B2S_PLUGIN_DIR . 'includes/B2S/Settings/Item.php');
8
- require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
9
-
10
- $options = new B2S_Options(B2S_PLUGIN_BLOG_USER_ID);
11
- $optionUserTimeZone = $options->_getOption('user_time_zone');
12
- $userTimeZone = ($optionUserTimeZone !== false) ? $optionUserTimeZone : get_option('timezone_string');
13
- $userTimeZoneOffset = (empty($userTimeZone)) ? get_option('gmt_offset') : B2S_Util::getOffsetToUtcByTimeZone($userTimeZone);
14
- $optionUserTimeFormat = $options->_getOption('user_time_format');
15
- if($optionUserTimeFormat == false) {
16
- $optionUserTimeFormat = (substr(B2S_LANGUAGE, 0, 2) == 'de') ? 0 : 1;
17
- }
18
- $metaSettings = get_option('B2S_PLUGIN_GENERAL_OPTIONS');
19
- ?>
20
-
21
-
22
- <div class="b2s-container">
23
- <div class="b2s-inbox">
24
- <div class="col-md-12 del-padding-left">
25
- <?php require_once (B2S_PLUGIN_DIR . 'views/b2s/html/sidebar.php'); ?>
26
- <div class="col-md-9 del-padding-left del-padding-right">
27
- <!--Header|Start - Include-->
28
- <?php require_once (B2S_PLUGIN_DIR . 'views/b2s/html/header.php'); ?>
29
- <!--Header|End-->
30
- <div class="clearfix"></div>
31
- <!--Navbar|Start-->
32
- <div class="panel panel-default">
33
- <div class="panel-body">
34
- <?php require_once (B2S_PLUGIN_DIR . 'views/b2s/html/post.navbar.php'); ?>
35
- </div>
36
- </div>
37
- <!--Navbar|End-->
38
- <div class="clearfix"></div>
39
- <!--Content|Start-->
40
- <div class="panel panel-default">
41
- <div class="panel-body">
42
- <div>
43
- <div class="grid-body">
44
- <div class="clearfix"></div>
45
- <div class="col-md-12 b2s-calendar-filter form-inline del-padding-left del-padding-right">
46
- <div class="b2s-calendar-filter-network-legend-text">
47
- <?php esc_html_e('Sort by network', 'blog2social'); ?>
48
- <select id="b2s-calendar-filter-status" class="form-control pull-right">
49
- <option selected value="0"><?php esc_html_e('show all', 'blog2social'); ?></option>
50
- <option value="1"><?php esc_html_e('published', 'blog2social'); ?></option>
51
- <option value="2"><?php esc_html_e('scheduled', 'blog2social'); ?></option>
52
- </select>
53
- </div>
54
- <div class="clearfix"></div>
55
- <?php
56
- $filter = new B2S_Calendar_Filter();
57
- $filterNetwork = $filter->getNetworkHtml();
58
- if (!empty($filterNetwork)) {
59
- ?>
60
- <div class="b2s-calendar-filter-network-list">
61
- <?php echo $filterNetwork ?>
62
- </div>
63
- <div class="b2s-calendar-filter-network-account-list"></div>
64
- <?php }
65
- ?>
66
- </div>
67
- <div class="clearfix"></div><hr>
68
- <div class="b2s-loading-area">
69
- <br>
70
- <div class="b2s-loader-impulse b2s-loader-impulse-md"></div>
71
- <div class="clearfix"></div>
72
- <div class="text-center b2s-loader-text"><?php esc_html_e("Loading...", "blog2social"); ?></div>
73
- </div>
74
- <div id='b2s_calendar'></div>
75
- <br>
76
- <script>
77
- var b2s_calendar_locale = '<?php echo esc_js(strtolower(substr(get_locale(), 0, 2))); ?>';
78
- var b2s_calendar_date = '<?php echo esc_js(B2S_Util::getbyIdentLocalDate($userTimeZoneOffset, "Y-m-d")); ?>';
79
- var b2s_calendar_datetime = '<?php echo esc_js(B2S_Util::getbyIdentLocalDate($userTimeZoneOffset)); ?>';
80
- var b2s_has_premium = <?php echo esc_js(((B2S_PLUGIN_USER_VERSION > 0) ? "true" : "false")); ?>;
81
- var b2s_plugin_url = '<?php echo esc_url(B2S_PLUGIN_URL); ?>';
82
- var b2s_calendar_formats = <?php echo json_encode(array('post' => array(esc_html__('Link Post', 'blog2social'), esc_html__('Image Post', 'blog2social')), 'image' => array(esc_html__('Image with frame', 'blog2social'), esc_html__('Image cut out', 'blog2social')))); ?>;
83
- var b2s_is_calendar = true;
84
- </script>
85
- </div>
86
- </div>
87
- <?php
88
- $noLegendCalender=1;
89
- require_once (B2S_PLUGIN_DIR . 'views/b2s/html/footer.php');
90
- ?>
91
- </div>
92
- </div>
93
- </div>
94
- </div>
95
- </div>
96
- </div>
97
-
98
- <input type="hidden" id="b2sLang" value="<?php echo esc_attr(substr(B2S_LANGUAGE, 0, 2)); ?>">
99
- <input type="hidden" id="b2sUserTimeFormat" value="<?php echo esc_attr($optionUserTimeFormat); ?>">
100
- <input type="hidden" id="b2sJSTextAddPost" value="<?php esc_html_e("add post", "blog2social"); ?>">
101
- <input type="hidden" id="b2sUserLang" value="<?php echo esc_attr(strtolower(substr(get_locale(), 0, 2))); ?>">
102
- <input type='hidden' id="user_timezone" name="user_timezone" value="<?php echo esc_attr($userTimeZoneOffset); ?>">
103
- <input type="hidden" id="user_version" name="user_version" value="<?php echo esc_attr(B2S_PLUGIN_USER_VERSION); ?>">
104
- <input type="hidden" id="b2sDefaultNoImage" value="<?php echo plugins_url('/assets/images/no-image.png', B2S_PLUGIN_FILE); ?>">
105
- <input type="hidden" id="b2sPostId" value="">
106
- <input type="hidden" id="b2sInsertImageType" value="0">
107
- <input type="hidden" id="isOgMetaChecked" value="<?php echo (isset($metaSettings['og_active']) ? (int) $metaSettings['og_active'] : 0); ?>">
108
- <input type="hidden" id="isCardMetaChecked" value="<?php echo (isset($metaSettings['card_active']) ? (int) $metaSettings['card_active'] : 0); ?>">
109
- <input type="hidden" id="b2sRedirectUrlContentCuration" value="<?php echo esc_url(get_option('siteurl') . ((substr(get_option('siteurl'), -1, 1) == '/') ? '' : '/') . 'wp-admin/admin.php?page=blog2social-curation'); ?>">
110
- <input type="hidden" id="b2sNotAllowGif" value="<?php echo esc_attr(implode(";", json_decode(B2S_PLUGIN_NETWORK_NOT_ALLOW_GIF, true))); ?>">
111
- <input type="hidden" id="b2sAnimateGif" value='<?php echo esc_attr(B2S_PLUGIN_NETWORK_ANIMATE_GIF); ?>'>
112
- <input type="hidden" id="ogMetaNetworks" value="<?php echo esc_attr(implode(';', json_decode(B2S_PLUGIN_NETWORK_META_TAGS, true)['og'])); ?>">
113
- <input type="hidden" id="b2sEmojiTranslation" value='<?php echo esc_attr(json_encode(B2S_Tools::getEmojiTranslationList())); ?>'>
114
- <!--Routing from dashboard-->
115
- <input type="hidden" id="b2s_rfd" value="<?php echo (isset($_GET['rfd'])) ? 1 : 0; ?>">
116
- <input type="hidden" id="b2s_rfd_b2s_id" value="<?php echo (isset($_GET['b2s_id'])) ? esc_attr($_GET['b2s_id']) : ""; ?>">
117
-
118
- <div id="b2s-post-ship-item-post-format-modal" class="modal fade" role="dialog" aria-labelledby="b2s-post-ship-item-post-format-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
119
- <div class="modal-dialog modal-lg">
120
- <div class="modal-content">
121
- <div class="modal-header">
122
- <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-post-ship-item-post-format-modal">&times;</button>
123
- <h4 class="modal-title"><?php esc_html_e('Choose your', 'blog2social') ?> <span id="b2s-post-ship-item-post-format-network-title"></span> <?php esc_html_e('Post Format', 'blog2social') ?>
124
- <?php if (B2S_PLUGIN_USER_VERSION >= 2) { ?>
125
- <?php esc_html_e('for:', 'blog2social') ?> <span id="b2s-post-ship-item-post-format-network-display-name"></span>
126
- <?php } ?>
127
- </h4>
128
- </div>
129
- <div class="modal-body">
130
- <div class="row">
131
- <div class="col-xs-12">
132
- <?php
133
- $settingsItem = new B2S_Settings_Item();
134
- echo $settingsItem->setNetworkSettingsHtml();
135
- echo $settingsItem->getNetworkSettingsHtml();
136
- ?>
137
- </div>
138
- </div>
139
- <div class="row">
140
- <div class="col-xs-12">
141
- <div class="text-center">
142
- <br>
143
- <div class="b2s-post-format-settings-info" data-network-id="1" style="display:none;">
144
- <b><?php esc_html_e('Define the default settings for the custom post format for all of your Facebook accounts in the Blog2Social settings.', 'blog2social'); ?></b>
145
- </div>
146
- <div class="b2s-post-format-settings-info" data-network-id="2" style="display:none;">
147
- <b><?php esc_html_e('Define the default settings for the custom post format for all of your Twitter accounts in the Blog2Social settings.', 'blog2social'); ?></b>
148
- </div>
149
- <div class="b2s-post-format-settings-info" data-network-id="3" style="display:none;">
150
- <b><?php esc_html_e('Define the default settings for the custom post format for all of your LinkedIn accounts in the Blog2Social settings.', 'blog2social'); ?></b>
151
- </div>
152
- <div class="b2s-post-format-settings-info" data-network-id="12" style="display:none;">
153
- <b><?php esc_html_e('Define the default settings for the custom post format for all of your Instagram accounts in the Blog2Social settings.', 'blog2social'); ?></b>
154
- </div>
155
- </div>
156
- </div>
157
- </div>
158
- </div>
159
- </div>
160
- </div>
161
- </div>
162
-
163
- <div id="b2s-network-select-image" class="modal fade" role="dialog" aria-labelledby="b2s-network-select-image" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
164
- <div class="modal-dialog modal-lg">
165
- <div class="modal-content">
166
- <div class="modal-header">
167
- <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-network-select-image">&times;</button>
168
- <h4 class="modal-title"><?php esc_html_e('Select image for', 'blog2social') ?> <span class="b2s-selected-network-for-image-info"></span></h4>
169
- </div>
170
- <div class="modal-body">
171
- <div class="row">
172
- <div class="col-xs-12">
173
- <div class="b2s-network-select-image-content"></div>
174
- </div>
175
- </div>
176
- </div>
177
- </div>
178
- </div>
179
- </div>
180
-
181
- <div id="b2s-show-post-type-modal" class="modal fade" role="dialog" aria-labelledby="b2s-show-post-type-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
182
- <div class="modal-dialog modal-lg">
183
- <div class="modal-content">
184
- <div class="modal-header">
185
- <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-show-post-type-modal">&times;</button>
186
- <h4 class="modal-title"><?php esc_html_e('What would you like to share?', 'blog2social') ?></h4>
187
- </div>
188
- <div class="modal-body">
189
- <div class="row">
190
- <div class="col-md-6 col-xs-12">
191
- <div class="b2s-post-type-area text-center">
192
- <div class="image">
193
- <img class="img-width-150" src="<?php echo plugins_url('/assets/images/b2s/blog-post-icon.png', B2S_PLUGIN_FILE); ?>" alt="blog post">
194
- </div>
195
- <div class="text">
196
- <?php esc_html_e("Share your WordPress posts, pages or products", "blog2social") ?>
197
- </div>
198
- <div class="action">
199
- <button class="btn btn-primary" id="b2s-btn-select-blog-post"><?php esc_html_e("select", "blog2social"); ?></button>
200
- </div>
201
- </div>
202
- </div>
203
- <div class="col-md-6 col-xs-12">
204
- <div class="b2s-post-type-area text-center">
205
- <div class="image">
206
- <img class="img-width-150" src="<?php echo plugins_url('/assets/images/b2s/content-curation-icon.png', B2S_PLUGIN_FILE); ?>" alt="content curation">
207
- </div>
208
- <div class="text">
209
- <?php esc_html_e("Create or share content from other sources", "blog2social") ?>
210
- </div>
211
- <div class="action">
212
- <button class="btn btn-primary" id="b2s-btn-select-content-curation"><?php esc_html_e("select", "blog2social"); ?></button>
213
- </div>
214
- </div>
215
- </div>
216
- <input type="hidden" id="b2sSelSchedDate" value="">
217
-
218
- </div>
219
- </div>
220
- </div>
221
- </div>
222
- </div>
223
-
224
-
225
- <div id="b2s-show-post-all-modal" class="modal fade" role="dialog" aria-labelledby="b2s-post-all-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
226
- <div class="modal-dialog modal-lg">
227
- <div class="modal-content">
228
- <div class="modal-header">
229
- <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-show-post-all-modal">&times;</button>
230
- <h4 class="modal-title"><?php esc_html_e('Select a post', 'blog2social') ?></h4>
231
- </div>
232
- <div class="modal-body">
233
- <div class="row">
234
- <div class="col-xs-12">
235
- <div class="b2s-all-post-content">
236
- <div class="b2s-post">
237
- <div class="grid-body">
238
- <div class="hidden-lg hidden-md hidden-sm filterShow"><a href="#" onclick="showFilter('show');return false;"><i class="glyphicon glyphicon-chevron-down"></i><?php esc_html_e('filter', 'blog2social') ?></a></div>
239
- <div class="hidden-lg hidden-md hidden-sm filterHide"><a href="#" onclick="showFilter('hide');return false;"><i class="glyphicon glyphicon-chevron-up"></i><?php esc_html_e('filter', 'blog2social') ?></a></div>
240
- <form class="b2sSortForm form-inline pull-left" action="#">
241
- <input id="b2sType" type="hidden" value="all" name="b2sType">
242
- <input id="b2sShowByDate" type="hidden" value="" name="b2sShowByDate">
243
- <input id="b2sPagination" type="hidden" value="1" name="b2sPagination">
244
- <?php
245
- $postFilter = new B2S_Post_Filter('all');
246
- echo $postFilter->getItemHtml();
247
- ?>
248
- </form>
249
- </div>
250
- </div>
251
- <div class="clearfix"></div>
252
- <div class="b2s-loading-area" style="display:none">
253
- <br>
254
- <div class="b2s-loader-impulse b2s-loader-impulse-md"></div>
255
- <div class="clearfix"></div>
256
- <div class="text-center b2s-loader-text"><?php esc_html_e("Loading...", "blog2social"); ?></div>
257
- </div>
258
- <div class="clearfix"></div>
259
- <br>
260
- <ul class="list-group b2s-sort-result-item-area"></ul>
261
- <br>
262
- <nav class="b2s-sort-pagination-area text-center"></nav>
263
- </div>
264
- </div>
265
- </div>
266
- </div>
267
- </div>
268
- </div>
269
- </div>
270
-
271
-
272
- <div id="b2s-sched-post-modal" class="modal fade" role="dialog" aria-labelledby="b2s-sched-post-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
273
- <div class="modal-dialog">
274
- <div class="modal-content">
275
- <div class="modal-header">
276
- <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-sched-post-modal">&times;</button>
277
- <h4 class="modal-title"><?php esc_html_e('Need to schedule your posts?', 'blog2social') ?></h4>
278
- </div>
279
- <div class="modal-body">
280
- <p><?php esc_html_e('Blog2Social Premium covers everything you need.', 'blog2social') ?></p>
281
- <br>
282
- <div class="clearfix"></div>
283
- <b><?php esc_html_e('Schedule for specific dates', 'blog2social') ?></b>
284
- <p><?php esc_html_e('You want to publish a post on a specific date? No problem! Just enter your desired date and you are ready to go!', 'blog2social') ?></p>
285
- <br>
286
- <b><?php esc_html_e('Schedule post recurrently', 'blog2social') ?></b>
287
- <p><?php esc_html_e('You have evergreen content you want to re-share from time to time in your timeline? Schedule your evergreen content to be shared once, multiple times or recurringly at specific times.', 'blog2social') ?></p>
288
- <br>
289
- <b><?php esc_html_e('Best Time Scheduler', 'blog2social') ?></b>
290
- <p><?php esc_html_e('Whenever you publish a post, only a fraction of your followers will actually see your post. Use the Blog2Social Best Times Scheduler to share your post at the best times for each social network. Get more outreach and extend the lifespan of your posts.', 'blog2social') ?></p>
291
- <br>
292
- <?php if (B2S_PLUGIN_USER_VERSION == 0) { ?>
293
- <hr>
294
- <?php esc_html_e('With Blog2Social Premium you can:', 'blog2social') ?>
295
- <br>
296
- <br>
297
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Post on pages and groups', 'blog2social') ?><br>
298
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Share on multiple profiles, pages and groups', 'blog2social') ?><br>
299
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Auto-post and auto-schedule new and updated blog posts', 'blog2social') ?><br>
300
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Schedule your posts at the best times on each network', 'blog2social') ?><br>
301
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Best Time Manager: use predefined best time scheduler to auto-schedule your social media posts', 'blog2social') ?><br>
302
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Schedule your post for one time, multiple times or recurrently', 'blog2social') ?><br>
303
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Schedule and re-share old posts', 'blog2social') ?><br>
304
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Select link format or image format for your posts', 'blog2social') ?><br>
305
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Select individual images per post', 'blog2social') ?><br>
306
- <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Reporting & calendar: keep track of your published and scheduled social media posts', 'blog2social') ?><br>
307
- <br>
308
- <a target="_blank" href="<?php echo esc_url(B2S_Tools::getSupportLink('affiliate')); ?>" class="btn btn-success center-block"><?php esc_html_e('Upgrade to SMART and above', 'blog2social') ?></a>
309
- <br>
310
- <center> <?php echo sprintf(__('or <a target="_blank" href="%s">start with free 30-days-trial of Blog2Social Premium</a> (no payment information needed)', 'blog2social'), esc_url('https://service.blog2social.com/trial')); ?> </center>
311
- <?php } ?>
312
- </div>
313
- </div>
314
- </div>
315
- </div>
316
-
317
- <div id="b2s-show-error-modal" class="modal fade" role="dialog" aria-labelledby="b2s-show-error-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
318
- <div class="modal-dialog modal-lg">
319
- <div class="modal-content">
320
- <div class="modal-header">
321
- <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-show-error-modal">&times;</button>
322
- <h4 class="modal-title"><?php esc_html_e('Notification', 'blog2social') ?></h4>
323
- </div>
324
- <div class="modal-body">
325
- <div class="row">
326
- <div class="col-xs-12">
327
- <div class="alert alert-danger b2s-error-text"></div>
328
- </div>
329
- </div>
330
- </div>
331
- </div>
332
- </div>
333
- </div>
334
-
335
- <div id="b2sImageZoomModal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="b2sImageZoomModal" aria-hidden="true" data-backdrop="false" style="display:none;">
336
- <div class="modal-dialog">
337
- <div class="modal-content">
338
- <div class="modal-body">
339
- <button type="button" class="btn btn-primary btn-circle b2sImageZoomModalClose b2s-modal-close close" data-modal-name="#b2sImageZoomModal" aria-label="Close"><i class="glyphicon glyphicon-remove"></i></button>
340
- <img id="b2sImageZoom">
341
- </div>
342
- </div>
343
- </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
344
  </div>
1
+ <?php
2
+ wp_nonce_field('b2s_security_nonce', 'b2s_security_nonce');
3
+ /* Data */
4
+ require_once (B2S_PLUGIN_DIR . 'includes/B2S/Calendar/Filter.php');
5
+ require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
6
+ require_once (B2S_PLUGIN_DIR . 'includes/B2S/Ship/Image.php');
7
+ require_once (B2S_PLUGIN_DIR . 'includes/B2S/Settings/Item.php');
8
+ require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
9
+
10
+ $options = new B2S_Options(B2S_PLUGIN_BLOG_USER_ID);
11
+ $optionUserTimeZone = $options->_getOption('user_time_zone');
12
+ $userTimeZone = ($optionUserTimeZone !== false) ? $optionUserTimeZone : get_option('timezone_string');
13
+ $userTimeZoneOffset = (empty($userTimeZone)) ? get_option('gmt_offset') : B2S_Util::getOffsetToUtcByTimeZone($userTimeZone);
14
+ $optionUserTimeFormat = $options->_getOption('user_time_format');
15
+ if($optionUserTimeFormat == false) {
16
+ $optionUserTimeFormat = (substr(B2S_LANGUAGE, 0, 2) == 'de') ? 0 : 1;
17
+ }
18
+ $metaSettings = get_option('B2S_PLUGIN_GENERAL_OPTIONS');
19
+ ?>
20
+
21
+
22
+ <div class="b2s-container">
23
+ <div class="b2s-inbox">
24
+ <div class="col-md-12 del-padding-left">
25
+ <?php require_once (B2S_PLUGIN_DIR . 'views/b2s/html/sidebar.php'); ?>
26
+ <div class="col-md-9 del-padding-left del-padding-right">
27
+ <!--Header|Start - Include-->
28
+ <?php require_once (B2S_PLUGIN_DIR . 'views/b2s/html/header.php'); ?>
29
+ <!--Header|End-->
30
+ <div class="clearfix"></div>
31
+ <!--Navbar|Start-->
32
+ <div class="panel panel-default">
33
+ <div class="panel-body">
34
+ <?php require_once (B2S_PLUGIN_DIR . 'views/b2s/html/post.navbar.php'); ?>
35
+ </div>
36
+ </div>
37
+ <!--Navbar|End-->
38
+ <div class="clearfix"></div>
39
+ <!--Content|Start-->
40
+ <div class="panel panel-default">
41
+ <div class="panel-body">
42
+ <div>
43
+ <div class="grid-body">
44
+ <div class="clearfix"></div>
45
+ <div class="col-md-12 b2s-calendar-filter form-inline del-padding-left del-padding-right">
46
+ <div class="b2s-calendar-filter-network-legend-text">
47
+ <?php esc_html_e('Sort by network', 'blog2social'); ?>
48
+ <select id="b2s-calendar-filter-status" class="form-control pull-right">
49
+ <option selected value="0"><?php esc_html_e('show all', 'blog2social'); ?></option>
50
+ <option value="1"><?php esc_html_e('published', 'blog2social'); ?></option>
51
+ <option value="2"><?php esc_html_e('scheduled', 'blog2social'); ?></option>
52
+ </select>
53
+ </div>
54
+ <div class="clearfix"></div>
55
+ <?php
56
+ $filter = new B2S_Calendar_Filter();
57
+ $filterNetwork = $filter->getNetworkHtml();
58
+ if (!empty($filterNetwork)) {
59
+ ?>
60
+ <div class="b2s-calendar-filter-network-list">
61
+ <?php echo $filterNetwork ?>
62
+ </div>
63
+ <div class="b2s-calendar-filter-network-account-list"></div>
64
+ <?php }
65
+ ?>
66
+ </div>
67
+ <div class="clearfix"></div><hr>
68
+ <div class="b2s-loading-area">
69
+ <br>
70
+ <div class="b2s-loader-impulse b2s-loader-impulse-md"></div>
71
+ <div class="clearfix"></div>
72
+ <div class="text-center b2s-loader-text"><?php esc_html_e("Loading...", "blog2social"); ?></div>
73
+ </div>
74
+ <div id='b2s_calendar'></div>
75
+ <br>
76
+ <script>
77
+ var b2s_calendar_locale = '<?php echo esc_js(strtolower(substr(get_locale(), 0, 2))); ?>';
78
+ var b2s_calendar_date = '<?php echo esc_js(B2S_Util::getbyIdentLocalDate($userTimeZoneOffset, "Y-m-d")); ?>';
79
+ var b2s_calendar_datetime = '<?php echo esc_js(B2S_Util::getbyIdentLocalDate($userTimeZoneOffset)); ?>';
80
+ var b2s_has_premium = <?php echo esc_js(((B2S_PLUGIN_USER_VERSION > 0) ? "true" : "false")); ?>;
81
+ var b2s_plugin_url = '<?php echo esc_url(B2S_PLUGIN_URL); ?>';
82
+ var b2s_calendar_formats = <?php echo json_encode(array('post' => array(esc_html__('Link Post', 'blog2social'), esc_html__('Image Post', 'blog2social')), 'image' => array(esc_html__('Image with frame', 'blog2social'), esc_html__('Image cut out', 'blog2social')))); ?>;
83
+ var b2s_is_calendar = true;
84
+ </script>
85
+ </div>
86
+ </div>
87
+ <?php
88
+ $noLegendCalender=1;
89
+ require_once (B2S_PLUGIN_DIR . 'views/b2s/html/footer.php');
90
+ ?>
91
+ </div>
92
+ </div>
93
+ </div>
94
+ </div>
95
+ </div>
96
+ </div>
97
+
98
+ <input type="hidden" id="b2sLang" value="<?php echo esc_attr(substr(B2S_LANGUAGE, 0, 2)); ?>">
99
+ <input type="hidden" id="b2sUserTimeFormat" value="<?php echo esc_attr($optionUserTimeFormat); ?>">
100
+ <input type="hidden" id="b2sJSTextAddPost" value="<?php esc_html_e("add post", "blog2social"); ?>">
101
+ <input type="hidden" id="b2sUserLang" value="<?php echo esc_attr(strtolower(substr(get_locale(), 0, 2))); ?>">
102
+ <input type='hidden' id="user_timezone" name="user_timezone" value="<?php echo esc_attr($userTimeZoneOffset); ?>">
103
+ <input type="hidden" id="user_version" name="user_version" value="<?php echo esc_attr(B2S_PLUGIN_USER_VERSION); ?>">
104
+ <input type="hidden" id="b2sDefaultNoImage" value="<?php echo plugins_url('/assets/images/no-image.png', B2S_PLUGIN_FILE); ?>">
105
+ <input type="hidden" id="b2sPostId" value="">
106
+ <input type="hidden" id="b2sInsertImageType" value="0">
107
+ <input type="hidden" id="isOgMetaChecked" value="<?php echo (isset($metaSettings['og_active']) ? (int) $metaSettings['og_active'] : 0); ?>">
108
+ <input type="hidden" id="isCardMetaChecked" value="<?php echo (isset($metaSettings['card_active']) ? (int) $metaSettings['card_active'] : 0); ?>">
109
+ <input type="hidden" id="b2sRedirectUrlContentCuration" value="<?php echo esc_url(get_option('siteurl') . ((substr(get_option('siteurl'), -1, 1) == '/') ? '' : '/') . 'wp-admin/admin.php?page=blog2social-curation'); ?>">
110
+ <input type="hidden" id="b2sNotAllowGif" value="<?php echo esc_attr(implode(";", json_decode(B2S_PLUGIN_NETWORK_NOT_ALLOW_GIF, true))); ?>">
111
+ <input type="hidden" id="b2sAnimateGif" value='<?php echo esc_attr(B2S_PLUGIN_NETWORK_ANIMATE_GIF); ?>'>
112
+ <input type="hidden" id="ogMetaNetworks" value="<?php echo esc_attr(implode(';', json_decode(B2S_PLUGIN_NETWORK_META_TAGS, true)['og'])); ?>">
113
+ <input type="hidden" id="b2sEmojiTranslation" value='<?php echo esc_attr(json_encode(B2S_Tools::getEmojiTranslationList())); ?>'>
114
+ <!--Routing from dashboard-->
115
+ <input type="hidden" id="b2s_rfd" value="<?php echo (isset($_GET['rfd'])) ? 1 : 0; ?>">
116
+ <input type="hidden" id="b2s_rfd_b2s_id" value="<?php echo (isset($_GET['b2s_id'])) ? esc_attr($_GET['b2s_id']) : ""; ?>">
117
+
118
+ <div id="b2s-post-ship-item-post-format-modal" class="modal fade" role="dialog" aria-labelledby="b2s-post-ship-item-post-format-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
119
+ <div class="modal-dialog modal-lg">
120
+ <div class="modal-content">
121
+ <div class="modal-header">
122
+ <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-post-ship-item-post-format-modal">&times;</button>
123
+ <h4 class="modal-title"><?php esc_html_e('Choose your', 'blog2social') ?> <span id="b2s-post-ship-item-post-format-network-title"></span> <?php esc_html_e('Post Format', 'blog2social') ?>
124
+ <?php if (B2S_PLUGIN_USER_VERSION >= 2) { ?>
125
+ <?php esc_html_e('for:', 'blog2social') ?> <span id="b2s-post-ship-item-post-format-network-display-name"></span>
126
+ <?php } ?>
127
+ </h4>
128
+ </div>
129
+ <div class="modal-body">
130
+ <div class="row">
131
+ <div class="col-xs-12">
132
+ <?php
133
+ $settingsItem = new B2S_Settings_Item();
134
+ echo wp_kses($settingsItem->setNetworkSettingsHtml(), array(
135
+ 'input' => array(
136
+ 'type' => array(),
137
+ 'class' => array(),
138
+ 'value' => array(),
139
+ 'data-post-format-type' => array(),
140
+ 'data-network-id' => array(),
141
+ 'data-network-type' => array()
142
+ )
143
+ ));
144
+ echo wp_kses($settingsItem->getNetworkSettingsHtml(), array(
145
+ 'div' => array(
146
+ 'class' => array(),
147
+ 'data-post-format-type' => array(),
148
+ 'data-network-type' => array(),
149
+ 'data-network-id' => array(),
150
+ 'data-network-title' => array(),
151
+ 'style' => array()
152
+ ),
153
+ 'b' => array(),
154
+ 'br' => array(),
155
+ 'a' => array(
156
+ 'target' => array(),
157
+ 'href' => array()
158
+ ),
159
+ 'hr' => array(),
160
+ 'span' => array(
161
+ 'class' => array()
162
+ ),
163
+ 'label' => array(),
164
+ 'input' => array(
165
+ 'type' => array(),
166
+ 'name' => array(),
167
+ 'value' => array(),
168
+ 'class' => array(),
169
+ 'data-post-wp-type' => array(),
170
+ 'data-post-format-type' => array(),
171
+ 'data-network-type' => array(),
172
+ 'data-network-id' => array(),
173
+ 'data-post-format' => array()
174
+ ),
175
+ 'img' => array(
176
+ 'class' => array(),
177
+ 'src' => array()
178
+ )
179
+ ));
180
+ ?>
181
+ </div>
182
+ </div>
183
+ <div class="row">
184
+ <div class="col-xs-12">
185
+ <div class="text-center">
186
+ <br>
187
+ <div class="b2s-post-format-settings-info" data-network-id="1" style="display:none;">
188
+ <b><?php esc_html_e('Define the default settings for the custom post format for all of your Facebook accounts in the Blog2Social settings.', 'blog2social'); ?></b>
189
+ </div>
190
+ <div class="b2s-post-format-settings-info" data-network-id="2" style="display:none;">
191
+ <b><?php esc_html_e('Define the default settings for the custom post format for all of your Twitter accounts in the Blog2Social settings.', 'blog2social'); ?></b>
192
+ </div>
193
+ <div class="b2s-post-format-settings-info" data-network-id="3" style="display:none;">
194
+ <b><?php esc_html_e('Define the default settings for the custom post format for all of your LinkedIn accounts in the Blog2Social settings.', 'blog2social'); ?></b>
195
+ </div>
196
+ <div class="b2s-post-format-settings-info" data-network-id="12" style="display:none;">
197
+ <b><?php esc_html_e('Define the default settings for the custom post format for all of your Instagram accounts in the Blog2Social settings.', 'blog2social'); ?></b>
198
+ </div>
199
+ </div>
200
+ </div>
201
+ </div>
202
+ </div>
203
+ </div>
204
+ </div>
205
+ </div>
206
+
207
+ <div id="b2s-network-select-image" class="modal fade" role="dialog" aria-labelledby="b2s-network-select-image" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
208
+ <div class="modal-dialog modal-lg">
209
+ <div class="modal-content">
210
+ <div class="modal-header">
211
+ <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-network-select-image">&times;</button>
212
+ <h4 class="modal-title"><?php esc_html_e('Select image for', 'blog2social') ?> <span class="b2s-selected-network-for-image-info"></span></h4>
213
+ </div>
214
+ <div class="modal-body">
215
+ <div class="row">
216
+ <div class="col-xs-12">
217
+ <div class="b2s-network-select-image-content"></div>
218
+ </div>
219
+ </div>
220
+ </div>
221
+ </div>
222
+ </div>
223
+ </div>
224
+
225
+ <div id="b2s-show-post-type-modal" class="modal fade" role="dialog" aria-labelledby="b2s-show-post-type-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
226
+ <div class="modal-dialog modal-lg">
227
+ <div class="modal-content">
228
+ <div class="modal-header">
229
+ <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-show-post-type-modal">&times;</button>
230
+ <h4 class="modal-title"><?php esc_html_e('What would you like to share?', 'blog2social') ?></h4>
231
+ </div>
232
+ <div class="modal-body">
233
+ <div class="row">
234
+ <div class="col-md-6 col-xs-12">
235
+ <div class="b2s-post-type-area text-center">
236
+ <div class="image">
237
+ <img class="img-width-150" src="<?php echo plugins_url('/assets/images/b2s/blog-post-icon.png', B2S_PLUGIN_FILE); ?>" alt="blog post">
238
+ </div>
239
+ <div class="text">
240
+ <?php esc_html_e("Share your WordPress posts, pages or products", "blog2social") ?>
241
+ </div>
242
+ <div class="action">
243
+ <button class="btn btn-primary" id="b2s-btn-select-blog-post"><?php esc_html_e("select", "blog2social"); ?></button>
244
+ </div>
245
+ </div>
246
+ </div>
247
+ <div class="col-md-6 col-xs-12">
248
+ <div class="b2s-post-type-area text-center">
249
+ <div class="image">
250
+ <img class="img-width-150" src="<?php echo plugins_url('/assets/images/b2s/content-curation-icon.png', B2S_PLUGIN_FILE); ?>" alt="content curation">
251
+ </div>
252
+ <div class="text">
253
+ <?php esc_html_e("Create or share content from other sources", "blog2social") ?>
254
+ </div>
255
+ <div class="action">
256
+ <button class="btn btn-primary" id="b2s-btn-select-content-curation"><?php esc_html_e("select", "blog2social"); ?></button>
257
+ </div>
258
+ </div>
259
+ </div>
260
+ <input type="hidden" id="b2sSelSchedDate" value="">
261
+
262
+ </div>
263
+ </div>
264
+ </div>
265
+ </div>
266
+ </div>
267
+
268
+
269
+ <div id="b2s-show-post-all-modal" class="modal fade" role="dialog" aria-labelledby="b2s-post-all-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
270
+ <div class="modal-dialog modal-lg">
271
+ <div class="modal-content">
272
+ <div class="modal-header">
273
+ <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-show-post-all-modal">&times;</button>
274
+ <h4 class="modal-title"><?php esc_html_e('Select a post', 'blog2social') ?></h4>
275
+ </div>
276
+ <div class="modal-body">
277
+ <div class="row">
278
+ <div class="col-xs-12">
279
+ <div class="b2s-all-post-content">
280
+ <div class="b2s-post">
281
+ <div class="grid-body">
282
+ <div class="hidden-lg hidden-md hidden-sm filterShow"><a href="#" onclick="showFilter('show');return false;"><i class="glyphicon glyphicon-chevron-down"></i><?php esc_html_e('filter', 'blog2social') ?></a></div>
283
+ <div class="hidden-lg hidden-md hidden-sm filterHide"><a href="#" onclick="showFilter('hide');return false;"><i class="glyphicon glyphicon-chevron-up"></i><?php esc_html_e('filter', 'blog2social') ?></a></div>
284
+ <form class="b2sSortForm form-inline pull-left" action="#">
285
+ <input id="b2sType" type="hidden" value="all" name="b2sType">
286
+ <input id="b2sShowByDate" type="hidden" value="" name="b2sShowByDate">
287
+ <input id="b2sPagination" type="hidden" value="1" name="b2sPagination">
288
+ <?php
289
+ $postFilter = new B2S_Post_Filter('all');
290
+ echo $postFilter->getItemHtml();
291
+ ?>
292
+ </form>
293
+ </div>
294
+ </div>
295
+ <div class="clearfix"></div>
296
+ <div class="b2s-loading-area" style="display:none">
297
+ <br>
298
+ <div class="b2s-loader-impulse b2s-loader-impulse-md"></div>
299
+ <div class="clearfix"></div>
300
+ <div class="text-center b2s-loader-text"><?php esc_html_e("Loading...", "blog2social"); ?></div>
301
+ </div>
302
+ <div class="clearfix"></div>
303
+ <br>
304
+ <ul class="list-group b2s-sort-result-item-area"></ul>
305
+ <br>
306
+ <nav class="b2s-sort-pagination-area text-center"></nav>
307
+ </div>
308
+ </div>
309
+ </div>
310
+ </div>
311
+ </div>
312
+ </div>
313
+ </div>
314
+
315
+
316
+ <div id="b2s-sched-post-modal" class="modal fade" role="dialog" aria-labelledby="b2s-sched-post-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
317
+ <div class="modal-dialog">
318
+ <div class="modal-content">
319
+ <div class="modal-header">
320
+ <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-sched-post-modal">&times;</button>
321
+ <h4 class="modal-title"><?php esc_html_e('Need to schedule your posts?', 'blog2social') ?></h4>
322
+ </div>
323
+ <div class="modal-body">
324
+ <p><?php esc_html_e('Blog2Social Premium covers everything you need.', 'blog2social') ?></p>
325
+ <br>
326
+ <div class="clearfix"></div>
327
+ <b><?php esc_html_e('Schedule for specific dates', 'blog2social') ?></b>
328
+ <p><?php esc_html_e('You want to publish a post on a specific date? No problem! Just enter your desired date and you are ready to go!', 'blog2social') ?></p>
329
+ <br>
330
+ <b><?php esc_html_e('Schedule post recurrently', 'blog2social') ?></b>
331
+ <p><?php esc_html_e('You have evergreen content you want to re-share from time to time in your timeline? Schedule your evergreen content to be shared once, multiple times or recurringly at specific times.', 'blog2social') ?></p>
332
+ <br>
333
+ <b><?php esc_html_e('Best Time Scheduler', 'blog2social') ?></b>
334
+ <p><?php esc_html_e('Whenever you publish a post, only a fraction of your followers will actually see your post. Use the Blog2Social Best Times Scheduler to share your post at the best times for each social network. Get more outreach and extend the lifespan of your posts.', 'blog2social') ?></p>
335
+ <br>
336
+ <?php if (B2S_PLUGIN_USER_VERSION == 0) { ?>
337
+ <hr>
338
+ <?php esc_html_e('With Blog2Social Premium you can:', 'blog2social') ?>
339
+ <br>
340
+ <br>
341
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Post on pages and groups', 'blog2social') ?><br>
342
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Share on multiple profiles, pages and groups', 'blog2social') ?><br>
343
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Auto-post and auto-schedule new and updated blog posts', 'blog2social') ?><br>
344
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Schedule your posts at the best times on each network', 'blog2social') ?><br>
345
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Best Time Manager: use predefined best time scheduler to auto-schedule your social media posts', 'blog2social') ?><br>
346
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Schedule your post for one time, multiple times or recurrently', 'blog2social') ?><br>
347
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Schedule and re-share old posts', 'blog2social') ?><br>
348
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Select link format or image format for your posts', 'blog2social') ?><br>
349
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Select individual images per post', 'blog2social') ?><br>
350
+ <span class="glyphicon glyphicon-ok glyphicon-success"></span> <?php esc_html_e('Reporting & calendar: keep track of your published and scheduled social media posts', 'blog2social') ?><br>
351
+ <br>
352
+ <a target="_blank" href="<?php echo esc_url(B2S_Tools::getSupportLink('affiliate')); ?>" class="btn btn-success center-block"><?php esc_html_e('Upgrade to SMART and above', 'blog2social') ?></a>
353
+ <br>
354
+ <center> <?php echo sprintf(__('or <a target="_blank" href="%s">start with free 30-days-trial of Blog2Social Premium</a> (no payment information needed)', 'blog2social'), esc_url('https://service.blog2social.com/trial')); ?> </center>
355
+ <?php } ?>
356
+ </div>
357
+ </div>
358
+ </div>
359
+ </div>
360
+
361
+ <div id="b2s-show-error-modal" class="modal fade" role="dialog" aria-labelledby="b2s-show-error-modal" aria-hidden="true" data-backdrop="false" style="display:none;z-index: 1070;">
362
+ <div class="modal-dialog modal-lg">
363
+ <div class="modal-content">
364
+ <div class="modal-header">
365
+ <button type="button" class="b2s-modal-close close" data-modal-name="#b2s-show-error-modal">&times;</button>
366
+ <h4 class="modal-title"><?php esc_html_e('Notification', 'blog2social') ?></h4>
367
+ </div>
368
+ <div class="modal-body">
369
+ <div class="row">
370
+ <div class="col-xs-12">
371
+ <div class="alert alert-danger b2s-error-text"></div>
372
+ </div>
373
+ </div>
374
+ </div>
375
+ </div>
376
+ </div>
377
+ </div>
378
+
379
+ <div id="b2sImageZoomModal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="b2sImageZoomModal" aria-hidden="true" data-backdrop="false" style="display:none;">
380
+ <div class="modal-dialog">
381
+ <div class="modal-content">
382
+ <div class="modal-body">
383
+ <button type="button" class="btn btn-primary btn-circle b2sImageZoomModalClose b2s-modal-close close" data-modal-name="#b2sImageZoomModal" aria-label="Close"><i class="glyphicon glyphicon-remove"></i></button>
384
+ <img id="b2sImageZoom">
385
+ </div>
386
+ </div>
387
+ </div>
388
  </div>
views/b2s/post.notice.php CHANGED
@@ -4,7 +4,7 @@ wp_nonce_field('b2s_security_nonce', 'b2s_security_nonce');
4
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
5
  require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
6
  require_once(B2S_PLUGIN_DIR . 'includes/Options.php');
7
- $b2sShowByDate = isset($_GET['b2sShowByDate']) ? (preg_match("#^[0-9\-.\]]+$#", trim($_GET['b2sShowByDate'])) ? trim($_GET['b2sShowByDate']) : "") : ""; //YYYY-mm-dd
8
  $options = new B2S_Options(B2S_PLUGIN_BLOG_USER_ID);
9
  $options->_setOption('lastNotificationUpdate', date('Y-m-d H:i:s'));
10
  ?>
4
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
5
  require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
6
  require_once(B2S_PLUGIN_DIR . 'includes/Options.php');
7
+ $b2sShowByDate = isset($_GET['b2sShowByDate']) ? (preg_match("#^[0-9\-.\]]+$#", trim($_GET['b2sShowByDate'])) ? trim(sanitize_text_field(wp_unslash($_GET['b2sShowByDate']))) : "") : ""; //YYYY-mm-dd
8
  $options = new B2S_Options(B2S_PLUGIN_BLOG_USER_ID);
9
  $options->_setOption('lastNotificationUpdate', date('Y-m-d H:i:s'));
10
  ?>
views/b2s/post.publish.php CHANGED
@@ -3,7 +3,7 @@ wp_nonce_field('b2s_security_nonce', 'b2s_security_nonce');
3
  /* Data */
4
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
5
  require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
6
- $b2sShowByDate = isset($_GET['b2sShowByDate']) ? (preg_match("#^[0-9\-.\]]+$#", trim($_GET['b2sShowByDate'])) ? trim($_GET['b2sShowByDate']) : "") : ""; //YYYY-mm-dd
7
  ?>
8
 
9
  <div class="b2s-container">
3
  /* Data */
4
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
5
  require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
6
+ $b2sShowByDate = isset($_GET['b2sShowByDate']) ? (preg_match("#^[0-9\-.\]]+$#", trim($_GET['b2sShowByDate'])) ? trim(sanitize_text_field(wp_unslash($_GET['b2sShowByDate']))) : "") : ""; //YYYY-mm-dd
7
  ?>
8
 
9
  <div class="b2s-container">
views/b2s/post.sched.php CHANGED
@@ -191,10 +191,10 @@ $metaSettings = get_option('B2S_PLUGIN_GENERAL_OPTIONS');
191
 
192
 
193
  <input type="hidden" id="b2sLang" value="<?php echo substr(B2S_LANGUAGE, 0, 2); ?>">
194
- <input type="hidden" id="b2sUserTimeFormat" value="<?php echo $optionUserTimeFormat; ?>">
195
  <input type="hidden" id="b2sJSTextAddPost" value="<?php echo esc_html_e("add post", "blog2social"); ?>">
196
  <input type="hidden" id="b2sUserLang" value="<?php echo strtolower(substr(get_locale(), 0, 2)); ?>">
197
- <input type='hidden' id="user_timezone" name="user_timezone" value="<?php echo $userTimeZoneOffset; ?>">
198
  <input type="hidden" id="user_version" name="user_version" value="<?php echo B2S_PLUGIN_USER_VERSION; ?>">
199
  <input type="hidden" id="b2sDefaultNoImage" value="<?php echo plugins_url('/assets/images/no-image.png', B2S_PLUGIN_FILE); ?>">
200
  <input type="hidden" id="b2sPostId" value="">
191
 
192
 
193
  <input type="hidden" id="b2sLang" value="<?php echo substr(B2S_LANGUAGE, 0, 2); ?>">
194
+ <input type="hidden" id="b2sUserTimeFormat" value="<?php echo esc_attr($optionUserTimeFormat); ?>">
195
  <input type="hidden" id="b2sJSTextAddPost" value="<?php echo esc_html_e("add post", "blog2social"); ?>">
196
  <input type="hidden" id="b2sUserLang" value="<?php echo strtolower(substr(get_locale(), 0, 2)); ?>">
197
+ <input type='hidden' id="user_timezone" name="user_timezone" value="<?php echo esc_attr($userTimeZoneOffset); ?>">
198
  <input type="hidden" id="user_version" name="user_version" value="<?php echo B2S_PLUGIN_USER_VERSION; ?>">
199
  <input type="hidden" id="b2sDefaultNoImage" value="<?php echo plugins_url('/assets/images/no-image.png', B2S_PLUGIN_FILE); ?>">
200
  <input type="hidden" id="b2sPostId" value="">
views/b2s/ship.php CHANGED
@@ -71,13 +71,13 @@ $draftIncompleteModal = false;
71
  <a href="#" class="btn btn-primary btn-xs b2s-get-settings-sched-time-user">
72
  <?php } else { ?>
73
  <a href="#" class="btn btn-primary btn-xs b2s-btn-disabled b2sPreFeatureModalBtn" data-title="<?php esc_html_e('You want to load your time settings?', 'blog2social') ?>">
74
- <?php } esc_html_e('Load My Times Settings', 'blog2social'); ?> <?php echo $isPremium; ?></a>
75
 
76
  <?php if (B2S_PLUGIN_USER_VERSION > 0) { ?>
77
  <a href="#" class="btn btn-primary btn-xs b2s-get-settings-sched-time-default">
78
  <?php } else { ?>
79
  <a href="#" class="btn btn-primary btn-xs b2s-btn-disabled b2s-get-settings-sched-time-open-modal b2sPreFeatureModalBtn" data-title="<?php esc_html_e('You want to schedule your posts and use the Best Time Scheduler?', 'blog2social') ?>">
80
- <?php } esc_html_e('Load Best Times', 'blog2social'); ?> <?php echo $isPremium; ?></a>
81
  <a href="#" class="btn btn-link btn-xs hidden-sm b2s-load-settings-sched-time-default-info b2sInfoSchedTimesModalBtn"><?php echo esc_html_e('Info', 'blog2social'); ?></a>
82
  </div>
83
  </div>
@@ -256,7 +256,7 @@ $draftIncompleteModal = false;
256
  <input type="hidden" id="user_version" name="user_version" value="<?php echo B2S_PLUGIN_USER_VERSION; ?>">
257
  <input type="hidden" id="action" name="action" value="b2s_save_ship_data">
258
  <input type='hidden' id='post_id' name="post_id" value='<?php echo (int) esc_attr($_GET['postId']); ?>'>
259
- <input type='hidden' id='user_timezone' name="user_timezone" value="<?php echo $userTimeZoneOffset; ?>">
260
  <input type='hidden' id='user_timezone_text' name="user_timezone_text" value="<?php echo esc_html_e('Time zone', 'blog2social') . ': (UTC ' . B2S_Util::humanReadableOffset($userTimeZoneOffset) . ') ' . $userTimeZone ?>">
261
  <input type='hidden' id="default_titel" name="default_titel" value="<?php echo addslashes(B2S_Util::getTitleByLanguage($postData->post_title, $userLang)); ?>">
262
  <input type="hidden" id="b2sChangeOgMeta" name="change_og_meta" value="0">
@@ -278,7 +278,7 @@ $draftIncompleteModal = false;
278
  <?php } else { ?>
279
  <a href="#" class="btn btn-primary b2s-btn-disabled b2sPreFeatureModalBtn" data-title="You want to re-share your blog post?"><?php esc_html_e('Re-share this post', 'blog2social') ?> <?php echo $isPremium; ?></a>
280
  <?php } ?>
281
- <a class="btn btn-primary" href="<?php echo $allPosts; ?>"><?php esc_html_e('Share new post on Social Media', 'blog2social') ?></a>
282
  </div>
283
  </div>
284
  </div>
71
  <a href="#" class="btn btn-primary btn-xs b2s-get-settings-sched-time-user">
72
  <?php } else { ?>
73
  <a href="#" class="btn btn-primary btn-xs b2s-btn-disabled b2sPreFeatureModalBtn" data-title="<?php esc_html_e('You want to load your time settings?', 'blog2social') ?>">
74
+ <?php } esc_html_e('Load My Times Settings', 'blog2social'); ?> <?php echo wp_kses($isPremium, array('span' => array('class' => array()))); ?></a>
75
 
76
  <?php if (B2S_PLUGIN_USER_VERSION > 0) { ?>
77
  <a href="#" class="btn btn-primary btn-xs b2s-get-settings-sched-time-default">
78
  <?php } else { ?>
79
  <a href="#" class="btn btn-primary btn-xs b2s-btn-disabled b2s-get-settings-sched-time-open-modal b2sPreFeatureModalBtn" data-title="<?php esc_html_e('You want to schedule your posts and use the Best Time Scheduler?', 'blog2social') ?>">
80
+ <?php } esc_html_e('Load Best Times', 'blog2social'); ?> <?php echo wp_kses($isPremium, array('span' => array('class' => array()))); ?></a>
81
  <a href="#" class="btn btn-link btn-xs hidden-sm b2s-load-settings-sched-time-default-info b2sInfoSchedTimesModalBtn"><?php echo esc_html_e('Info', 'blog2social'); ?></a>
82
  </div>
83
  </div>
256
  <input type="hidden" id="user_version" name="user_version" value="<?php echo B2S_PLUGIN_USER_VERSION; ?>">
257
  <input type="hidden" id="action" name="action" value="b2s_save_ship_data">
258
  <input type='hidden' id='post_id' name="post_id" value='<?php echo (int) esc_attr($_GET['postId']); ?>'>
259
+ <input type='hidden' id='user_timezone' name="user_timezone" value="<?php echo esc_attr($userTimeZoneOffset); ?>">
260
  <input type='hidden' id='user_timezone_text' name="user_timezone_text" value="<?php echo esc_html_e('Time zone', 'blog2social') . ': (UTC ' . B2S_Util::humanReadableOffset($userTimeZoneOffset) . ') ' . $userTimeZone ?>">
261
  <input type='hidden' id="default_titel" name="default_titel" value="<?php echo addslashes(B2S_Util::getTitleByLanguage($postData->post_title, $userLang)); ?>">
262
  <input type="hidden" id="b2sChangeOgMeta" name="change_og_meta" value="0">
278
  <?php } else { ?>
279
  <a href="#" class="btn btn-primary b2s-btn-disabled b2sPreFeatureModalBtn" data-title="You want to re-share your blog post?"><?php esc_html_e('Re-share this post', 'blog2social') ?> <?php echo $isPremium; ?></a>
280
  <?php } ?>
281
+ <a class="btn btn-primary" href="<?php echo esc_url($allPosts); ?>"><?php esc_html_e('Share new post on Social Media', 'blog2social') ?></a>
282
  </div>
283
  </div>
284
  </div>
views/b2s/widgets/calendar.php CHANGED
@@ -17,11 +17,11 @@ if($optionUserTimeFormat == false) {
17
  $metaSettings = get_option('B2S_PLUGIN_GENERAL_OPTIONS');
18
  ?>
19
  <input type="hidden" id="b2sLang" value="<?php echo substr(B2S_LANGUAGE, 0, 2); ?>">
20
- <input type="hidden" id="b2sUserTimeFormat" value="<?php echo $optionUserTimeFormat; ?>">
21
  <input type="hidden" id="b2sJSTextAddPost" value="<?php esc_html_e("add post", "blog2social"); ?>">
22
  <input type="hidden" id="b2sUserLang" value="<?php echo strtolower(substr(get_locale(), 0, 2)); ?>">
23
- <input type='hidden' id="user_timezone" name="user_timezone" value="<?php echo $userTimeZoneOffset; ?>">
24
- <input type="hidden" id="user_version" name="user_version" value="<?php echo B2S_PLUGIN_USER_VERSION; ?>">
25
  <input type="hidden" id="b2sDefaultNoImage" value="<?php echo plugins_url('/assets/images/no-image.png', B2S_PLUGIN_FILE); ?>">
26
  <input type="hidden" id="b2sPostId" value="">
27
  <input type="hidden" id="b2sInsertImageType" value="0">
17
  $metaSettings = get_option('B2S_PLUGIN_GENERAL_OPTIONS');
18
  ?>
19
  <input type="hidden" id="b2sLang" value="<?php echo substr(B2S_LANGUAGE, 0, 2); ?>">
20
+ <input type="hidden" id="b2sUserTimeFormat" value="<?php echo esc_attr($optionUserTimeFormat); ?>">
21
  <input type="hidden" id="b2sJSTextAddPost" value="<?php esc_html_e("add post", "blog2social"); ?>">
22
  <input type="hidden" id="b2sUserLang" value="<?php echo strtolower(substr(get_locale(), 0, 2)); ?>">
23
+ <input type='hidden' id="user_timezone" name="user_timezone" value="<?php echo esc_attr($userTimeZoneOffset); ?>">
24
+ <input type="hidden" id="user_version" name="user_version" value="<?php echo esc_attr(B2S_PLUGIN_USER_VERSION); ?>">
25
  <input type="hidden" id="b2sDefaultNoImage" value="<?php echo plugins_url('/assets/images/no-image.png', B2S_PLUGIN_FILE); ?>">
26
  <input type="hidden" id="b2sPostId" value="">
27
  <input type="hidden" id="b2sInsertImageType" value="0">
views/b2s/widgets/newsletter.php CHANGED
@@ -5,7 +5,7 @@ $updateMail = get_option('B2S_UPDATE_MAIL_' . B2S_PLUGIN_BLOG_USER_ID);
5
  <div class="form-inline">
6
  <label class="b2s-text-xl b2s-color-grey"><?php esc_html_e("Get Social Media News", "blog2social") ?></label>
7
  <div class="input-group input-group-sm">
8
- <input id="b2s-mail-update-input" class="form-control" name="b2sMailUpdate" value="<?php echo $wpUserData->user_email; ?>" placeholder="E-Mail" type="text">
9
  <span class="input-group-btn">
10
  <button class="btn btn-primary b2s-mail-btn"><?php esc_html_e('subscribe', 'blog2social') ?></button>
11
  </span>
5
  <div class="form-inline">
6
  <label class="b2s-text-xl b2s-color-grey"><?php esc_html_e("Get Social Media News", "blog2social") ?></label>
7
  <div class="input-group input-group-sm">
8
+ <input id="b2s-mail-update-input" class="form-control" name="b2sMailUpdate" value="<?php echo esc_html($wpUserData->user_email); ?>" placeholder="E-Mail" type="text">
9
  <span class="input-group-btn">
10
  <button class="btn btn-primary b2s-mail-btn"><?php esc_html_e('subscribe', 'blog2social') ?></button>
11
  </span>
views/b2s/widgets/posts.php CHANGED
@@ -2,7 +2,7 @@
2
  /* Data */
3
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
4
  require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
5
- $b2sShowByDate = isset($_GET['b2sShowByDate']) ? trim($_GET['b2sShowByDate']) : "";
6
  ?>
7
 
8
  <div>
@@ -22,7 +22,7 @@ $b2sShowByDate = isset($_GET['b2sShowByDate']) ? trim($_GET['b2sShowByDate']) :
22
  <!-- Filter Post Start-->
23
  <form class="b2sSortForm form-inline pull-left" action="#">
24
  <input id="b2sType" type="hidden" value="all" name="b2sType">
25
- <input id="b2sShowByDate" type="hidden" value="<?php echo $b2sShowByDate; ?>" name="b2sShowByDate">
26
  <input id="b2sPagination" type="hidden" value="0" name="b2sPagination">
27
  <input id="b2sShowPagination" type="hidden" value="0" name="b2sShowPagination">
28
  <input id="b2sPostsPerPage" type="hidden" value="3" name="b2sPostsPerPage">
2
  /* Data */
3
  require_once (B2S_PLUGIN_DIR . 'includes/B2S/Post/Filter.php');
4
  require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
5
+ $b2sShowByDate = isset($_GET['b2sShowByDate']) ? trim(sanitize_text_field(wp_unslash($_GET['b2sShowByDate']))) : "";
6
  ?>
7
 
8
  <div>
22
  <!-- Filter Post Start-->
23
  <form class="b2sSortForm form-inline pull-left" action="#">
24
  <input id="b2sType" type="hidden" value="all" name="b2sType">
25
+ <input id="b2sShowByDate" type="hidden" value="<?php echo esc_attr($b2sShowByDate); ?>" name="b2sShowByDate">
26
  <input id="b2sPagination" type="hidden" value="0" name="b2sPagination">
27
  <input id="b2sShowPagination" type="hidden" value="0" name="b2sShowPagination">
28
  <input id="b2sPostsPerPage" type="hidden" value="3" name="b2sPostsPerPage">
views/prg/post.php CHANGED
@@ -7,7 +7,7 @@ require_once (B2S_PLUGIN_DIR . 'includes/Util.php');
7
  /* Sort */
8
  $currentPage = isset($_GET['b2sPage']) ? (int) $_GET['b2sPage'] : 1;
9
  $prgSortPostType = isset($_GET['prgSortPostType']) ? trim(sanitize_text_field($_GET['prgSortPostType'])) : "";
10
- $prgSortPostStatus = isset($_GET['prgSortPostStatus']) ? (in_array(trim($_GET['prgSortPostStatus']), array('publish', 'future', 'pending')) ? trim($_GET['prgSortPostStatus']) : "") : "";
11
  $prgSortPostTitle = isset($_GET['prgSortPostTitle']) ? trim(sanitize_text_field($_GET['prgSortPostTitle'])) : "";
12
  $prgSortPostAuthor = isset($_GET['prgSortPostAuthor']) ? (int) $_GET['prgSortPostAuthor'] : 0;
13
  $prgUserLang = strtolower(substr(get_locale(), 0, 2));
7
  /* Sort */
8
  $currentPage = isset($_GET['b2sPage']) ? (int) $_GET['b2sPage'] : 1;
9
  $prgSortPostType = isset($_GET['prgSortPostType']) ? trim(sanitize_text_field($_GET['prgSortPostType'])) : "";
10
+ $prgSortPostStatus = isset($_GET['prgSortPostStatus']) ? (in_array(trim($_GET['prgSortPostStatus']), array('publish', 'future', 'pending')) ? trim(sanitize_text_field(wp_unslash($_GET['prgSortPostStatus']))) : "") : "";
11
  $prgSortPostTitle = isset($_GET['prgSortPostTitle']) ? trim(sanitize_text_field($_GET['prgSortPostTitle'])) : "";
12
  $prgSortPostAuthor = isset($_GET['prgSortPostAuthor']) ? (int) $_GET['prgSortPostAuthor'] : 0;
13
  $prgUserLang = strtolower(substr(get_locale(), 0, 2));
views/prg/ship.php CHANGED
@@ -62,8 +62,8 @@ $prgInfo = get_option('B2S_PLUGIN_PRG_' . B2S_PLUGIN_BLOG_USER_ID);
62
  <input type ="hidden" value="0" name="confirm" id="confirm">
63
  <input type ="hidden" value="<?php echo esc_attr(B2S_PLUGIN_BLOG_USER_ID); ?>" id="blog_user_id" name="blog_user_id">
64
  <input type ="hidden" value="<?php echo esc_attr($postData->ID); ?>" id="post_id" name="post_id">
65
- <input type ="hidden" id="token" name="token" value="<?php echo esc_attr((isset($prgInfo['B2S_PRG_TOKEN']) && !empty($prgInfo['B2S_PRG_TOKEN'])) ? $prgInfo['B2S_PRG_TOKEN'] : 0); ?>">
66
- <input type ="hidden" id="prg_id" name="prg_id" value="<?php echo esc_attr((isset($prgInfo['B2S_PRG_ID']) && !empty($prgInfo['B2S_PRG_ID'])) ? $prgInfo['B2S_PRG_ID'] : 0); ?>">
67
  <div class = "pull-right">
68
  <button type = "submit" class = "btn btn-warning btn-lg draft checkPRGButton" disabled = "disabled"><?php esc_html_e('Save As Draft', 'blog2social') ?></button>
69
  <button class = "btn btn-warning btn-lg checkPRGButton publish" disabled = "disabled"><?php esc_html_e('Publish', 'blog2social') ?></button>
62
  <input type ="hidden" value="0" name="confirm" id="confirm">
63
  <input type ="hidden" value="<?php echo esc_attr(B2S_PLUGIN_BLOG_USER_ID); ?>" id="blog_user_id" name="blog_user_id">
64
  <input type ="hidden" value="<?php echo esc_attr($postData->ID); ?>" id="post_id" name="post_id">
65
+ <input type ="hidden" id="token" name="token" value="<?php echo esc_attr((isset($prgInfo['B2S_PRG_TOKEN']) && !empty($prgInfo['B2S_PRG_TOKEN'])) ? esc_attr($prgInfo['B2S_PRG_TOKEN']) : 0); ?>">
66
+ <input type ="hidden" id="prg_id" name="prg_id" value="<?php echo esc_attr((isset($prgInfo['B2S_PRG_ID']) && !empty($prgInfo['B2S_PRG_ID'])) ? esc_attr($prgInfo['B2S_PRG_ID']) : 0); ?>">
67
  <div class = "pull-right">
68
  <button type = "submit" class = "btn btn-warning btn-lg draft checkPRGButton" disabled = "disabled"><?php esc_html_e('Save As Draft', 'blog2social') ?></button>
69
  <button class = "btn btn-warning btn-lg checkPRGButton publish" disabled = "disabled"><?php esc_html_e('Publish', 'blog2social') ?></button>