Calendar by WD – Responsive Event Calendar - Version 1.5.52

Version Description

Fixed: Security issue
Added: Overview page

Download this release

Release Info

Developer webdorado
Plugin Icon 128x128 Calendar by WD – Responsive Event Calendar
Version 1.5.52
Comparing to
See all releases

Code changes from version 1.5.51 to 1.5.52

Files changed (80) hide show
  1. Theme_functions.php +9 -4
  2. Themes_function.html.php +2 -24
  3. calendar.php +255 -30
  4. calendar_functions.html.php +88 -107
  5. calendar_functions.php +49 -26
  6. elements/calendar-jos.css +86 -2
  7. images/i_support.png +0 -0
  8. notices.php +0 -33
  9. readme.txt +25 -9
  10. spider_calendar_admin_class.php +0 -47
  11. spider_calendar_notices_class.php +0 -219
  12. wd/README.md +129 -0
  13. wd/assets/css/deactivate_popup.css +86 -0
  14. wd/assets/css/img/allow&continue.png +0 -0
  15. wd/assets/css/img/coupon_bg.png +0 -0
  16. wd/assets/css/img/plugins_header_bg.png +0 -0
  17. wd/assets/css/img/skip.png +0 -0
  18. wd/assets/css/img/themes_headrer_bg.png +0 -0
  19. wd/assets/css/img/ug-icon-1.png +0 -0
  20. wd/assets/css/img/ug-icon-2.png +0 -0
  21. wd/assets/css/img/ug-icon-3.png +0 -0
  22. wd/assets/css/img/ug-icon-4.png +0 -0
  23. wd/assets/css/img/ug-icon-5.png +0 -0
  24. wd/assets/css/img/welcome_bg.png +0 -0
  25. wd/assets/css/notices.css +88 -0
  26. wd/assets/css/overview.css +455 -0
  27. wd/assets/css/subscribe.css +114 -0
  28. wd/assets/img/bwg_main_plugin.png +0 -0
  29. wd/assets/img/ecwd_main_plugin.png +0 -0
  30. wd/assets/img/faqwd_main_plugin.png +0 -0
  31. wd/assets/img/ffwd_main_plugin.png +0 -0
  32. wd/assets/img/fwd_main_plugin.png +0 -0
  33. wd/assets/img/gawd_main_plugin.png +0 -0
  34. wd/assets/img/gmwd_main_plugin.png +0 -0
  35. wd/assets/img/loader.gif +0 -0
  36. wd/assets/img/mwd_main_plugin.png +0 -0
  37. wd/assets/img/plugins/business_elite.png +0 -0
  38. wd/assets/img/plugins/business_world.png +0 -0
  39. wd/assets/img/plugins/event-calendar-wd.png +0 -0
  40. wd/assets/img/plugins/form-maker.png +0 -0
  41. wd/assets/img/plugins/photo-gallery.png +0 -0
  42. wd/assets/img/plugins/portfolio_gallery.png +0 -0
  43. wd/assets/img/plugins/sauron.png +0 -0
  44. wd/assets/img/plugins/slider-wd.png +0 -0
  45. wd/assets/img/plugins/spider-event-calendar.png +0 -0
  46. wd/assets/img/plugins/wd-google-maps.png +0 -0
  47. wd/assets/img/plugins/wd-instagram-feed.png +0 -0
  48. wd/assets/img/sp_calendar_main_plugin.png +0 -0
  49. wd/assets/img/spinner.gif +0 -0
  50. wd/assets/img/sub_1.png +0 -0
  51. wd/assets/img/sub_2.png +0 -0
  52. wd/assets/img/sub_4.png +0 -0
  53. wd/assets/img/twd_main_plugin.png +0 -0
  54. wd/assets/img/wd_ads_main_plugin.png +0 -0
  55. wd/assets/img/wde_main_plugin.png +0 -0
  56. wd/assets/img/wdi_main_plugin.png +0 -0
  57. wd/assets/img/wdps_main_plugin.png +0 -0
  58. wd/assets/img/wds_main_plugin.png +0 -0
  59. wd/assets/img/wp_logo.png +0 -0
  60. wd/assets/img/ytwd_main_plugin.png +0 -0
  61. wd/assets/js/deactivate_popup.js +104 -0
  62. wd/assets/js/overview.js +56 -0
  63. wd/assets/js/subsribe.js +36 -0
  64. wd/config.php +127 -0
  65. wd/includes/api.php +81 -0
  66. wd/includes/deactivate.php +168 -0
  67. wd/includes/notices.php +223 -0
  68. wd/includes/overview.php +310 -0
  69. wd/includes/subscribe.php +138 -0
  70. wd/start.php +41 -0
  71. wd/templates/display_deactivation_popup.php +28 -0
  72. wd/templates/display_overview.php +33 -0
  73. wd/templates/display_overview_deals.php +88 -0
  74. wd/templates/display_overview_support.php +43 -0
  75. wd/templates/display_overview_user_guide.php +46 -0
  76. wd/templates/display_overview_welcome.php +31 -0
  77. wd/templates/display_subscribe.php +47 -0
  78. wd/wd.php +146 -0
  79. widget_Theme_functions.php +11 -5
  80. widget_Themes_function.html.php +2 -25
Theme_functions.php CHANGED
@@ -9,7 +9,9 @@ if (!current_user_can('manage_options')) {
9
 
10
  function show_theme_calendar() {
11
  global $wpdb;
12
- $order = " ORDER BY title ASC";
 
 
13
  $sort["default_style"] = "manage-column column-autor sortable desc";
14
  $sort["sortid_by"] = "title";
15
  $sort["custom_style"] = "manage-column column-title sorted asc";
@@ -21,12 +23,14 @@ function show_theme_calendar() {
21
  if (isset($_POST['asc_or_desc']) && (esc_html($_POST['asc_or_desc']) == 1)) {
22
  $sort["custom_style"] = "manage-column column-title sorted asc";
23
  $sort["1_or_2"] = "2";
24
- $order = "ORDER BY " . $sort["sortid_by"] . " ASC";
 
25
  }
26
  else {
27
  $sort["custom_style"] = "manage-column column-title sorted desc";
28
  $sort["1_or_2"] = "1";
29
- $order = "ORDER BY " . $sort["sortid_by"] . " DESC";
 
30
  }
31
  if (isset($_POST['page_number']) && (esc_html($_POST['page_number']))) {
32
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number']))) - 1) * 20;
@@ -45,7 +49,7 @@ function show_theme_calendar() {
45
  $search_tag = "";
46
  }
47
  if ($search_tag) {
48
- $where = ' WHERE title LIKE "%%' . like_escape($search_tag) . '%%"';
49
  }
50
  else {
51
  $where = '';
@@ -55,6 +59,7 @@ function show_theme_calendar() {
55
  $total = $wpdb->get_var($query);
56
  $pageNav['total'] = $total;
57
  $pageNav['limit'] = $limit / 20 + 1;
 
58
  $query = $wpdb->prepare ("SELECT * FROM " . $wpdb->prefix . "spidercalendar_theme" . $where . " " . $order . " " . " LIMIT %d,20",$limit);
59
  $rows = $wpdb->get_results( $query);
60
  html_show_theme_calendar($rows, $pageNav, $sort);
9
 
10
  function show_theme_calendar() {
11
  global $wpdb;
12
+ $order = "title";
13
+ $asc_desc = "ASC";
14
+ $order_by = "";
15
  $sort["default_style"] = "manage-column column-autor sortable desc";
16
  $sort["sortid_by"] = "title";
17
  $sort["custom_style"] = "manage-column column-title sorted asc";
23
  if (isset($_POST['asc_or_desc']) && (esc_html($_POST['asc_or_desc']) == 1)) {
24
  $sort["custom_style"] = "manage-column column-title sorted asc";
25
  $sort["1_or_2"] = "2";
26
+ $order = esc_sql(esc_html($sort["sortid_by"]));
27
+ $asc_desc = "ASC";
28
  }
29
  else {
30
  $sort["custom_style"] = "manage-column column-title sorted desc";
31
  $sort["1_or_2"] = "1";
32
+ $order = esc_sql(esc_html($sort["sortid_by"]));
33
+ $asc_desc = "DESC";
34
  }
35
  if (isset($_POST['page_number']) && (esc_html($_POST['page_number']))) {
36
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number']))) - 1) * 20;
49
  $search_tag = "";
50
  }
51
  if ($search_tag) {
52
+ $where = ' WHERE title LIKE "%%' . esc_sql(esc_html($search_tag)) . '%%"';
53
  }
54
  else {
55
  $where = '';
59
  $total = $wpdb->get_var($query);
60
  $pageNav['total'] = $total;
61
  $pageNav['limit'] = $limit / 20 + 1;
62
+ if( $order == "id" || $order == "title" ) $order_by = " ORDER BY " . $order . " " . $asc_desc;
63
  $query = $wpdb->prepare ("SELECT * FROM " . $wpdb->prefix . "spidercalendar_theme" . $where . " " . $order . " " . " LIMIT %d,20",$limit);
64
  $rows = $wpdb->get_results( $query);
65
  html_show_theme_calendar($rows, $pageNav, $sort);
Themes_function.html.php CHANGED
@@ -5,30 +5,8 @@ if (!current_user_can('manage_options')) {
5
  }
6
 
7
  function html_show_theme_calendar() {
8
- global $wpdb;
9
- ?>
10
- <div class="updated" style="font-size: 14px; color:red !important">
11
- <p><strong>
12
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;"> This feature is disabled for the non-commercial version.</a>
13
- </strong></p>
14
- </div>
15
- <table width="95%">
16
- <tr>
17
- <td width="100%" style="font-size:14px; font-weight:bold">
18
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-5/5-1.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a><br />
19
- This section allows you to create/edit themes for the calendars.<br />
20
- This feature is disabled for the non-commercial version.
21
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-5/5-1.html" target="_blank" style="color:blue; text-decoration:none;">More...</a><br />
22
- Here are some examples of 12 standard templates included in the commercial version.
23
- <a href="http://wpdemo.web-dorado.com/spider-calendar/" target="_blank" style="color:blue; text-decoration:none;">Demo</a>
24
- </td>
25
- <td colspan="7" align="right" style="font-size:16px;">
26
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;">
27
- <img src="<?php echo plugins_url('images/header.png',__FILE__) ?>" border="0" alt="https://web-dorado.com/files/fromSpiderCalendarWP.php" width="215">
28
- </a>
29
- </td>
30
- </tr>
31
- </table>
32
  <br /><br />
33
  <img src="<?php echo plugins_url('images/spider_calendar_themes.png', __FILE__) ?>" />
34
  <?php
5
  }
6
 
7
  function html_show_theme_calendar() {
8
+ global $wpdb; ?>
9
+ <?php upgrade_pro_sp("themes"); ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
10
  <br /><br />
11
  <img src="<?php echo plugins_url('images/spider_calendar_themes.png', __FILE__) ?>" />
12
  <?php
calendar.php CHANGED
@@ -3,12 +3,12 @@
3
  Plugin Name: Spider Event Calendar
4
  Plugin URI: https://web-dorado.com/products/wordpress-calendar.html
5
  Description: Spider Event Calendar is a highly configurable product which allows you to have multiple organized events. Spider Event Calendar is an extraordinary user friendly extension.
6
- Version: 1.5.51
7
  Author: WebDorado
8
  Author URI: https://web-dorado.com
9
  License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
10
  */
11
- $wd_spider_calendar_version="1.5.51";
12
  // LANGUAGE localization.
13
  function sp_calendar_language_load() {
14
  load_plugin_textdomain('sp_calendar', FALSE, basename(dirname(__FILE__)) . '/languages');
@@ -22,6 +22,19 @@ function sp_cal_registr_some_scripts(){
22
  wp_register_script("Canlendar_upcoming", plugins_url("elements/calendar.js", __FILE__), array(), $wd_spider_calendar_version);
23
  wp_register_script("calendnar-setup_upcoming", plugins_url("elements/calendar-setup.js", __FILE__), array(), $wd_spider_calendar_version);
24
  wp_register_script("calenndar_function_upcoming", plugins_url("elements/calendar_function.js", __FILE__), array(), $wd_spider_calendar_version);
 
 
 
 
 
 
 
 
 
 
 
 
 
25
  }
26
 
27
  // Include widget.
@@ -532,17 +545,20 @@ function sp_calendar_register($plugin_array) {
532
 
533
  // Function create in menu.
534
  function sp_calendar_options_panel() {
535
- add_menu_page('Theme page title', 'Calendar', 'manage_options', 'SpiderCalendar', 'Manage_Spider_Calendar', plugins_url("images/calendar_menu.png", __FILE__));
 
 
536
  $page_calendar = add_submenu_page('SpiderCalendar', 'Calendars', 'Calendars', 'manage_options', 'SpiderCalendar', 'Manage_Spider_Calendar');
537
  $page_event_category = add_submenu_page('SpiderCalendar', 'Event Category', 'Event Category', 'manage_options', 'spider_calendar_event_category', 'Manage_Spider_Category_Calendar');
538
  $page_theme = add_submenu_page('SpiderCalendar', 'Calendar Parameters', 'Calendar Themes', 'manage_options', 'spider_calendar_themes', 'spider_calendar_params');
539
  $page_widget_theme = add_submenu_page('SpiderCalendar', 'Calendar Parameters', 'Widget Themes', 'manage_options', 'spider_widget_calendar_themes', 'spider_widget_calendar_params');
540
  add_submenu_page('SpiderCalendar', 'Export', 'Export', 'manage_options', 'calendar_export', 'calendar_export');
541
  add_submenu_page('SpiderCalendar', 'Get Pro', 'Get Pro', 'manage_options', 'Spider_calendar_Licensing', 'Spider_calendar_Licensing');
542
- add_submenu_page('SpiderCalendar', 'Uninstall Spider Event Calendar', 'Uninstall Spider Event Calendar', 'manage_options', 'Uninstall_sp_calendar', 'Uninstall_sp_calendar'); // uninstall Calendar
543
  add_action('admin_print_styles-' . $page_theme, 'spider_calendar_themes_admin_styles_scripts');
544
  add_action('admin_print_styles-' . $page_event_category, 'spider_calendar_event_category_admin_styles_scripts');
545
  add_action('admin_print_styles-' . $page_calendar, 'spider_calendar_admin_styles_scripts');
 
546
  add_action('admin_print_styles-' . $page_widget_theme, 'spider_widget_calendar_themes_admin_styles_scripts');
547
  }
548
 
@@ -579,6 +595,7 @@ function spider_calendar_themes_admin_styles_scripts() {
579
  wp_enqueue_style("parsetheme_css", plugins_url('style_for_cal/style_for_tables_cal.css', __FILE__), array(), $wd_spider_calendar_version);
580
  }
581
  }
 
582
  }
583
 
584
  function spider_widget_calendar_themes_admin_styles_scripts() {
@@ -600,6 +617,10 @@ function spider_calendar_admin_styles_scripts() {
600
  wp_enqueue_script("calendar-setup", plugins_url("elements/calendar-setup.js", __FILE__), array(), $wd_spider_calendar_version, FALSE);
601
  wp_enqueue_script("calendar_function", plugins_url("elements/calendar_function.js", __FILE__), array(), $wd_spider_calendar_version, FALSE);
602
  wp_enqueue_style("Css", plugins_url("elements/calendar-jos.css", __FILE__), array(), $wd_spider_calendar_version, FALSE);
 
 
 
 
603
  }
604
 
605
  function spider_calendar_event_category_admin_styles_scripts(){
@@ -608,7 +629,7 @@ function spider_calendar_event_category_admin_styles_scripts(){
608
  wp_enqueue_script("calendar-setup", plugins_url("elements/calendar-setup.js", __FILE__), array(), $wd_spider_calendar_version, FALSE);
609
  wp_enqueue_script('wp-color-picker');
610
  wp_enqueue_style( 'wp-color-picker' );
611
- wp_enqueue_style("Css", plugins_url("elements/calendar-jos.css", __FILE__), array(), $wd_spider_calendar_version, FALSE);
612
  }
613
 
614
  add_filter('admin_head', 'spide_ShowTinyMCE');
@@ -633,7 +654,145 @@ function spide_ShowTinyMCE() {
633
  }
634
 
635
  // Add menu.
636
- add_action('admin_menu', 'sp_calendar_options_panel');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
637
 
638
  require_once("functions_for_xml_and_ajax.php");
639
  require_once("front_end/bigcalendarday.php");
@@ -670,14 +829,6 @@ add_action('wp_ajax_nopriv_spidercalendarbig', 'spiderbigcalendar');
670
  add_action('wp_ajax_nopriv_spiderseemore', 'seemore');
671
  add_action('wp_ajax_nopriv_window', 'php_window');
672
 
673
- //notices
674
- if ( is_admin() && ( ! defined( 'DOING_AJAX' ) || ! DOING_AJAX ) ) {
675
- require_once( 'spider_calendar_admin_class.php' );
676
- include_once('spider_calendar_notices_class.php');
677
- require_once('notices.php');
678
- add_action( 'plugins_loaded', array( 'SC_Admin', 'get_instance' ) );
679
- }
680
-
681
 
682
  // Add style head.
683
  function add_button_style_calendar() {
@@ -951,18 +1102,21 @@ function spider_calendar_params() {
951
  }
952
  }
953
 
954
-
955
  function Uninstall_sp_calendar() {
956
- global $wpdb;
 
 
 
 
 
 
 
 
957
  $base_name = plugin_basename('Spider_Calendar');
958
  $base_page = 'admin.php?page=' . $base_name;
959
  $mode = (isset($_GET['mode']) ? trim($_GET['mode']) : '');
960
  ?>
961
- <div class="page-banner uninstall-banner">
962
- <div class="uninstall_icon">
963
- </div>
964
- <div class="logo-title">Uninstall Spider Calendar</div>
965
- </div>
966
  <br />
967
  <div class="goodbye-text">
968
  Before uninstalling the plugin, please Contact our <a href="https://web-dorado.com/support/contact-us.html?source=spidercalendar" target= '_blank'>support team</a>. We'll do our best to help you out with your issue. We value each and every user and value what’s right for our users in everything we do.<br>
@@ -1005,16 +1159,16 @@ function Uninstall_sp_calendar() {
1005
  echo '</font><br />';
1006
  echo '</p>';
1007
  echo '</form>';
1008
- $mode = 'end-UNINSTALL';
1009
-
1010
  }
1011
  }
 
1012
  switch ($mode) {
1013
  case 'end-UNINSTALL':
1014
- $deactivate_url = wp_nonce_url('plugins.php?action=deactivate&amp;plugin=' . plugin_basename(__FILE__), 'deactivate-plugin_' . plugin_basename(__FILE__));
1015
  echo '<div class="wrap">';
1016
  echo '<h2>Uninstall Spider Event Calendar</h2>';
1017
- echo '<p><strong>' . sprintf('<a href="%s">Click Here</a> To Finish The Uninstallation And Spider Event Calendar Will Be Deactivated Automatically.', $deactivate_url) . '</strong></p>';
1018
  echo '</div>';
1019
  break;
1020
  // Main Page
@@ -1031,7 +1185,7 @@ function Uninstall_sp_calendar() {
1031
  </p>
1032
 
1033
  <p style="color: red">
1034
- <strong><?php echo'WARNING:'; ?></strong><br/>
1035
  <?php echo 'Once uninstalled, this cannot be undone. You should use a Database Backup plugin of WordPress to back up all the data first.'; ?>
1036
  </p>
1037
 
@@ -1085,6 +1239,7 @@ function Uninstall_sp_calendar() {
1085
  </div>
1086
  </form>
1087
  <?php
 
1088
  }
1089
  }
1090
 
@@ -1202,13 +1357,83 @@ function spider_calendar_export() {
1202
  }
1203
  }
1204
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1205
  function calendar_export() {
1206
  ?>
 
1207
  <form method="post" style="font-size: 14px; font-weight: bold;">
1208
- <div id="export_div">
1209
- This section will allow exporting Spider Calendar data (events, calendars, categories) for further import to Event Calendar WD.
1210
- <a href="https://web-dorado.com/products/wordpress-event-calendar-wd.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
1211
- </div>
1212
  <input type='submit' value='Export' id="export_WD" name='export_spider_calendar' />
1213
  </form>
1214
  <style>
3
  Plugin Name: Spider Event Calendar
4
  Plugin URI: https://web-dorado.com/products/wordpress-calendar.html
5
  Description: Spider Event Calendar is a highly configurable product which allows you to have multiple organized events. Spider Event Calendar is an extraordinary user friendly extension.
6
+ Version: 1.5.52
7
  Author: WebDorado
8
  Author URI: https://web-dorado.com
9
  License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
10
  */
11
+ $wd_spider_calendar_version="1.5.52";
12
  // LANGUAGE localization.
13
  function sp_calendar_language_load() {
14
  load_plugin_textdomain('sp_calendar', FALSE, basename(dirname(__FILE__)) . '/languages');
22
  wp_register_script("Canlendar_upcoming", plugins_url("elements/calendar.js", __FILE__), array(), $wd_spider_calendar_version);
23
  wp_register_script("calendnar-setup_upcoming", plugins_url("elements/calendar-setup.js", __FILE__), array(), $wd_spider_calendar_version);
24
  wp_register_script("calenndar_function_upcoming", plugins_url("elements/calendar_function.js", __FILE__), array(), $wd_spider_calendar_version);
25
+
26
+ if( isset($_GET['page']) && $_GET['page'] == "Uninstall_sp_calendar" ) {
27
+ wp_enqueue_script("sp_calendar-deactivate-popup", plugins_url('wd/assets/js/deactivate_popup.js', __FILE__), array(), $wd_spider_calendar_version);
28
+ $admin_data = wp_get_current_user();
29
+
30
+ wp_localize_script( 'sp_calendar-deactivate-popup', 'sp_calendarWDDeactivateVars', array(
31
+ "prefix" => "sp_calendar" ,
32
+ "deactivate_class" => 'sp_calendar_deactivate_link',
33
+ "email" => $admin_data->data->user_email,
34
+ "plugin_wd_url" => "https://web-dorado.com/products/wordpress-google-maps-plugin.html",
35
+ ));
36
+ }
37
+
38
  }
39
 
40
  // Include widget.
545
 
546
  // Function create in menu.
547
  function sp_calendar_options_panel() {
548
+ if( get_option( "sp_calendar_subscribe_done" ) == 1 ){
549
+ add_menu_page('Theme page title', 'Calendar', 'manage_options', 'SpiderCalendar', 'Manage_Spider_Calendar', plugins_url("images/calendar_menu.png", __FILE__));
550
+ }
551
  $page_calendar = add_submenu_page('SpiderCalendar', 'Calendars', 'Calendars', 'manage_options', 'SpiderCalendar', 'Manage_Spider_Calendar');
552
  $page_event_category = add_submenu_page('SpiderCalendar', 'Event Category', 'Event Category', 'manage_options', 'spider_calendar_event_category', 'Manage_Spider_Category_Calendar');
553
  $page_theme = add_submenu_page('SpiderCalendar', 'Calendar Parameters', 'Calendar Themes', 'manage_options', 'spider_calendar_themes', 'spider_calendar_params');
554
  $page_widget_theme = add_submenu_page('SpiderCalendar', 'Calendar Parameters', 'Widget Themes', 'manage_options', 'spider_widget_calendar_themes', 'spider_widget_calendar_params');
555
  add_submenu_page('SpiderCalendar', 'Export', 'Export', 'manage_options', 'calendar_export', 'calendar_export');
556
  add_submenu_page('SpiderCalendar', 'Get Pro', 'Get Pro', 'manage_options', 'Spider_calendar_Licensing', 'Spider_calendar_Licensing');
557
+ $page_uninstall = add_submenu_page('SpiderCalendar', 'Uninstall Spider Event Calendar', 'Uninstall Spider Event Calendar', 'manage_options', 'Uninstall_sp_calendar', 'Uninstall_sp_calendar'); // uninstall Calendar
558
  add_action('admin_print_styles-' . $page_theme, 'spider_calendar_themes_admin_styles_scripts');
559
  add_action('admin_print_styles-' . $page_event_category, 'spider_calendar_event_category_admin_styles_scripts');
560
  add_action('admin_print_styles-' . $page_calendar, 'spider_calendar_admin_styles_scripts');
561
+ add_action('admin_print_styles-' . $page_uninstall, 'spider_calendar_admin_styles_scripts');
562
  add_action('admin_print_styles-' . $page_widget_theme, 'spider_widget_calendar_themes_admin_styles_scripts');
563
  }
564
 
595
  wp_enqueue_style("parsetheme_css", plugins_url('style_for_cal/style_for_tables_cal.css', __FILE__), array(), $wd_spider_calendar_version);
596
  }
597
  }
598
+
599
  }
600
 
601
  function spider_widget_calendar_themes_admin_styles_scripts() {
617
  wp_enqueue_script("calendar-setup", plugins_url("elements/calendar-setup.js", __FILE__), array(), $wd_spider_calendar_version, FALSE);
618
  wp_enqueue_script("calendar_function", plugins_url("elements/calendar_function.js", __FILE__), array(), $wd_spider_calendar_version, FALSE);
619
  wp_enqueue_style("Css", plugins_url("elements/calendar-jos.css", __FILE__), array(), $wd_spider_calendar_version, FALSE);
620
+
621
+ if( isset($_GET['page']) && $_GET['page'] == "Uninstall_sp_calendar" ) {
622
+ wp_enqueue_style("sp_calendar_deactivate-css", plugins_url("wd/assets/css/deactivate_popup.css", __FILE__), array(), $wd_spider_calendar_version, FALSE);
623
+ }
624
  }
625
 
626
  function spider_calendar_event_category_admin_styles_scripts(){
629
  wp_enqueue_script("calendar-setup", plugins_url("elements/calendar-setup.js", __FILE__), array(), $wd_spider_calendar_version, FALSE);
630
  wp_enqueue_script('wp-color-picker');
631
  wp_enqueue_style( 'wp-color-picker' );
632
+ wp_enqueue_style("Css", plugins_url("elements/calendar-jos.css", __FILE__), array(), $wd_spider_calendar_version, FALSE);
633
  }
634
 
635
  add_filter('admin_head', 'spide_ShowTinyMCE');
654
  }
655
 
656
  // Add menu.
657
+ add_action( 'admin_menu', 'sp_calendar_options_panel' );
658
+ add_action( 'init', "wd_spcal_init" );
659
+
660
+
661
+ function wd_spcal_init(){
662
+
663
+ if( !class_exists("DoradoWeb") ){
664
+ require_once('wd/start.php');
665
+ }
666
+
667
+ global $sp_calendar_options;
668
+ $sp_calendar_options = array (
669
+ "prefix" => "sp_calendar",
670
+ "wd_plugin_id" => 29,
671
+ "plugin_title" => "Spider Calendar",
672
+ "plugin_wordpress_slug" => "spider-event-calendar",
673
+ "plugin_dir" => plugins_url('/', __FILE__),
674
+ "plugin_main_file" => __FILE__,
675
+ "description" => __('This is the best WordPress event Calendar plugin available in WordPress Directory.', 'sp_calendar'),
676
+
677
+ // from web-dorado.com
678
+ "plugin_features" => array(
679
+ 0 => array(
680
+ "title" => __("Responsive", "sp_calendar"),
681
+ "description" => __("Spider Calendar plugin is fully responsive and mobile-ready. Thus a beautiful display on all types of devices and screens is guaranteed.", "sp_calendar"),
682
+ ),
683
+ 1 => array(
684
+ "title" => __("Unlimited Calendars & Events", "sp_calendar"),
685
+ "description" => __("The calendar plugin allows you to create as many calendars as you want and add unlimited number of events in each calendar. Customize the design of each calendar, create events for each calendar separately and show multiple calendars on one page.", "sp_calendar"),
686
+ ),
687
+ 2 => array(
688
+ "title" => __("Event Categories", "sp_calendar"),
689
+ "description" => __("You can assign categories to your events by adding titles, descriptions and category colors from the website admin panel. The plugin allows you customize the calendars to show events from all or just a few categories.", "sp_calendar"),
690
+ ),
691
+ 3 => array(
692
+ "title" => __("Themes", "sp_calendar"),
693
+ "description" => __("Choose among 17 different calendar themes to make sure the calendar fits perfectly with your website design. Add your own style to the themes by customizing almost everything or easily create your own theme.", "sp_calendar"),
694
+ ),
695
+ 4 => array(
696
+ "title" => __("Repeat Events", "sp_calendar"),
697
+ "description" => __("If you have events in your calendar that occur regularly you can choose to use the recurring events option. You can set the events to repeat daily, weekly, monthly, yearly on specific days of the week, specific days of the month or year.", "sp_calendar"),
698
+ )
699
+ ),
700
+ // user guide from web-dorado.com
701
+ "user_guide" => array(
702
+ 0 => array(
703
+ "main_title" => __("Creating/Editing Calendars", "sp_calendar"),
704
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/creating-editing-calendar.html",
705
+ "titles" => array()
706
+ ),
707
+ 1 => array(
708
+ "main_title" => __("Creating/Editing Events", "sp_calendar"),
709
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/creating-editing-events.html",
710
+ "titles" => array()
711
+ ),
712
+ 2 => array(
713
+ "main_title" => __("Adding Event Category", "sp_calendar"),
714
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-event-category.html",
715
+ "titles" => array()
716
+ ),
717
+ 3 => array(
718
+ "main_title" => __("Adding Themes", "sp_calendar"),
719
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-themes.html",
720
+ "titles" => array(
721
+ array(
722
+ "title" => __("General Parameters", "sp_calendar"),
723
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-themes/general-parameters.html",
724
+ ),
725
+ array(
726
+ "title" => __("Header Parameters", "sp_calendar"),
727
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-themes/header-parameters.html",
728
+ ),
729
+ array(
730
+ "title" => __("Body Parameters", "sp_calendar"),
731
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-themes/body-parameters.html",
732
+ ),
733
+ array(
734
+ "title" => __("Popup Window Parameters", "sp_calendar"),
735
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-themes/popup-window-parameters.html",
736
+ ),
737
+ array(
738
+ "title" => __("Other Views Parameters of the Wordpress Calendar", "sp_calendar"),
739
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-themes/other-views-parameters.html",
740
+ ),
741
+ )
742
+ ),
743
+ 4 => array(
744
+ "main_title" => __("Adding Themes for a widget view", "sp_calendar"),
745
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-widget-view-themes.html",
746
+ "titles" => array(
747
+ array(
748
+ "title" => __("General Parameters", "sp_calendar"),
749
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-widget-view-themes/general-parameters.html",
750
+ ),
751
+ array(
752
+ "title" => __("Popup Window Parameters", "sp_calendar"),
753
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-widget-view-themes/popup-window-parameters.html",
754
+ ),
755
+ array(
756
+ "title" => __("Body Parameters", "sp_calendar"),
757
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/adding-widget-view-themes/body-parameters.html",
758
+ ),
759
+ )
760
+ ),
761
+ 5 => array(
762
+ "main_title" => __("Publishing the Created Calendar in a Page or a Post", "sp_calendar"),
763
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/publishing-calendar.html",
764
+ "titles" => array()
765
+ ),
766
+ 6 => array(
767
+ "main_title" => __("Publishing the Created Calendar in the Widget", "sp_calendar"),
768
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/publishing-calendar-in-widget.html",
769
+ "titles" => array()
770
+ ),
771
+ 7 => array(
772
+ "main_title" => __("Publishing the Upcoming Events widget", "sp_calendar"),
773
+ "url" => "https://web-dorado.com/wordpress-spider-calendar/publishing-upcoming-events-widget.html",
774
+ "titles" => array()
775
+ ),
776
+
777
+ ),
778
+ "video_youtube_id" => "wDrMRAjhgHk", // e.g. https://www.youtube.com/watch?v=acaexefeP7o youtube id is the acaexefeP7o
779
+ "overview_welcome_image" => null,
780
+ "plugin_wd_url" => "https://web-dorado.com/products/wordpress-calendar.html",
781
+ "plugin_wd_demo_link" => "http://wpdemo.web-dorado.com/spider-calendar/?_ga=1.67418517.523103993.1473155982",
782
+ "plugin_wd_addons_link" => null,
783
+ "plugin_wizard_link" => null,
784
+ "after_subscribe" => admin_url('admin.php?page=overview_sp_calendar'), // this can be plagin overview page or set up page
785
+ "plugin_menu_title" => "Calendar",
786
+ "plugin_menu_icon" => plugins_url('/images/calendar_menu.png', __FILE__) ,
787
+ "deactivate" => true,
788
+ "subscribe" => true,
789
+ "custom_post" => "SpiderCalendar", // if true => edit.php?post_type=contact
790
+ "menu_capability" => "manage_options",
791
+ "menu_position" => null,
792
+
793
+ );
794
+ dorado_web_init($sp_calendar_options);
795
+ }
796
 
797
  require_once("functions_for_xml_and_ajax.php");
798
  require_once("front_end/bigcalendarday.php");
829
  add_action('wp_ajax_nopriv_spiderseemore', 'seemore');
830
  add_action('wp_ajax_nopriv_window', 'php_window');
831
 
 
 
 
 
 
 
 
 
832
 
833
  // Add style head.
834
  function add_button_style_calendar() {
1102
  }
1103
  }
1104
 
 
1105
  function Uninstall_sp_calendar() {
1106
+ global $wpdb, $sp_calendar_options;
1107
+ if(!class_exists("DoradoWebConfig")){
1108
+ require_once("wd/config.php");
1109
+ }
1110
+ $config = new DoradoWebConfig();
1111
+ $config->set_options( $sp_calendar_options );
1112
+ $deactivate_reasons = new DoradoWebDeactivate($config);
1113
+ $deactivate_reasons->submit_and_deactivate();
1114
+
1115
  $base_name = plugin_basename('Spider_Calendar');
1116
  $base_page = 'admin.php?page=' . $base_name;
1117
  $mode = (isset($_GET['mode']) ? trim($_GET['mode']) : '');
1118
  ?>
1119
+ <?php upgrade_pro_sp(); ?>
 
 
 
 
1120
  <br />
1121
  <div class="goodbye-text">
1122
  Before uninstalling the plugin, please Contact our <a href="https://web-dorado.com/support/contact-us.html?source=spidercalendar" target= '_blank'>support team</a>. We'll do our best to help you out with your issue. We value each and every user and value what’s right for our users in everything we do.<br>
1159
  echo '</font><br />';
1160
  echo '</p>';
1161
  echo '</form>';
1162
+ delete_option('sp_calendar_subscribe_done');
1163
+ $mode = 'end-UNINSTALL';
1164
  }
1165
  }
1166
+
1167
  switch ($mode) {
1168
  case 'end-UNINSTALL':
 
1169
  echo '<div class="wrap">';
1170
  echo '<h2>Uninstall Spider Event Calendar</h2>';
1171
+ echo '<p><strong><a href="#" class="sp_calendar_deactivate_link" data-uninstall="1">Click Here</a> To Finish The Uninstallation And Spider Event Calendar Will Be Deactivated Automatically.</strong></p>';
1172
  echo '</div>';
1173
  break;
1174
  // Main Page
1185
  </p>
1186
 
1187
  <p style="color: red">
1188
+ <strong><?php echo'WARNING:'; ?></strong>
1189
  <?php echo 'Once uninstalled, this cannot be undone. You should use a Database Backup plugin of WordPress to back up all the data first.'; ?>
1190
  </p>
1191
 
1239
  </div>
1240
  </form>
1241
  <?php
1242
+
1243
  }
1244
  }
1245
 
1357
  }
1358
  }
1359
 
1360
+
1361
+ function upgrade_pro_sp($text = false){
1362
+ $page = isset($_GET["page"]) ? $_GET["page"] : "";
1363
+ ?>
1364
+ <div class="sp_calendar_upgrade wd-clear" >
1365
+ <div class="wd-left">
1366
+ <?php
1367
+ switch($page){
1368
+ case "SpiderCalendar":
1369
+ ?>
1370
+ <div style="font-size: 14px;">
1371
+ <?php _e("This section allows you to create calendars.","sp_calendar");?>
1372
+ <a style="color: #5CAEBD; text-decoration: none;border-bottom: 1px dotted;" target="_blank" href="https://web-dorado.com/wordpress-spider-calendar/creating-editing-calendar.html"><?php _e("Read More in User Manual.","sp_calendar");?></a>
1373
+ </div>
1374
+ <?php
1375
+ break;
1376
+ case "spider_calendar_event_category":
1377
+ ?>
1378
+ <div style="font-size: 14px;">
1379
+ <?php _e("This section allows you to create event categories.","sp_calendar");?>
1380
+ <a style="color: #5CAEBD; text-decoration: none;border-bottom: 1px dotted;" target="_blank" href="https://web-dorado.com/wordpress-spider-calendar/adding-event-category.html"><?php _e("Read More in User Manual.","sp_calendar");?></a>
1381
+ </div>
1382
+ <?php
1383
+ break;
1384
+ case "calendar_export":
1385
+ ?>
1386
+ <div style="font-size: 14px;">
1387
+ <?php _e("This section will allow exporting Spider Calendar data for further import to Event Calendar WD.","sp_calendar");?>
1388
+ <a style="color: #5CAEBD; text-decoration: none;border-bottom: 1px dotted;" target="_blank" href="https://web-dorado.com/products/wordpress-event-calendar-wd.html"><?php _e("Read More in User Manual.","sp_calendar");?></a>
1389
+ </div>
1390
+ <?php
1391
+ break;
1392
+ case "Uninstall_sp_calendar":
1393
+ ?>
1394
+ <div style="font-size: 14px;">
1395
+ <div class="page-banner uninstall-banner">
1396
+ <div class="uninstall_icon">
1397
+ </div>
1398
+ <div class="logo-title">Uninstall Spider Calendar </div>
1399
+ </div>
1400
+ </div>
1401
+ <?php
1402
+ break;
1403
+ }
1404
+ ?>
1405
+ </div>
1406
+ <div class="wd-right">
1407
+ <div class="wd-table">
1408
+ <div class="wd-cell wd-cell-valign-middle">
1409
+ <a href="https://wordpress.org/support/plugin/spider-event-calendar" target="_blank">
1410
+ <img src="<?php echo plugins_url('images/i_support.png', __FILE__); ?>" >
1411
+ <?php _e("Support Forum", "sp_calendar"); ?>
1412
+ </a>
1413
+ </div>
1414
+ <div class="wd-cell wd-cell-valign-middle">
1415
+ <a href="https://web-dorado.com/products/wordpress-calendar.html" target="_blank">
1416
+ <?php _e("UPGRADE TO PAID VERSION", "sp_calendar"); ?>
1417
+ </a>
1418
+ </div>
1419
+ </div>
1420
+
1421
+ </div>
1422
+ </div>
1423
+ <?php if($text){
1424
+ ?>
1425
+ <div class="wd-text-right wd-row" style="color: #15699F; font-size: 20px; margin-top:10px; padding:0px 15px;">
1426
+ <?php echo sprintf(__("This is FREE version, Customizing %s is available only in the PAID version.","sp_calendar"), $text);?>
1427
+ </div>
1428
+ <?php
1429
+ }
1430
+
1431
+ }
1432
+
1433
  function calendar_export() {
1434
  ?>
1435
+ <?php upgrade_pro_sp(); ?>
1436
  <form method="post" style="font-size: 14px; font-weight: bold;">
 
 
 
 
1437
  <input type='submit' value='Export' id="export_WD" name='export_spider_calendar' />
1438
  </form>
1439
  <style>
calendar_functions.html.php CHANGED
@@ -4,6 +4,7 @@ if (function_exists('current_user_can')) {
4
  die('Access Denied');
5
  }
6
  }
 
7
  function html_show_spider_calendar($rows, $pageNav, $sort) {
8
  ?>
9
  <script language="javascript">
@@ -127,31 +128,17 @@ function html_show_spider_calendar($rows, $pageNav, $sort) {
127
  if($def_zone_wd == 0) {
128
  $wpdb->query("ALTER TABLE " . $wpdb->prefix . "spidercalendar_calendar ADD def_zone varchar(255) DEFAULT 'Asia/Muscat'");
129
  } ?>
 
130
  <form method="post" onKeyPress="doNothing()" action="admin.php?page=SpiderCalendar" id="admin_form" name="admin_form">
131
  <?php $sp_cal_nonce = wp_create_nonce('nonce_sp_cal'); ?>
132
  <table cellspacing="10" width="100%" id="calendar_table">
133
  <tr>
134
- <td width="100%" style="font-size:14px; font-weight:bold">
135
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-2.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a>
136
- <br />
137
- This section allows you to create calendars. You can add unlimited number of calendars.
138
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-2.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
139
- </td>
140
- <td colspan="7" align="right" style="font-size:16px;">
141
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;">
142
- <img src="<?php echo plugins_url('images/header.png', __FILE__); ?>" border="0" alt="https://web-dorado.com/files/fromSpiderCalendarWP.php" width="215">
143
- </a>
144
- </td>
145
- </tr>
146
- <tr>
147
- <td style="width:210px"><h2>Calendar Manager</h2></td>
148
- <td style="width:90px; text-align:right;">
149
- <p class="submit" style="padding:0px; text-align:left">
150
  <input type="button" value="Add a Calendar" name="custom_parametrs" onClick="window.location.href='admin.php?page=SpiderCalendar&task=add_calendar'"/>
151
  </p>
152
  </td>
153
- <td style="text-align:right;font-size:16px;padding:20px; padding-right:50px">
154
- </td>
155
  </tr>
156
  </table>
157
  <?php
@@ -277,20 +264,8 @@ function html_add_spider_calendar() {
277
  height: 25px;
278
  }
279
  </style>
 
280
  <table width="95%">
281
- <tr>
282
- <td width="100%" style="font-size:14px; font-weight:bold">
283
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-2.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a>
284
- <br />
285
- This section allows you to create calendars. You can add unlimited number of calendars.
286
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-2.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
287
- </td>
288
- <td colspan="7" align="right" style="font-size:16px;">
289
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;">
290
- <img src="<?php echo plugins_url('images/header.png', __FILE__); ?>" border="0" alt="https://web-dorado.com/files/fromSpiderCalendarWP.php" width="215">
291
- </a>
292
- </td>
293
- </tr>
294
  <tr>
295
  <td width="100%"><h2>Add Calendar</h2></td>
296
  <td align="right"><input type="button" onClick="submitbutton('Save')" value="Save" class="button-secondary action"></td>
@@ -463,20 +438,8 @@ function html_edit_spider_calendar($row) {
463
  height: 25px;
464
  }
465
  </style>
 
466
  <table width="95%">
467
- <tr>
468
- <td width="100%" style="font-size:14px; font-weight:bold">
469
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-2.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a>
470
- <br />
471
- This section allows you to create calendars. You can add unlimited number of calendars.
472
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-2.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
473
- </td>
474
- <td colspan="7" align="right" style="font-size:16px;">
475
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;">
476
- <img src="<?php echo plugins_url('images/header.png', __FILE__); ?>" border="0" alt="https://web-dorado.com/files/fromSpiderCalendarWP.php" width="215">
477
- </a>
478
- </td>
479
- </tr>
480
  <tr>
481
  <td width="100%"><h2>Calendar - <?php echo $row->title; ?></h2></td>
482
  <td align="right"><input type="button" onClick="submitbutton('Save')" value="Save" class="button-secondary action"></td>
@@ -726,32 +689,17 @@ function show_event_category($rows, $pageNav, $sort){
726
  return "";
727
  }
728
  </script>
 
729
  <form method="post" onKeyPress="doNothing()" action="admin.php?page=spider_calendar_event_category" id="admin_form" name="admin_form">
730
  <?php $sp_cal_nonce = wp_create_nonce('nonce_sp_cal'); ?>
731
  <table cellspacing="10" width="100%" id="category_table">
732
  <tr>
733
- <td width="100%" style="font-size:14px; font-weight:bold">
734
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-2.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a>
735
- <br />
736
- This section allows you to create event categories. You can add unlimited number of categories.
737
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-4.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
738
- </td>
739
- <td colspan="7" align="right" style="font-size:16px;">
740
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;">
741
- <img src="<?php echo plugins_url('images/header.png', __FILE__); ?>" border="0" alt="https://web-dorado.com/files/fromSpiderCalendarWP.php" width="215">
742
- </a>
743
- </td>
744
- </tr>
745
-
746
- <tr>
747
- <td style="width:210px"><h2>Event Category</h2></td>
748
- <td style="width:90px; text-align:right;">
749
  <p class="submit" style="padding:0px; text-align:left">
750
- <input type="button" value="Add a Category" name="custom_parametrs" onClick="window.location.href='admin.php?page=spider_calendar_event_category&task=add_category'"/>
751
  </p>
752
  </td>
753
- <td style="text-align:right;font-size:16px;padding:20px; padding-right:50px">
754
- </td>
755
  </tr>
756
  </table>
757
  <?php
@@ -885,23 +833,13 @@ $row=$wpdb->get_row($wpdb->prepare ("SELECT * FROM " . $wpdb->prefix . "spiderca
885
  margin: -4px;
886
  }
887
  </style>
 
888
  <table cellspacing="10" width="100%" id="category_table">
889
  <tr>
890
- <td width="100%" style="font-size:14px; font-weight:bold">
891
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-2.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a>
892
- <br />
893
- This section allows you to create event categories. You can add unlimited number of categories.
894
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-4.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
895
- </td>
896
- </tr>
897
- <tr>
898
- <td style="width:210px"><h2>Event Category <?php if(isset($row->title)) echo htmlspecialchars($row->title); ?></h2></td>
899
- <td align="right"><input type="button" onClick="submitbutton('save_category_event')" value="Save" class="button-secondary action"></td>
900
- <td align="right"><input type="button" onClick="submitbutton('apply_event_category')" value="Apply" class="button-secondary action"></td>
901
- <td align="right"><input type="button" onClick="window.location.href='admin.php?page=spider_calendar_event_category'" value="Cancel" class="button-secondary action" style="margin: 0px 0px 0px -5px;">
902
- </td>
903
- <td style="text-align:right;font-size:16px;padding:20px; padding-right:50px">
904
- </td>
905
  </tr>
906
  </table>
907
 
@@ -1297,22 +1235,33 @@ function html_show_spider_event($rows, $pageNav, $sort, $calendar_id, $cal_name)
1297
  }
1298
  }
1299
  </script>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1300
  <form method="post" onKeyPress="doNothing()" action="admin.php?page=SpiderCalendar&task=show_manage_event&calendar_id=<?php echo $calendar_id; ?>" id="admin_form" name="admin_form">
1301
  <?php $sp_cal_nonce = wp_create_nonce('nonce_sp_cal'); ?>
1302
  <table cellspacing="10" width="95%">
1303
- <tr>
1304
- <td width="100%" style="font-size:14px; font-weight:bold">
1305
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-3.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a><br>
1306
- This section allows you to create/edit the events of a particular calendar.<br/> You can add
1307
- unlimited number of events for each calendar.
1308
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-3.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
1309
- </td>
1310
- <td colspan="7" align="right" style="font-size:16px;">
1311
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;">
1312
- <img src="<?php echo plugins_url('images/header.png', __FILE__); ?>" border="0" alt="https://web-dorado.com/files/fromSpiderCalendarWP.php" width="215">
1313
- </a>
1314
- </td>
1315
- </tr>
1316
  <tr>
1317
  <td width="100%"><h2>Event Manager for calendar <font style="color:red"><?php echo $cal_name; ?></font></h2></td>
1318
  <td>
@@ -1704,15 +1653,31 @@ function html_add_spider_event($calendar_id, $cal_name) {
1704
  height: 25px;
1705
  }
1706
  </style>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1707
  <table width="95%">
1708
- <tr>
1709
- <td width="100%" style="font-size:14px; font-weight:bold">
1710
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-3.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a>
1711
- <br />
1712
- This section allows you to create/edit the events of a particular calendar.<br/> You can add unlimited number of events for each calendar.
1713
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-3.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
1714
- </td>
1715
- </tr>
1716
  <tbody>
1717
  <tr>
1718
  <td width="100%"><h2>Add an event for calendar <font style="color:red"><?php echo $cal_name; ?></font></h2></td>
@@ -2184,15 +2149,31 @@ function html_edit_spider_event($row, $calendar_id, $id, $cal_name) {
2184
 
2185
  $query2 = $wpdb->get_results("SELECT title,id FROM " . $wpdb->prefix . "spidercalendar_event_category");
2186
  ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2187
  <table width="95%">
2188
- <tr>
2189
- <td width="100%" style="font-size:14px; font-weight:bold">
2190
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-3.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a>
2191
- <br />
2192
- This section allows you to create/edit the events of a particular calendar.<br/> You can add unlimited number of events for each calendar.
2193
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-3.html" target="_blank" style="color:blue; text-decoration:none;">More...</a>
2194
- </td>
2195
- </tr>
2196
  <tbody>
2197
  <tr>
2198
  <td width="100%"><h2>Edit an event for calendar <font style="color:red"><?php echo $cal_name; ?></font></h2></td>
4
  die('Access Denied');
5
  }
6
  }
7
+
8
  function html_show_spider_calendar($rows, $pageNav, $sort) {
9
  ?>
10
  <script language="javascript">
128
  if($def_zone_wd == 0) {
129
  $wpdb->query("ALTER TABLE " . $wpdb->prefix . "spidercalendar_calendar ADD def_zone varchar(255) DEFAULT 'Asia/Muscat'");
130
  } ?>
131
+ <?php upgrade_pro_sp(); ?>
132
  <form method="post" onKeyPress="doNothing()" action="admin.php?page=SpiderCalendar" id="admin_form" name="admin_form">
133
  <?php $sp_cal_nonce = wp_create_nonce('nonce_sp_cal'); ?>
134
  <table cellspacing="10" width="100%" id="calendar_table">
135
  <tr>
136
+ <td><h2>Calendar Manager</h2></td>
137
+ <td style="text-align: right;">
138
+ <p class="submit" style="padding:0px; text-align: right;">
 
 
 
 
 
 
 
 
 
 
 
 
 
139
  <input type="button" value="Add a Calendar" name="custom_parametrs" onClick="window.location.href='admin.php?page=SpiderCalendar&task=add_calendar'"/>
140
  </p>
141
  </td>
 
 
142
  </tr>
143
  </table>
144
  <?php
264
  height: 25px;
265
  }
266
  </style>
267
+ <?php upgrade_pro_sp(); ?>
268
  <table width="95%">
 
 
 
 
 
 
 
 
 
 
 
 
 
269
  <tr>
270
  <td width="100%"><h2>Add Calendar</h2></td>
271
  <td align="right"><input type="button" onClick="submitbutton('Save')" value="Save" class="button-secondary action"></td>
438
  height: 25px;
439
  }
440
  </style>
441
+ <?php upgrade_pro_sp(); ?>
442
  <table width="95%">
 
 
 
 
 
 
 
 
 
 
 
 
 
443
  <tr>
444
  <td width="100%"><h2>Calendar - <?php echo $row->title; ?></h2></td>
445
  <td align="right"><input type="button" onClick="submitbutton('Save')" value="Save" class="button-secondary action"></td>
689
  return "";
690
  }
691
  </script>
692
+ <?php upgrade_pro_sp(); ?>
693
  <form method="post" onKeyPress="doNothing()" action="admin.php?page=spider_calendar_event_category" id="admin_form" name="admin_form">
694
  <?php $sp_cal_nonce = wp_create_nonce('nonce_sp_cal'); ?>
695
  <table cellspacing="10" width="100%" id="category_table">
696
  <tr>
697
+ <td><h2>Event Category</h2></td>
698
+ <td style="text-align:right;">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
699
  <p class="submit" style="padding:0px; text-align:left">
700
+ <input type="button" value="Add a Category" name="custom_parametrs" onClick="window.location.href='admin.php?page=spider_calendar_event_category&task=add_category'" class="wd-right"/>
701
  </p>
702
  </td>
 
 
703
  </tr>
704
  </table>
705
  <?php
833
  margin: -4px;
834
  }
835
  </style>
836
+ <?php upgrade_pro_sp(); ?>
837
  <table cellspacing="10" width="100%" id="category_table">
838
  <tr>
839
+ <td><h2>Event Category <?php if(isset($row->title)) echo htmlspecialchars($row->title); ?></h2></td>
840
+ <td align="right" style="width: 45px;"><input type="button" onClick="submitbutton('save_category_event')" value="Save" class="button-secondary action"></td>
841
+ <td align="right" style="width: 50px;"><input type="button" onClick="submitbutton('apply_event_category')" value="Apply" class="button-secondary action"></td>
842
+ <td align="right" style="width: 59px;"><input type="button" onClick="window.location.href='admin.php?page=spider_calendar_event_category'" value="Cancel" class="button-secondary action" style="margin: 0px 0px 0px -5px;"></td>
 
 
 
 
 
 
 
 
 
 
 
843
  </tr>
844
  </table>
845
 
1235
  }
1236
  }
1237
  </script>
1238
+ <div class="sp_calendar_upgrade wd-clear" >
1239
+ <div class="wd-left">
1240
+ <div style="font-size: 14px;">
1241
+ <?php _e("This section allows you to create/edit the events of a particular calendar.","sp_calendar");?>
1242
+ <a style="color: #5CAEBD; text-decoration: none;border-bottom: 1px dotted;" target="_blank" href="https://web-dorado.com/wordpress-spider-calendar/creating-editing-events.html"><?php _e("Read More in User Manual.","sp_calendar");?></a>
1243
+ </div>
1244
+ </div>
1245
+ <div class="wd-right">
1246
+ <div class="wd-table">
1247
+ <div class="wd-cell wd-cell-valign-middle">
1248
+ <a href="https://wordpress.org/support/plugin/spider-event-calendar" target="_blank">
1249
+ <img src="<?php echo plugins_url('images/i_support.png', __FILE__); ?>" >
1250
+ <?php _e("Support Forum", "sp_calendar"); ?>
1251
+ </a>
1252
+ </div>
1253
+ <div class="wd-cell wd-cell-valign-middle">
1254
+ <a href="https://web-dorado.com/products/wordpress-calendar.html" target="_blank">
1255
+ <?php _e("UPGRADE TO PAID VERSION", "sp_calendar"); ?>
1256
+ </a>
1257
+ </div>
1258
+ </div>
1259
+
1260
+ </div>
1261
+ </div>
1262
  <form method="post" onKeyPress="doNothing()" action="admin.php?page=SpiderCalendar&task=show_manage_event&calendar_id=<?php echo $calendar_id; ?>" id="admin_form" name="admin_form">
1263
  <?php $sp_cal_nonce = wp_create_nonce('nonce_sp_cal'); ?>
1264
  <table cellspacing="10" width="95%">
 
 
 
 
 
 
 
 
 
 
 
 
 
1265
  <tr>
1266
  <td width="100%"><h2>Event Manager for calendar <font style="color:red"><?php echo $cal_name; ?></font></h2></td>
1267
  <td>
1653
  height: 25px;
1654
  }
1655
  </style>
1656
+ <div class="sp_calendar_upgrade wd-clear" >
1657
+ <div class="wd-left">
1658
+ <div style="font-size: 14px;">
1659
+ <?php _e("This section allows you to create/edit the events of a particular calendar.","sp_calendar");?>
1660
+ <a style="color: #5CAEBD; text-decoration: none;border-bottom: 1px dotted;" target="_blank" href="https://web-dorado.com/wordpress-spider-calendar/creating-editing-events.html"><?php _e("Read More in User Manual.","sp_calendar");?></a>
1661
+ </div>
1662
+ </div>
1663
+ <div class="wd-right">
1664
+ <div class="wd-table">
1665
+ <div class="wd-cell wd-cell-valign-middle">
1666
+ <a href="https://wordpress.org/support/plugin/spider-event-calendar" target="_blank">
1667
+ <img src="<?php echo plugins_url('images/i_support.png', __FILE__); ?>" >
1668
+ <?php _e("Support Forum", "sp_calendar"); ?>
1669
+ </a>
1670
+ </div>
1671
+ <div class="wd-cell wd-cell-valign-middle">
1672
+ <a href="https://web-dorado.com/products/wordpress-calendar.html" target="_blank">
1673
+ <?php _e("UPGRADE TO PAID VERSION", "sp_calendar"); ?>
1674
+ </a>
1675
+ </div>
1676
+ </div>
1677
+
1678
+ </div>
1679
+ </div>
1680
  <table width="95%">
 
 
 
 
 
 
 
 
1681
  <tbody>
1682
  <tr>
1683
  <td width="100%"><h2>Add an event for calendar <font style="color:red"><?php echo $cal_name; ?></font></h2></td>
2149
 
2150
  $query2 = $wpdb->get_results("SELECT title,id FROM " . $wpdb->prefix . "spidercalendar_event_category");
2151
  ?>
2152
+ <div class="sp_calendar_upgrade wd-clear" >
2153
+ <div class="wd-left">
2154
+ <div style="font-size: 14px;">
2155
+ <?php _e("This section allows you to create/edit the events of a particular calendar.","sp_calendar");?>
2156
+ <a style="color: #5CAEBD; text-decoration: none;border-bottom: 1px dotted;" target="_blank" href="https://web-dorado.com/wordpress-spider-calendar/creating-editing-events.html"><?php _e("Read More in User Manual.","sp_calendar");?></a>
2157
+ </div>
2158
+ </div>
2159
+ <div class="wd-right">
2160
+ <div class="wd-table">
2161
+ <div class="wd-cell wd-cell-valign-middle">
2162
+ <a href="https://wordpress.org/support/plugin/spider-event-calendar" target="_blank">
2163
+ <img src="<?php echo plugins_url('images/i_support.png', __FILE__); ?>" >
2164
+ <?php _e("Support Forum", "sp_calendar"); ?>
2165
+ </a>
2166
+ </div>
2167
+ <div class="wd-cell wd-cell-valign-middle">
2168
+ <a href="https://web-dorado.com/products/wordpress-calendar.html" target="_blank">
2169
+ <?php _e("UPGRADE TO PAID VERSION", "sp_calendar"); ?>
2170
+ </a>
2171
+ </div>
2172
+ </div>
2173
+
2174
+ </div>
2175
+ </div>
2176
  <table width="95%">
 
 
 
 
 
 
 
 
2177
  <tbody>
2178
  <tr>
2179
  <td width="100%"><h2>Edit an event for calendar <font style="color:red"><?php echo $cal_name; ?></font></h2></td>
calendar_functions.php CHANGED
@@ -12,7 +12,7 @@ function add_spider_calendar() {
12
 
13
  function copy_spider_event($calendar_id, $id) {
14
  global $wpdb;
15
- $query = 'INSERT INTO `'.$wpdb->prefix . 'spidercalendar_event`(`calendar`, `date`, `date_end`, `title`, `category`, `time`, `text_for_date`, `userID`, `repeat_method`, `repeat`, `week`, `month`, `month_type`, `monthly_list`, `month_week`, `year_month`, `published`) SELECT `calendar`, `date`, `date_end`, `title`, `category`, `time`, `text_for_date`, `userID`, `repeat_method`, `repeat`, `week`, `month`, `month_type`, `monthly_list`, `month_week`, `year_month`, `published` FROM `'.$wpdb->prefix . 'spidercalendar_event` WHERE `id` = "'.$id.'"';
16
  if (!$wpdb->query($query)) {
17
  ?>
18
  <div id="message" class="error"><p>Event copy was not created.</p></div>
@@ -30,8 +30,10 @@ if(isset($_GET['upcalendar_id']))
30
  $calendar_id=(int)$_GET['upcalendar_id'];
31
  else $calendar_id="0";
32
 
33
- global $wpdb;
34
- $order = " ORDER BY title ASC";
 
 
35
  $sort["default_style"] = "manage-column column-autor sortable desc";
36
  $sort["sortid_by"] = "title";
37
  $sort["custom_style"] = "manage-column column-title sorted asc";
@@ -43,12 +45,14 @@ else $calendar_id="0";
43
  }
44
  $sort["custom_style"] = "manage-column column-title sorted asc";
45
  $sort["1_or_2"] = "2";
46
- $order = "ORDER BY " . $sort["sortid_by"] . " ASC";
 
47
  }
48
  else {
49
  $sort["custom_style"] = "manage-column column-title sorted desc";
50
  $sort["1_or_2"] = "1";
51
- $order = "ORDER BY " . $sort["sortid_by"] . " DESC";
 
52
  }
53
  if ($_POST['page_number']) {
54
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number'])))- 1) * 20;
@@ -68,7 +72,7 @@ else $calendar_id="0";
68
  }
69
 
70
  if ($search_tag) {
71
- $where = ' AND ' . $wpdb->prefix . 'spidercalendar_event.title LIKE "%%' . like_escape($search_tag) . '%%"';
72
  }
73
  else {
74
  $where = '';
@@ -86,8 +90,9 @@ else $calendar_id="0";
86
  $total = $wpdb->get_var($query);
87
  $pageNav['total'] = $total;
88
  $pageNav['limit'] = $limit / 20 + 1;
89
-
90
- $query = $wpdb->prepare ("SELECT * FROM " . $wpdb->prefix . "spidercalendar_event WHERE calendar=%d " . $where . " " . $order . " " . " LIMIT %d,20",$calendar_id,$limit);
 
91
 
92
  $rows=$wpdb->get_results($query);
93
 
@@ -99,7 +104,10 @@ else $calendar_id="0";
99
 
100
  function show_spider_calendar() {
101
  global $wpdb;
102
- $order = " ORDER BY title ASC";
 
 
 
103
  $sort["default_style"] = "manage-column column-autor sortable desc";
104
  $sort["sortid_by"] = "title";
105
  $sort["custom_style"] = "manage-column column-title sorted asc";
@@ -111,12 +119,14 @@ function show_spider_calendar() {
111
  if (isset($_POST['asc_or_desc']) && (esc_html($_POST['asc_or_desc']) == 1)) {
112
  $sort["custom_style"] = "manage-column column-title sorted asc";
113
  $sort["1_or_2"] = "2";
114
- $order = "ORDER BY " . $sort["sortid_by"] . " ASC";
 
115
  }
116
  else {
117
  $sort["custom_style"] = "manage-column column-title sorted desc";
118
  $sort["1_or_2"] = "1";
119
- $order = "ORDER BY " . $sort["sortid_by"] . " DESC";
 
120
  }
121
  if (isset($_POST['page_number']) && (esc_html($_POST['page_number']))) {
122
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number']))) - 1) * 20;
@@ -135,7 +145,7 @@ function show_spider_calendar() {
135
  $search_tag = "";
136
  }
137
  if ($search_tag) {
138
- $where = ' WHERE title LIKE "%%' . like_escape($search_tag) . '%%"';
139
  }
140
  else {
141
  $where = ' ';
@@ -145,7 +155,10 @@ function show_spider_calendar() {
145
  $total = $wpdb->get_var($query);
146
  $pageNav['total'] = $total;
147
  $pageNav['limit'] = $limit / 20 + 1;
148
- $query = $wpdb->prepare ( "SELECT * FROM " . $wpdb->prefix . "spidercalendar_calendar" . $where . " " . $order . " " . " LIMIT %d,20",$limit);
 
 
 
149
  $rows = $wpdb->get_results($query);
150
  // display function
151
  html_show_spider_calendar($rows, $pageNav, $sort);
@@ -153,7 +166,9 @@ function show_spider_calendar() {
153
 
154
  function show_event_cat(){
155
  global $wpdb;
156
- $order = " ORDER BY title ASC";
 
 
157
  $sort["default_style"] = "manage-column column-autor sortable desc";
158
  $sort["sortid_by"] = "title";
159
  $sort["custom_style"] = "manage-column column-title sorted asc";
@@ -165,12 +180,14 @@ function show_event_cat(){
165
  if (isset($_POST['asc_or_desc']) && (esc_html($_POST['asc_or_desc']) == 1)) {
166
  $sort["custom_style"] = "manage-column column-title sorted asc";
167
  $sort["1_or_2"] = "2";
168
- $order = "ORDER BY " . $sort["sortid_by"] . " ASC";
 
169
  }
170
  else {
171
  $sort["custom_style"] = "manage-column column-title sorted desc";
172
  $sort["1_or_2"] = "1";
173
- $order = "ORDER BY " . $sort["sortid_by"] . " DESC";
 
174
  }
175
  if (isset($_POST['page_number']) && (esc_html($_POST['page_number']))) {
176
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number']))) - 1) * 20;
@@ -189,7 +206,7 @@ function show_event_cat(){
189
  $search_tag = "";
190
  }
191
  if ($search_tag) {
192
- $where = ' WHERE title LIKE "%%' . like_escape($search_tag) . '%%"';
193
  }
194
  else {
195
  $where = ' ';
@@ -199,7 +216,9 @@ function show_event_cat(){
199
  $total = $wpdb->get_var($query);
200
  $pageNav['total'] = $total;
201
  $pageNav['limit'] = $limit / 20 + 1;
202
- $query =$wpdb->prepare ( "SELECT * FROM " . $wpdb->prefix . "spidercalendar_event_category" . $where . " " . $order . " " . " LIMIT %d,20",$limit);
 
 
203
 
204
  $rows = $wpdb->get_results($query);
205
  // display function
@@ -430,7 +449,9 @@ function spider_calendar_published($id) {
430
  // Event in table
431
  function show_spider_event($calendar_id) {
432
  global $wpdb;
433
- $order = " ORDER BY title ASC";
 
 
434
  $sort["default_style"] = "manage-column column-autor sortable desc";
435
  $sort["sortid_by"] = "title";
436
  $sort["custom_style"] = "manage-column column-title sorted asc";
@@ -442,12 +463,14 @@ global $wpdb;
442
  if (isset($_POST['asc_or_desc']) && (esc_html($_POST['asc_or_desc']) == 1)) {
443
  $sort["custom_style"] = "manage-column column-title sorted asc";
444
  $sort["1_or_2"] = "2";
445
- $order = "ORDER BY " . $sort["sortid_by"] . " ASC";
 
446
  }
447
  else {
448
  $sort["custom_style"] = "manage-column column-title sorted desc";
449
  $sort["1_or_2"] = "1";
450
- $order = "ORDER BY " . $sort["sortid_by"] . " DESC";
 
451
  }
452
  if (isset($_POST['page_number']) && (esc_html($_POST['page_number']))) {
453
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number']))) - 1) * 20;
@@ -466,7 +489,7 @@ global $wpdb;
466
  $search_tag = "";
467
  }
468
  if ($search_tag) {
469
- $where = ' AND ' . $wpdb->prefix . 'spidercalendar_event.title LIKE "%%' . like_escape($search_tag) . '%%"';
470
  }
471
  else {
472
  $where = '';
@@ -477,15 +500,15 @@ global $wpdb;
477
  if (isset($_POST['enddate']) && $_POST['enddate']) {
478
  $where .= ' AND ' . $wpdb->prefix . 'spidercalendar_event.date < \'' .esc_sql(esc_html(stripslashes($_POST['enddate']))). '\' ';
479
  }
 
480
  // Get the total number of records.
481
  $query = $wpdb->prepare ("SELECT COUNT(*) FROM " . $wpdb->prefix . "spidercalendar_event WHERE calendar=%d " . $where . " ", $calendar_id);
482
  $total = $wpdb->get_var($query);
483
  $pageNav['total'] = $total;
484
  $pageNav['limit'] = $limit / 20 + 1;
485
-
486
- $query = $wpdb->prepare ("SELECT " . $wpdb->prefix . "spidercalendar_event.*, " . $wpdb->prefix . "spidercalendar_event_category.title as cattitle FROM " . $wpdb->prefix . "spidercalendar_event LEFT JOIN " . $wpdb->prefix . "spidercalendar_event_category ON " . $wpdb->prefix . "spidercalendar_event.category=" . $wpdb->prefix . "spidercalendar_event_category.id
487
- WHERE calendar=%d " . $where . " " . $order . " " . " LIMIT %d,20",$calendar_id,$limit);
488
-
489
  $rows = $wpdb->get_results($query);
490
  $cal_name = $wpdb->get_var($wpdb->prepare('SELECT title' . ' FROM ' . $wpdb->prefix . 'spidercalendar_calendar WHERE `id`="%d"', $calendar_id));
491
  html_show_spider_event($rows, $pageNav, $sort, $calendar_id, $cal_name);
12
 
13
  function copy_spider_event($calendar_id, $id) {
14
  global $wpdb;
15
+ $query = $wpdb->prepare ('INSERT INTO `'.$wpdb->prefix . 'spidercalendar_event`(`calendar`, `date`, `date_end`, `title`, `category`, `time`, `text_for_date`, `userID`, `repeat_method`, `repeat`, `week`, `month`, `month_type`, `monthly_list`, `month_week`, `year_month`, `published`) SELECT `calendar`, `date`, `date_end`, `title`, `category`, `time`, `text_for_date`, `userID`, `repeat_method`, `repeat`, `week`, `month`, `month_type`, `monthly_list`, `month_week`, `year_month`, `published` FROM `'.$wpdb->prefix . 'spidercalendar_event` WHERE `id` = "%d"', $id );
16
  if (!$wpdb->query($query)) {
17
  ?>
18
  <div id="message" class="error"><p>Event copy was not created.</p></div>
30
  $calendar_id=(int)$_GET['upcalendar_id'];
31
  else $calendar_id="0";
32
 
33
+ global $wpdb;
34
+ $order = "title";
35
+ $asc_desc = "ASC";
36
+ $order_by = "";
37
  $sort["default_style"] = "manage-column column-autor sortable desc";
38
  $sort["sortid_by"] = "title";
39
  $sort["custom_style"] = "manage-column column-title sorted asc";
45
  }
46
  $sort["custom_style"] = "manage-column column-title sorted asc";
47
  $sort["1_or_2"] = "2";
48
+ $order = esc_sql(esc_html($sort["sortid_by"]));
49
+ $asc_desc = "ASC";
50
  }
51
  else {
52
  $sort["custom_style"] = "manage-column column-title sorted desc";
53
  $sort["1_or_2"] = "1";
54
+ $order = esc_sql(esc_html($sort["sortid_by"]));
55
+ $asc_desc = "DESC";
56
  }
57
  if ($_POST['page_number']) {
58
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number'])))- 1) * 20;
72
  }
73
 
74
  if ($search_tag) {
75
+ $where = ' AND ' . $wpdb->prefix . 'spidercalendar_event.title LIKE "%%' . esc_sql(esc_html($search_tag)) . '%%"';
76
  }
77
  else {
78
  $where = '';
90
  $total = $wpdb->get_var($query);
91
  $pageNav['total'] = $total;
92
  $pageNav['limit'] = $limit / 20 + 1;
93
+
94
+ if( $order == "id" || $order == "title" || $order == "date" || $order == "time" ) $order_by = " ORDER BY " . $order . " " . $asc_desc;
95
+ $query = $wpdb->prepare ("SELECT * FROM " . $wpdb->prefix . "spidercalendar_event WHERE calendar=%d " . $where . " " . $order_by . " " . " LIMIT %d,20",$calendar_id,$limit);
96
 
97
  $rows=$wpdb->get_results($query);
98
 
104
 
105
  function show_spider_calendar() {
106
  global $wpdb;
107
+ $order = "title";
108
+ $asc_desc = "ASC";
109
+ $order_by = "";
110
+
111
  $sort["default_style"] = "manage-column column-autor sortable desc";
112
  $sort["sortid_by"] = "title";
113
  $sort["custom_style"] = "manage-column column-title sorted asc";
119
  if (isset($_POST['asc_or_desc']) && (esc_html($_POST['asc_or_desc']) == 1)) {
120
  $sort["custom_style"] = "manage-column column-title sorted asc";
121
  $sort["1_or_2"] = "2";
122
+ $order = esc_sql(esc_html($sort["sortid_by"]));
123
+ $asc_desc = "ASC";
124
  }
125
  else {
126
  $sort["custom_style"] = "manage-column column-title sorted desc";
127
  $sort["1_or_2"] = "1";
128
+ $order = esc_sql(esc_html($sort["sortid_by"]));
129
+ $asc_desc = "DESC";
130
  }
131
  if (isset($_POST['page_number']) && (esc_html($_POST['page_number']))) {
132
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number']))) - 1) * 20;
145
  $search_tag = "";
146
  }
147
  if ($search_tag) {
148
+ $where = ' WHERE title LIKE "%%' . esc_sql(esc_html($search_tag)) . '%%"';
149
  }
150
  else {
151
  $where = ' ';
155
  $total = $wpdb->get_var($query);
156
  $pageNav['total'] = $total;
157
  $pageNav['limit'] = $limit / 20 + 1;
158
+
159
+ if( $order == "id" || $order == "title" || $order == "published" )
160
+ $order_by = " ORDER BY " . $order . " " . $asc_desc;
161
+ $query = $wpdb->prepare ( "SELECT * FROM " . $wpdb->prefix . "spidercalendar_calendar" . $where . " " . $order_by . " " . " LIMIT %d,20",$limit);
162
  $rows = $wpdb->get_results($query);
163
  // display function
164
  html_show_spider_calendar($rows, $pageNav, $sort);
166
 
167
  function show_event_cat(){
168
  global $wpdb;
169
+ $order = "title";
170
+ $asc_desc = "ASC";
171
+ $order_by = "";
172
  $sort["default_style"] = "manage-column column-autor sortable desc";
173
  $sort["sortid_by"] = "title";
174
  $sort["custom_style"] = "manage-column column-title sorted asc";
180
  if (isset($_POST['asc_or_desc']) && (esc_html($_POST['asc_or_desc']) == 1)) {
181
  $sort["custom_style"] = "manage-column column-title sorted asc";
182
  $sort["1_or_2"] = "2";
183
+ $order = esc_sql(esc_html($sort["sortid_by"]));
184
+ $asc_desc = "ASC";
185
  }
186
  else {
187
  $sort["custom_style"] = "manage-column column-title sorted desc";
188
  $sort["1_or_2"] = "1";
189
+ $order = esc_sql(esc_html($sort["sortid_by"]));
190
+ $asc_desc = "DESC";
191
  }
192
  if (isset($_POST['page_number']) && (esc_html($_POST['page_number']))) {
193
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number']))) - 1) * 20;
206
  $search_tag = "";
207
  }
208
  if ($search_tag) {
209
+ $where = ' WHERE title LIKE "%%' . esc_sql(esc_html($search_tag)) . '%%"';
210
  }
211
  else {
212
  $where = ' ';
216
  $total = $wpdb->get_var($query);
217
  $pageNav['total'] = $total;
218
  $pageNav['limit'] = $limit / 20 + 1;
219
+ if( $order == "id" || $order == "title" || $order == "published" || $order == "description" )
220
+ $order_by = " ORDER BY " . $order . " " . $asc_desc;
221
+ $query =$wpdb->prepare ( "SELECT * FROM " . $wpdb->prefix . "spidercalendar_event_category" . $where . " " . $order_by . " " . " LIMIT %d,20",$limit);
222
 
223
  $rows = $wpdb->get_results($query);
224
  // display function
449
  // Event in table
450
  function show_spider_event($calendar_id) {
451
  global $wpdb;
452
+ $order = "title";
453
+ $asc_desc = "ASC";
454
+ $order_by = "";
455
  $sort["default_style"] = "manage-column column-autor sortable desc";
456
  $sort["sortid_by"] = "title";
457
  $sort["custom_style"] = "manage-column column-title sorted asc";
463
  if (isset($_POST['asc_or_desc']) && (esc_html($_POST['asc_or_desc']) == 1)) {
464
  $sort["custom_style"] = "manage-column column-title sorted asc";
465
  $sort["1_or_2"] = "2";
466
+ $order = esc_sql(esc_html($sort["sortid_by"]));
467
+ $asc_desc = "ASC";
468
  }
469
  else {
470
  $sort["custom_style"] = "manage-column column-title sorted desc";
471
  $sort["1_or_2"] = "1";
472
+ $order = esc_sql(esc_html($sort["sortid_by"]));
473
+ $asc_desc = "DESC";
474
  }
475
  if (isset($_POST['page_number']) && (esc_html($_POST['page_number']))) {
476
  $limit = (esc_sql(esc_html(stripslashes($_POST['page_number']))) - 1) * 20;
489
  $search_tag = "";
490
  }
491
  if ($search_tag) {
492
+ $where = ' AND ' . $wpdb->prefix . 'spidercalendar_event.title LIKE "%%' . esc_sql(esc_html($search_tag)) . '%%"';
493
  }
494
  else {
495
  $where = '';
500
  if (isset($_POST['enddate']) && $_POST['enddate']) {
501
  $where .= ' AND ' . $wpdb->prefix . 'spidercalendar_event.date < \'' .esc_sql(esc_html(stripslashes($_POST['enddate']))). '\' ';
502
  }
503
+
504
  // Get the total number of records.
505
  $query = $wpdb->prepare ("SELECT COUNT(*) FROM " . $wpdb->prefix . "spidercalendar_event WHERE calendar=%d " . $where . " ", $calendar_id);
506
  $total = $wpdb->get_var($query);
507
  $pageNav['total'] = $total;
508
  $pageNav['limit'] = $limit / 20 + 1;
509
+ if( $order == "id" || $order == "title" || $order == "date" || $order == "time" || $order == "cattitle" || $order == "published" )
510
+ $order_by = " ORDER BY " . $order . " " . $asc_desc;
511
+ $query = $wpdb->prepare ("SELECT " . $wpdb->prefix . "spidercalendar_event.*, " . $wpdb->prefix . "spidercalendar_event_category.title as cattitle FROM " . $wpdb->prefix . "spidercalendar_event LEFT JOIN " . $wpdb->prefix . "spidercalendar_event_category ON " . $wpdb->prefix . "spidercalendar_event.category=" . $wpdb->prefix . "spidercalendar_event_category.id WHERE calendar=%d " . $where . $order_by." LIMIT %d,20", $calendar_id, $limit);
 
512
  $rows = $wpdb->get_results($query);
513
  $cal_name = $wpdb->get_var($wpdb->prepare('SELECT title' . ' FROM ' . $wpdb->prefix . 'spidercalendar_calendar WHERE `id`="%d"', $calendar_id));
514
  html_show_spider_event($rows, $pageNav, $sort, $calendar_id, $cal_name);
elements/calendar-jos.css CHANGED
@@ -1,10 +1,11 @@
1
  .uninstall_icon {
2
- background: url("buttons.png") no-repeat 0% 75%;
3
  border: none;
4
  height: 42px;
5
  width: 37px;
6
  display: inline-block;
7
  vertical-align: middle;
 
8
  }
9
 
10
  .uninstall-banner .logo-title {
@@ -20,7 +21,6 @@
20
  .uninstall-banner {
21
  background: #fff;
22
  display: block;
23
- padding: 15px 10px;
24
  height: 38px;
25
  }
26
 
@@ -243,4 +243,88 @@ div.calendar {
243
  position: absolute;
244
  left: 31px;
245
  top: 0px;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
246
  }
1
  .uninstall_icon {
2
+ background: url(buttons.png) no-repeat 0% 75%;
3
  border: none;
4
  height: 42px;
5
  width: 37px;
6
  display: inline-block;
7
  vertical-align: middle;
8
+ background-size: 100%;
9
  }
10
 
11
  .uninstall-banner .logo-title {
21
  .uninstall-banner {
22
  background: #fff;
23
  display: block;
 
24
  height: 38px;
25
  }
26
 
243
  position: absolute;
244
  left: 31px;
245
  top: 0px;
246
+ }
247
+
248
+ /************* upgrade to pro ******************/
249
+
250
+ .sp_calendar_upgrade{
251
+ clear: both;
252
+ padding: 15px;
253
+ background: #fff;
254
+ margin: 6px 15px 6px 0px;
255
+ color: #6e7990;
256
+ font-size: 14px;
257
+ font-weight: bold;
258
+ line-height: 30px;
259
+ }
260
+
261
+ .sp_calendar_upgrade .wd-cell:first-child{
262
+ padding-right: 14px;
263
+ }
264
+
265
+ .sp_calendar_upgrade .wd-cell:last-child{
266
+ background: #45A6B7;
267
+ }
268
+ .sp_calendar_upgrade .wd-cell:last-child a{
269
+ color: #fff !important;
270
+ padding: 18px;
271
+ }
272
+
273
+
274
+ .sp_calendar_upgrade .wd-cell:first-child{
275
+ background: transparent
276
+ }
277
+ .sp_calendar_upgrade .wd-cell:first-child img{
278
+ vertical-align:middle;
279
+ }
280
+ .sp_calendar_upgrade .wd-cell:first-child a{
281
+ color: #72777c !important;
282
+ }
283
+ .sp_calendar_upgrade a, .sp_calendar_upgrade a:hover {
284
+ text-decoration: none !important;
285
+ }
286
+
287
+ /* general styles */
288
+
289
+ .wd-cell{
290
+ display:table-cell;
291
+ }
292
+ .wd-cell-valign-middle{
293
+ vertical-align:middle;
294
+ }
295
+ .wd-cell-valign-top{
296
+ vertical-align:top;
297
+ }
298
+ .wd-cell-valign-bottom{
299
+ vertical-align:bottom;
300
+ }
301
+ .wd-table{
302
+ display:table;
303
+ }
304
+ .wd-text-right{
305
+ text-align:right;
306
+ }
307
+ .wd-text-left{
308
+ text-align:left;
309
+ }
310
+ .wd-text-center{
311
+ text-align:center;
312
+ }
313
+ .wd-left{
314
+ float:left;
315
+ }
316
+ .wd-right{
317
+ float:right;
318
+ }
319
+ .wd-clear:after{
320
+ clear:both;
321
+ content:"";
322
+ display:table;
323
+ }
324
+ .wd-row{
325
+ margin-bottom:15px;
326
+ }
327
+
328
+ a:focus{
329
+ box-shadow: none;
330
  }
images/i_support.png ADDED
Binary file
notices.php DELETED
@@ -1,33 +0,0 @@
1
- <?php
2
-
3
- if ( ! defined( 'ABSPATH' ) ) exit;
4
-
5
- function sc_admin_notices( $notices ) {
6
- $two_week_review_ignore = add_query_arg( array( 'sc_admin_notice_ignore' => 'two_week_review' ) );
7
- $two_week_review_temp = add_query_arg( array( 'sc_admin_notice_temp_ignore' => 'two_week_review', 'int' => 14 ) );
8
- $notices['two_week_review'] = array(
9
- 'title' => __( 'Leave A Review?', 'sc_admin_notice' ),
10
- 'msg' => __( 'We hope you\'ve enjoyed using WordPress Spider Calendar! Would you consider leaving us a review on WordPress.org?', 'sc_admin_notice' ),
11
- 'link' => '<li><span class="dashicons dashicons-external"></span><a href="https://wordpress.org/support/view/plugin-reviews/spider-event-calendar" target="_blank">' . __( 'Sure! I\'d love to!', 'sc_admin_notice' ) . '</a></li>
12
- <li> <span class="dashicons dashicons-smiley"></span><a href="' . $two_week_review_ignore . '"> ' . __( 'I\'ve already left a review', 'sc_admin_notice' ) . '</a></li>
13
- <li><span class="dashicons dashicons-calendar-alt"></span><a href="' . $two_week_review_temp . '">' . __( 'Maybe Later' ,'sc_admin_notice' ) . '</a></li>
14
- <li><span class="dashicons dashicons-dismiss"></span><a href="' . $two_week_review_ignore . '">' . __( 'Never show again' ,'sc_admin_notice' ) . '</a></li>',
15
- 'later_link' => $two_week_review_temp,
16
- 'int' => 14
17
- );
18
-
19
- $one_week_support = add_query_arg( array( 'sc_admin_notice_ignore' => 'one_week_support' ) );
20
- $notices['one_week_support'] = array(
21
- 'title' => __( 'Hey! How\'s It Going?', 'spider-event-calendar' ),
22
- 'msg' => __( 'Thank you for using WordPress Spider Calendar! We hope that you\'ve found everything you need, but if you have any questions:', 'spider-event-calendar' ),
23
- 'link' => '<li><span class="dashicons dashicons-media-text"></span><a target="_blank" href="https://web-dorado.com/wordpress-spider-calendar/installing.html">' . __( 'Check out User Guide', 'spider-event-calendar' ) . '</a></li>
24
- <li><span class="dashicons dashicons-sos"></span><a target="_blank" href="https://web-dorado.com/forum/spider-calendar-wordpress.html">' . __( 'Get Some Help' ,'spider-event-calendar' ) . '</a></li>
25
- <li><span class="dashicons dashicons-dismiss"></span><a href="' . $one_week_support . '">' . __( 'Never show again' ,'spider-event-calendar' ) . '</a></li>',
26
- 'int' => 7
27
- );
28
-
29
- return $notices;
30
- }
31
-
32
- add_filter( 'sc_admin_notices', 'sc_admin_notices' );
33
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
readme.txt CHANGED
@@ -1,17 +1,17 @@
1
  === Calendar by WD – Responsive Event Calendar for WordPress ===
2
  Contributors: webdorado
3
  Donate link: https://web-dorado.com/products/wordpress-calendar.html
4
- Tags: calendar, responsive calendar, event, event calendar, events, events calendar, meeting, organizer, recurring, reservation, responsive, schedule
5
  Requires at least: 3.4
6
- Tested up to: 4.7
7
- Stable tag: 1.5.51
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
11
- Event Calendar plugin is a highly configurable product which allows you to have multiple organized events.
12
 
13
  == Description ==
14
- WordPress event calendar is a FREE user-friendly responsive plugin to manage multiple recurring events and with various options.
15
 
16
  [WordPress Calendar](https://web-dorado.com/products/wordpress-calendar.html)
17
  [Demo](http://wpdemo.web-dorado.com/spider-calendar/)
@@ -19,11 +19,20 @@ WordPress event calendar is a FREE user-friendly responsive plugin to manage mul
19
  [User Manual](https://web-dorado.com/spider-calendar-wordpress-guide-step-1.html)
20
 
21
 
22
- Spider Event Calendar is a highly configurable plugin which allows you to have multiple organized events in a calendar. This plugin is one of the best WordPress Calendar available in WordPress Directory. If you have problem with organizing your WordPress Calendar events and displaying them in a calendar format, then Spider Wordpress Calendar Plugin is the best solution. Maybe you just want to have a quick look at your calendar to remind yourself about the future appointments? It will be great if calendar extension will be able to show all events, display them in a widget as a beautiful and customizable calendar on your website. Spider WordPress Calendar is an extraordinary user friendly calendar.
23
- There is also a possibility of displaying the events in a list view. The product includes a widget called Upcoming events, allowing to have a specific number of upcoming events arranged in ordered or randomized option.
 
 
24
  Possibility to add multiple events for a single date, including events from different categories.
25
- You can display the calendar in a smaller format for all pages using the Calendar widget.
26
- Different categories created for the calendar will be displayed as a legend below the calendar. This will allow the users to manage the types of the events they are looking for.
 
 
 
 
 
 
 
27
 
28
  = Features of Spider Event Calendar: =
29
 
@@ -142,6 +151,10 @@ Vietnamese (vi)
142
 
143
  == Changelog ==
144
 
 
 
 
 
145
  = 1.5.51 =
146
  Removed: Featured plugins, themes page
147
 
@@ -363,7 +376,9 @@ If you want to update the calendar plugin while preserving your existing calenda
363
  -Repeat until. Choose the end date for repeating each event.
364
  3.10 Save. Click the "Save" button to save the created event.
365
 
 
366
 
 
367
 
368
 
369
  == Step 4:Spider Event Calendar ==
@@ -571,4 +586,5 @@ Select events from list.Click on Add button to specify the events you want to sh
571
  8.20 Save the widget.
572
 
573
 
 
574
 
1
  === Calendar by WD – Responsive Event Calendar for WordPress ===
2
  Contributors: webdorado
3
  Donate link: https://web-dorado.com/products/wordpress-calendar.html
4
+ Tags: calendar, date, event, event calendar, events, events calendar, meeting, organizer, recurring, reservation, responsive, schedule, calendars, event manager, calendar widget, event registration, event management, agenda, holiday calendar , scheduling, free calendar, Calender, upcoming events , event widget , event list, calendar localization, editorial calendar, Interactive Calendar, news calendar, appointment, event tracking, event organizer, upcoming events widget, event page, event bookings, recurring events, conference, dates, times, venue, responsive calendar, seminar, summit, facebook integration, widget, online calendar, calendar shortcode, events list, custom calendar, google calendar, event subscription, ical, facebook event calendar, event filter, calendar manager, online reservation, booking calendar, event booking, reservation calendar, customizable calendar, upcoming events calendar, events feed, event ticketing, rsvp, tickets, bookings
5
  Requires at least: 3.4
6
+ Tested up to: 4.8
7
+ Stable tag: 1.5.52
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
11
+ Event Calendar by WD is a responsive calendar plugin for organizing events. This calendar calendar lets you manage and publish unlimited event calendars on your site.
12
 
13
  == Description ==
14
+ WordPress event calendar is a FREE user-friendly responsive calendar plugin to manage multiple recurring events and various display options. This free calendar plugin makes event registration and events management easy and lets you display beautiful responsive calendars, upcoming events and calendar widget. It’s perfect for websites organising seminars,summits, conferences, concerts,meetings, who want to have it displayed in an attractive calendar.
15
 
16
  [WordPress Calendar](https://web-dorado.com/products/wordpress-calendar.html)
17
  [Demo](http://wpdemo.web-dorado.com/spider-calendar/)
19
  [User Manual](https://web-dorado.com/spider-calendar-wordpress-guide-step-1.html)
20
 
21
 
22
+ Spider Event Calendar is a highly configurable calendar plugin which allows you to have multiple organized events in one calendar. This plugin is one of the best WordPress Calendar available in WordPress Directory. If you have problem with organizing your WordPress Calendar events and displaying them in a calendar format, then Spider WordPress Calendar Plugin is the best solution. Maybe you just want to have a quick look at your WP calendar schedule to remind yourself about the future appointments or online reservations? Or you want to bring together your holiday calendar, web calendars, online calendars and events lists? Spider Calendar event plugin comes with advanced calendar manager tools and options. It will be great if calendar extension will be able to show all events, display them in an events widget as a beautiful and customizable calendar on your website. Spider WordPress Calendar is a great online events organizer and events manager plugin which is also an extremely user friendly calendar. It’s a feature rich event manager plugin allowing you to use it as an editorial calendar,news calendar or availability calendar.
23
+
24
+ You can add unlimited number of calendars and events on your website. You can have a separate upcoming events calendar on any page you’d like.
25
+ There is also a possibility of displaying the events in a list view. The product includes a widget called Upcoming events, allowing to have a specific number of upcoming events arranged in ordered or randomized option.
26
  Possibility to add multiple events for a single date, including events from different categories.
27
+ You can display the calendar in a smaller format for all pages using the Calendar widget.
28
+ Different categories created for the calendar will be displayed as a legend below the calendar. This will allow the users to manage the types of the events they are looking for.
29
+
30
+
31
+ This advanced events plugin allows you to provide detailed information about the events you have in your interactive calendar. You can provide event dates, time, venue, mention the event organizers, upload an image or a video for a particular event, and more. If you have an event page on your website you can use the calendar shortcode or event shortcode to display it on the page. Also, that can be a very good place to display an upcoming events widget. For websites with long events lists there is an event filter option in the front end to help your site visitors filter out events they are not interested in.
32
+
33
+ Its recurring events option makes event scheduling even easier. You just need to provide the repeating rate of the event and it will automatically be displayed on the calendar.
34
+ Spider Calendar comes with a number of event display options, and calendar themes, but if you want to have custom calendars with your own style you can add new themes with customized settings and options.
35
+
36
 
37
  = Features of Spider Event Calendar: =
38
 
151
 
152
  == Changelog ==
153
 
154
+ = 1.5.52 =
155
+ Fixed: Security issue
156
+ Added: Overview page
157
+
158
  = 1.5.51 =
159
  Removed: Featured plugins, themes page
160
 
376
  -Repeat until. Choose the end date for repeating each event.
377
  3.10 Save. Click the "Save" button to save the created event.
378
 
379
+ Note: Spider Event Calendar is not an online booking calendar and does not come with a booking system or reservation system. It does not support event bookings or event subscriptions. However you can manually add your bookings, Facebook calendar events, outlook appointments, Icalendar ( Ical ) appointment booking, and other events feed to the calendar. If you want to have booking forms, RSVP functionality, Facebook event calendar, or Google Calendar integration, you’ll have to get an appointment booking calendar, a booking plugin or other reservation plugin.
380
 
381
+ It does not support ticket integration,event ticketing and ticket sale. For this purpose you can check out Event Calendar WD, which allows you to sale event tickets and also provides events calendars Google maps integration. With its events gmap option you’ll be able to mark event location on Google maps.
382
 
383
 
384
  == Step 4:Spider Event Calendar ==
586
  8.20 Save the widget.
587
 
588
 
589
+
590
 
spider_calendar_admin_class.php DELETED
@@ -1,47 +0,0 @@
1
- <?php
2
-
3
- class SC_Admin {
4
- public static $instance = null;
5
- protected $version = '1.5.51';
6
- public $prefix = "sc_";
7
- protected $notices = null;
8
- public static function get_instance() {
9
- if ( null == self::$instance ) {
10
- self::$instance = new self;
11
- }
12
-
13
- return self::$instance;
14
- }
15
-
16
- private function __construct() {
17
- $this->notices = new SC_Notices();
18
- add_action( 'admin_init', array( $this, 'admin_notice_ignore' ) );
19
- add_action( 'admin_notices', array($this, 'sc_admin_notices') );
20
- }
21
-
22
- function sc_admin_notices( ) {
23
- // Notices filter and run the notices function.
24
-
25
- $admin_notices = apply_filters( 'sc_admin_notices', array() );
26
- $this->notices->admin_notice( $admin_notices );
27
-
28
- }
29
-
30
- // Ignore function that gets ran at admin init to ensure any messages that were dismissed get marked
31
- public function admin_notice_ignore() {
32
-
33
- $slug = ( isset( $_GET['sc_admin_notice_ignore'] ) ) ? $_GET['sc_admin_notice_ignore'] : '';
34
- // If user clicks to ignore the notice, run this action
35
- if ( isset($_GET['sc_admin_notice_ignore']) && current_user_can( 'manage_options' ) ) {
36
-
37
- $admin_notices_option = get_option( 'sc_admin_notice', array() );
38
- $admin_notices_option[ $_GET[ 'sc_admin_notice_ignore' ] ][ 'dismissed' ] = 1;
39
- update_option( 'sc_admin_notice', $admin_notices_option );
40
- $query_str = remove_query_arg( 'sc_admin_notice_ignore' );
41
- wp_redirect( $query_str );
42
- exit;
43
- }
44
- }
45
- }
46
-
47
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
spider_calendar_notices_class.php DELETED
@@ -1,219 +0,0 @@
1
- <?php
2
-
3
- if ( ! defined( 'ABSPATH' ) ) {
4
- exit;
5
- }
6
-
7
- /**
8
- * SC_Notices Class
9
- **/
10
- class SC_Notices {
11
- static $instance;
12
-
13
- public static function instance() {
14
- if ( ! isset( self::$instance ) ) {
15
- self::$instance = new SC_Notices();
16
- }
17
-
18
- return self::$instance;
19
- }
20
-
21
- public $notice_spam = 0;
22
- public $notice_spam_max = 1;
23
-
24
- // Basic actions to run
25
- public function __construct() {
26
-
27
- // Runs the admin notice ignore function incase a dismiss button has been clicked
28
- add_action( 'admin_init', array( $this, 'admin_notice_ignore' ) );
29
-
30
- // Runs the admin notice temp ignore function incase a temp dismiss link has been clicked
31
- add_action( 'admin_init', array( $this, 'admin_notice_temp_ignore' ) );
32
-
33
- }
34
-
35
- // Checks to ensure notices aren't disabled and the user has the correct permissions.
36
- public function sc_admin_notice() {
37
-
38
- $sc_settings = get_option( 'sc_admin_notice' );
39
- if ( ! isset( $sc_settings['disable_admin_notices'] ) || ( isset( $sc_settings['disable_admin_notices'] ) && $sc_settings['disable_admin_notices'] == 0 ) ) {
40
- if ( current_user_can( 'manage_options' ) ) {
41
- return true;
42
- }
43
- }
44
-
45
- return false;
46
-
47
- }
48
-
49
- // Primary notice function that can be called from an outside function sending necessary variables
50
- public function admin_notice( $admin_notices ) {
51
- global $wd_spider_calendar_version;
52
- // Check options
53
- if ( ! $this->sc_admin_notice() ) {
54
- return false;
55
- }
56
-
57
- foreach ( $admin_notices as $slug => $admin_notice ) {
58
- // Call for spam protection
59
- if ( $this->anti_notice_spam() ) {
60
- return false;
61
- }
62
-
63
- // Check for proper page to display on
64
- if ( isset( $admin_notices[ $slug ]['pages'] ) && is_array( $admin_notices[ $slug ]['pages'] ) ) {
65
- if ( ! $this->admin_notice_pages( $admin_notices[ $slug ]['pages'] ) ) {
66
- return false;
67
- }
68
- }
69
- // Check for required fields
70
- if ( ! $this->required_fields( $admin_notices[ $slug ] ) ) {
71
- // Get the current date then set start date to either passed value or current date value and add interval
72
- $current_date = current_time( "n/j/Y" );
73
- $start = ( isset( $admin_notices[ $slug ]['start'] ) ? $admin_notices[ $slug ]['start'] : $current_date );
74
- $start = date( "n/j/Y", strtotime( $start ) );
75
- $date_array = explode( '/', $start );
76
- $interval = ( isset( $admin_notices[ $slug ]['int'] ) ? $admin_notices[ $slug ]['int'] : 0 );
77
- $date_array[1] += $interval;
78
- $start = date( "n/j/Y", mktime( 0, 0, 0, $date_array[0], $date_array[1], $date_array[2] ) );
79
-
80
- // This is the main notices storage option
81
- $admin_notices_option = get_option( 'sc_admin_notice', array() );
82
- // Check if the message is already stored and if so just grab the key otherwise store the message and its associated date information
83
- if ( ! array_key_exists( $slug, $admin_notices_option ) ) {
84
- $admin_notices_option[ $slug ]['start'] = $start;
85
- $admin_notices_option[ $slug ]['int'] = $interval;
86
- update_option( 'sc_admin_notice', $admin_notices_option );
87
- }
88
-
89
- // Sanity check to ensure we have accurate information
90
- // New date information will not overwrite old date information
91
- $admin_display_check = ( isset( $admin_notices_option[ $slug ]['dismissed'] ) ? $admin_notices_option[ $slug ]['dismissed'] : 0 );
92
-
93
- $admin_display_start = ( isset( $admin_notices_option[ $slug ]['start'] ) ? $admin_notices_option[ $slug ]['start'] : $start );
94
- $admin_display_interval = ( isset( $admin_notices_option[ $slug ]['int'] ) ? $admin_notices_option[ $slug ]['int'] : $interval );
95
- $admin_display_msg = ( isset( $admin_notices[ $slug ]['msg'] ) ? $admin_notices[ $slug ]['msg'] : '' );
96
- $admin_display_title = ( isset( $admin_notices[ $slug ]['title'] ) ? $admin_notices[ $slug ]['title'] : '' );
97
- $admin_display_link = ( isset( $admin_notices[ $slug ]['link'] ) ? $admin_notices[ $slug ]['link'] : '' );
98
- $output_css = false;
99
- // Ensure the notice hasn't been hidden and that the current date is after the start date
100
- if ($admin_display_check == 0 && strtotime( $admin_display_start ) <= strtotime( $current_date )) {
101
-
102
- // Get remaining query string
103
- $query_str = (isset($admin_notices[$slug]['later_link']) ? $admin_notices[$slug]['later_link'] : esc_url(add_query_arg('sc_admin_notice_ignore', $slug)));
104
- // Admin notice display output
105
- echo '<div class="update-nag sc-admin-notice">';
106
- echo '<div class="sc-notice-logo"></div>';
107
- echo ' <p class="sc-notice-title">';
108
- echo $admin_display_title;
109
- echo ' </p>';
110
- echo ' <p class="sc-notice-body">';
111
- echo $admin_display_msg;
112
- echo ' </p>';
113
- echo '<ul class="sc-notice-body sc-blue">
114
- ' . $admin_display_link . '
115
- </ul>';
116
- echo '<a href="' . $query_str . '" class="dashicons dashicons-dismiss"></a>';
117
- echo '</div>';
118
-
119
- $this->notice_spam += 1;
120
- $output_css = true;
121
- }
122
- if ( $output_css ) {
123
- wp_enqueue_style("sc-admin-notices", plugins_url('style_for_cal/notices.css', __FILE__), array(), $wd_spider_calendar_version);
124
- }
125
- }
126
- }
127
- }
128
-
129
- // Spam protection check
130
- public function anti_notice_spam() {
131
-
132
- if ( $this->notice_spam >= $this->notice_spam_max ) {
133
- return true;
134
- }
135
-
136
- return false;
137
- }
138
-
139
- // Ignore function that gets ran at admin init to ensure any messages that were dismissed get marked
140
- public function admin_notice_ignore() {
141
-
142
- // If user clicks to ignore the notice, update the option to not show it again
143
- if ( isset( $_GET['sc_admin_notice_ignore'] ) ) {
144
-
145
- $admin_notices_option = get_option( 'sc_admin_notice', array() );
146
- $admin_notices_option[ $_GET['sc_admin_notice_ignore'] ]['dismissed'] = 1;
147
- update_option( 'sc_admin_notice', $admin_notices_option );
148
- $query_str = remove_query_arg( 'sc_admin_notice_ignore' );
149
- wp_redirect( $query_str );
150
- exit;
151
- }
152
- }
153
-
154
- // Temp Ignore function that gets ran at admin init to ensure any messages that were temp dismissed get their start date changed
155
- public function admin_notice_temp_ignore() {
156
-
157
- // If user clicks to temp ignore the notice, update the option to change the start date - default interval of 14 days
158
- if ( isset( $_GET['sc_admin_notice_temp_ignore'] ) ) {
159
-
160
- $admin_notices_option = get_option( 'sc_admin_notice', array() );
161
-
162
- $current_date = current_time( "n/j/Y" );
163
- $date_array = explode( '/', $current_date );
164
- $interval = ( isset( $_GET['sc_int'] ) ? $_GET['sc_int'] : 14 );
165
- $date_array[1] += $interval;
166
- $new_start = date( "n/j/Y", mktime( 0, 0, 0, $date_array[0], $date_array[1], $date_array[2] ) );
167
-
168
- $admin_notices_option[ $_GET['sc_admin_notice_temp_ignore'] ]['start'] = $new_start;
169
- $admin_notices_option[ $_GET['sc_admin_notice_temp_ignore'] ]['dismissed'] = 0;
170
- update_option( 'sc_admin_notice', $admin_notices_option );
171
- $query_str = remove_query_arg( array( 'sc_admin_notice_temp_ignore', 'sc_int' ) );
172
- wp_redirect( $query_str );
173
- exit;
174
- }
175
- }
176
-
177
- public function admin_notice_pages( $pages ) {
178
-
179
- foreach ( $pages as $key => $page ) {
180
- if ( is_array( $page ) ) {
181
- if ( isset( $_GET['page'] ) && $_GET['page'] == $page[0] && isset( $_GET['tab'] ) && $_GET['tab'] == $page[1] ) {
182
- return true;
183
- }
184
- } else {
185
- if ( $page == 'all' ) {
186
- return true;
187
- }
188
- if ( get_current_screen()->id === $page ) {
189
- return true;
190
- }
191
- if ( isset( $_GET['page'] ) && $_GET['page'] == $page ) {
192
- return true;
193
- }
194
- }
195
-
196
- return false;
197
- }
198
- }
199
-
200
- // Required fields check
201
- public function required_fields( $fields ) {
202
- if ( ! isset( $fields['msg'] ) || ( isset( $fields['msg'] ) && empty( $fields['msg'] ) ) ) {
203
- return true;
204
- }
205
-
206
- if ( ! isset( $fields['title'] ) || ( isset( $fields['title'] ) && empty( $fields['title'] ) ) ) {
207
- return true;
208
- }
209
-
210
- return false;
211
- }
212
-
213
- // Special parameters function that is to be used in any extension of this class
214
- public function special_parameters( $admin_notices ) {
215
- // Intentionally left blank
216
- }
217
-
218
- }
219
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
wd/README.md ADDED
@@ -0,0 +1,129 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Version: 1.0.7
2
+
3
+
4
+ Usage:
5
+
6
+ Copy and paste wd library into your plugin folder.
7
+ In your plugin main file check if library main DoradoWeb class doesn't exist, include it
8
+ if( !class_exists("DoradoWeb") ){
9
+ require_once(PATH_TO_YOUR_PLUGIN_DIR . '/wd/start.php');
10
+ }
11
+
12
+ Then call dorado_web_init($options) function.
13
+ $options = array (
14
+ "prefix" => "your_plugin_prefix",
15
+ "wd_plugin_id" => your_plugin_id,
16
+ "plugin_title" => "your plugin titile",
17
+ "plugin_wordpress_slug" => "your plugin wordpress slug",
18
+ "plugin_dir" => 'path to your plugin dir',
19
+ "plugin_main_file" => 'path to your plugin main file',
20
+ "description" => 'your plugin description',
21
+
22
+ "plugin_features" => array(
23
+ 0 => array(
24
+ "title" => "feature title 1",
25
+ "description" => "feature 1 description",
26
+ ),
27
+ 1 => array(
28
+ "title" => "feature title 2",
29
+ "description" => "feature 2 description",
30
+ ),
31
+ ...
32
+ ),
33
+ "user_guide" => array(
34
+ 0 => array(
35
+ "main_title" => "user guide step 1",
36
+ "url" => "link to step 1",
37
+ "titles" => array(
38
+ array(
39
+ "title" => "step 1 sub title",
40
+ "url" => "link to step 1 sub"
41
+ )
42
+ )
43
+ ),
44
+ ...
45
+ ),
46
+ "overview_welcome_image" => null,
47
+ "video_youtube_id" => "your plugin youtube video id", // e.g. https://www.youtube.com/watch?v=acaexefeP7o youtube id is the acaexefeP7o
48
+ "plugin_wd_url" => "https://web-dorado.com/products/your plugin",
49
+ "plugin_wd_demo_link" => "http://wpdemo.web-dorado.com/your plugin",
50
+ "plugin_wd_addons_link" => "https://web-dorado.com/products/your plugin addons",
51
+ "after_subscribe" => "after subsribe page", // this can be plagin overview page or set up page admin.php?page=overview_YOUR_PREFIX
52
+ "plugin_wizard_link" => "your plugin wizard page",
53
+ "plugin_menu_title" => "Your plugin menu title",
54
+ "plugin_menu_icon" => "path to menu icon",
55
+ "deactivate" => true,
56
+ "subscribe" => true,
57
+ "custom_post" => false, // if true => edit.php?post_type=contact
58
+ "menu_capability" => "manage_options",
59
+ "menu_position" => null,
60
+ );
61
+
62
+ Fully documentation of dorado_web_init options:
63
+
64
+ prefix - (type string) your plugin prefix
65
+ wd_plugin_id - (type int) plugin id ( in web-dorado database, you use it for update functionality)
66
+ plugin_wd_zip_name - (type string) plugin zip name (in web-dorado database, ask Armen or Sergey )
67
+ plugin_title - type string) plugin title (
68
+ plugin_wordpress_slug - (type string) plugin slug
69
+ plugin_dir - (type string) full file path to your plugin directory
70
+ plugin_main_file - (type string) path to your plugin main file (__FILE__)
71
+ description - (type string) plugin short description
72
+
73
+ plugin_features - (type array) plugin top 5 features from web-dorado.com
74
+ e.g. (for google maps plugin)
75
+ array(
76
+ 0 => array(
77
+ "title" => __("Easy set up", "gmwd"),
78
+ "description" => __("After installation a set-up guide will help you configure general options and get started on the dashboard. The plugin also displays tooltips in the whole admin area and settings. Moreover, you get instant live previews of changes you make in the working area, so you don’t have to save and publish maps to see the results.", "gmwd"),
79
+ ),
80
+ 1 => array(
81
+ "title" => __("Unlimited Everything", "gmwd"),
82
+ "description" => __("Display unlimited maps on any page or post. Same is true for markers, rectangles, circles, polygons and polylines.", "gmwd"),
83
+ ),
84
+ ....
85
+ )
86
+
87
+ user_guide - (type array) plugin user guide links from web-dorado.com
88
+ e.g. (for google maps plugin)
89
+ array(
90
+ 0 => array(
91
+ "main_title" => __("Installation Wizard/ Options Menu", "gmwd"),
92
+ "url" => "https://web-dorado.com/wordpress-google-maps/installation-wizard-options-menu.html",
93
+ "titles" => array(
94
+ array(
95
+ "title" => __("Configuring Map API Key", "gmwd"),
96
+ "url" => "https://web-dorado.com/wordpress-google-maps/installation-wizard-options-menu/configuring-api-key.html"
97
+ )
98
+ )
99
+ ),
100
+ 1 => array(
101
+ "main_title" => __("Creating Map", "gmwd"),
102
+ "url" => "https://web-dorado.com/wordpress-google-maps/creating-map.html",
103
+ "titles" => array()
104
+ ),
105
+ )
106
+
107
+ video_youtube_id - (type string) if your plugin has video, video's id, else null
108
+ ( e.g. for https://www.youtube.com/watch?v=acaexefeP7o , youtube id is the 'acaexefeP7o' )
109
+
110
+ plugin_wd_url - (type string) plugin page url
111
+ (e.g. https://web-dorado.com/products/wordpress-google-maps-plugin.html)
112
+
113
+ plugin_wd_demo_link - (type string) plugin demo url
114
+ plugin_wd_addons_link - (type string) if plugin has addons , plugin addons link, else null
115
+ plugin_wizard_link - (type string) if plugin has wizard, wizard page , else null
116
+ ( e.g. admin_url( 'index.php?page=gmwd_setup' ) )
117
+
118
+ plugin_menu_title - (type string) plugin wordpress backend menu title
119
+ plugin_menu_icon - (type string) path to plugin wordpress backend menu icon
120
+ ( e.g. GMWD_URL . '/images/icon-map-20.png' )
121
+ deactivate - (type bool) if plugin free deactivate = true, else deactivate = false
122
+ subscribe - (type bool) if plugin free subscribe = true, else subscribe = false
123
+ custom_post - ( type string) if plugin has not custom posts it must be top level menu slug, else toplevel menu url , e.g. edit.php?post_type=contact
124
+ menu_capability - (type string) top level menu capability e.g. manage_options
125
+ menu_position - (type string) top level menu position , default is null
126
+
127
+
128
+
129
+
wd/assets/css/deactivate_popup.css ADDED
@@ -0,0 +1,86 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .wd-opacity{
2
+ position: fixed;
3
+ top: 0px;
4
+ bottom: 0px;
5
+ left: 0px;
6
+ right: 0px;
7
+ z-index: 9999;
8
+ background: #000;
9
+ opacity: 0.5;
10
+ display: none;
11
+ }
12
+
13
+ .wd-deactivate-popup{
14
+ position: fixed;
15
+ top: 0px;
16
+ bottom: 0px;
17
+ left: 0px;
18
+ right: 0px;
19
+ background: #fff;
20
+ z-index: 999999;
21
+ width: 600px;
22
+ height: 281px;
23
+ margin: auto;
24
+ display: none;
25
+ box-sizing: border-box;
26
+ }
27
+
28
+
29
+ .wd-deactivate-popup-header{
30
+ border-bottom: 1px solid #ccc;
31
+ padding: 18px 40px;
32
+ font-size: 16px;
33
+ background: rgba(221, 221, 221, 0.14);
34
+ }
35
+ .wd-deactivate-popup-body{
36
+ padding: 20px 40px;
37
+ border-bottom: 1px solid #ccc;
38
+ }
39
+ .wd-deactivate-popup-body input[type=text]{
40
+ width: 220px;
41
+ }
42
+ .wd-deactivate-popup-body textarea{
43
+ width: 100%;
44
+ }
45
+
46
+ .wd-btns{
47
+ position: absolute;
48
+ bottom: 19px;
49
+ right: 19px
50
+ }
51
+
52
+ .additional_details_wrap{
53
+ margin-top: 20px;
54
+ }
55
+
56
+ .wd-additional-active{
57
+ background: rgba(204, 204, 204, 0.18);
58
+ padding: 15px;
59
+ margin: 14px 0px 5px;
60
+ }
61
+ .wd-popup-active1{
62
+ height: 523px !important;
63
+ }
64
+
65
+ .wd-popup-active2{
66
+ height: 426px !important
67
+ }
68
+ .wd-deactivate-popup-opacity{
69
+ width: 100%;
70
+ height: 100%;
71
+ background: #D9D9D9;
72
+ opacity: 0.3;
73
+ z-index: 45;
74
+ position: absolute;
75
+ display: none;
76
+ }
77
+
78
+ .wd-deactivate-popup-opacity .wd-img-loader{
79
+ position: absolute;
80
+ top: 0;
81
+ left: 0;
82
+ right: 0;
83
+ bottom: 0;
84
+ margin: auto;
85
+ z-index: 63;
86
+ }
wd/assets/css/img/allow&continue.png ADDED
Binary file
wd/assets/css/img/coupon_bg.png ADDED
Binary file
wd/assets/css/img/plugins_header_bg.png ADDED
Binary file
wd/assets/css/img/skip.png ADDED
Binary file
wd/assets/css/img/themes_headrer_bg.png ADDED
Binary file
wd/assets/css/img/ug-icon-1.png ADDED
Binary file
wd/assets/css/img/ug-icon-2.png ADDED
Binary file
wd/assets/css/img/ug-icon-3.png ADDED
Binary file
wd/assets/css/img/ug-icon-4.png ADDED
Binary file
wd/assets/css/img/ug-icon-5.png ADDED
Binary file
wd/assets/css/img/welcome_bg.png ADDED
Binary file
wd/assets/css/notices.css ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .wd-admin-notice {
2
+ background: #fff;
3
+ border: 4px;
4
+ display: block;
5
+ min-height: 68px;
6
+ padding: 10px 40px 10px 125px;
7
+ position: relative;
8
+ }
9
+ .wd-admin-notice a {
10
+ color: #10738B;
11
+ }
12
+ .wd-notice-logo {
13
+ clear: both;
14
+ content: "";
15
+ display: block;
16
+ background-size: 108px auto;
17
+ background-repeat: no-repeat;
18
+ background-position: 0 45%;
19
+ width: 125px;
20
+ position: absolute;
21
+ top: 0;
22
+ bottom: 0;
23
+ left: 5px;
24
+ }
25
+ .wd-admin-notice > .dashicons {
26
+ color: #424242;
27
+ position: absolute;
28
+ right: 20px;
29
+ top: 40%;
30
+ }
31
+ .wd-notice-title {
32
+ font-size: 24px;
33
+ margin: 0;
34
+ }
35
+ .wd-notice-body {
36
+ font-weight: normal;
37
+ margin: 5px 0;
38
+ }
39
+ .wd-notice-body:after {
40
+ clear: both;
41
+ content: "";
42
+ display: block;
43
+ }
44
+ .wd-notice-body li {
45
+ float: left;
46
+ margin-right: 20px;
47
+ }
48
+ .wd-notice-body .dashicons {
49
+ font-size: 17px;
50
+ }
51
+ .wd-blue {
52
+ color: #10738B;
53
+ }
54
+
55
+ .admin-notice-promo {
56
+ background: #fff;
57
+ border-top: 4px;
58
+ display: block;
59
+ min-height: 68px;
60
+ padding: 10px 40px 0px 10px;
61
+ margin: 10px 0;
62
+ position: relative;
63
+ }
64
+
65
+ .admin-notice-promo:after {
66
+ content: '';
67
+ display: table;
68
+ clear: both;
69
+ }
70
+
71
+ .close-promo {
72
+ position: absolute;
73
+ top: 5px;
74
+ right: 5px;
75
+ }
76
+
77
+ .promo {
78
+ background-position: center;
79
+ background-repeat: no-repeat;
80
+ background-size: 972px 200px;
81
+ height: 200px;
82
+ max-width: 100%;
83
+ }
84
+
85
+ .promo a {
86
+ display: block;
87
+ height: 100%;
88
+ }
wd/assets/css/overview.css ADDED
@@ -0,0 +1,455 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* general */
2
+ .wd-table{
3
+ display: table;
4
+ width: 100%;
5
+ }
6
+ .wd-cell{
7
+ display: table-cell;
8
+ }
9
+ .wd-valign-top{
10
+ vertical-align: top;
11
+ }
12
+ .wd-valign-middle{
13
+ vertical-align: middle;
14
+ }
15
+ .wd-valign-bottom{
16
+ vertical-align: bottom;
17
+ }
18
+ .wd-text-right{
19
+ text-align: right;
20
+ }
21
+ .wd-text-center{
22
+ text-align: center;
23
+ }
24
+ .hide{
25
+ display: none;
26
+ }
27
+ a:focus{
28
+ border: none !important;
29
+ outline: none !important;
30
+ box-shadow: none !important;
31
+ }
32
+
33
+ /*end general */
34
+ .wd-video_container{
35
+ text-align: center;
36
+ }
37
+ .overview_welcome{
38
+ background: url(img/welcome_bg.png) no-repeat;
39
+ margin: 21px 0px;
40
+ background-size: 100% 100%;
41
+ line-height: 28px;
42
+ }
43
+ .overview_welcome .wd-cell{
44
+ padding: 15px;
45
+ }
46
+ .overview_welcome .wd-cell:first-child{
47
+ position: relative;
48
+ }
49
+
50
+ .overview_welcome h2{
51
+ text-transform: uppercase;
52
+ font-size: 26px;
53
+ margin-top: 0;
54
+ margin-bottom: 15px;
55
+ color: #424141;
56
+ }
57
+ .overview_welcome img{
58
+ width: 120px;
59
+ padding-right: 100px;
60
+ padding-left: 25px;
61
+ }
62
+ .overview_wrap{
63
+ width: 935px;
64
+ background: #fff;
65
+ }
66
+ .overview_welcome .overview_welcome_text{
67
+ font-size: 15px;
68
+ color: #424141;
69
+ }
70
+ .overview_tabs:after, .deals_content:after, .deal_desc_footer:after{
71
+ content: "";
72
+ display: table;
73
+ clear: both;
74
+ }
75
+ .overview_tabs li{
76
+ float: left;
77
+ width: 16.666%;
78
+ }
79
+
80
+ .overview_tabs li a{
81
+ text-decoration: none !important;
82
+ color: #000;
83
+ background: #D6D6D6;
84
+ background: -webkit-linear-gradient(#D6D6D6, #D7D7D7, #D6D6D6); /* For Safari 5.1 to 6.0 */
85
+ background: -o-linear-gradient(#D6D6D6, #D7D7D7, #D6D6D6); /* For Opera 11.1 to 12.0 */
86
+ background: -moz-linear-gradient(#D6D6D6, #D7D7D7, #D6D6D6); /* For Firefox 3.6 to 15 */
87
+ background: linear-gradient(#D6D6D6, #D7D7D7, #D6D6D6); /* Standard syntax */
88
+ text-transform: uppercase;
89
+ display: block;
90
+ padding: 7px 10px;
91
+ text-align: center;
92
+ font-weight: bold;
93
+ border-top: 4px solid #F1F1F1;
94
+ position: relative;
95
+ top: -4px;
96
+ }
97
+ .overview_tabs li a:hover,.overview_tabs li a:active, .overview_tabs li a:focus, .overview_tab_active{
98
+ background: #fff !important;
99
+ border-top: 4px solid #2A495F !important;
100
+
101
+ }
102
+ #welcome, #user_guide, #support, .deals_content{
103
+ padding: 15px 10px;
104
+ background: #fff;
105
+ }
106
+ .plugin_feature_title{
107
+ font-size: 19px;
108
+ }
109
+ .more_features_wrap{
110
+ margin-top: 25px;
111
+ text-align: right;
112
+ }
113
+ .more_features, .more_features:hover, .more_features:focus{
114
+ color: #fff;
115
+ background: #00384F;
116
+ padding: 3px 15px;
117
+ text-decoration: none;
118
+ }
119
+ .user_guide_item{
120
+ margin-bottom: 19px;
121
+ }
122
+ .user_guide_title, .user_guide_title:hover, .user_guide_title:focus{
123
+ font-size: 16px;
124
+ color: #192D3B;
125
+ font-weight: bold;
126
+ margin-bottom: 5px;
127
+ text-decoration: none;
128
+ }
129
+ .user_guide_titles, .user_guide_titles:hover, .user_guide_titles:focus{
130
+ color: #192D3B;
131
+ text-decoration: none;
132
+ }
133
+ .user_guide_demo, .user_guide_plugin, .user_guide_support_forum, .user_guide_addons, .user_guide_faq,
134
+ .user_guide_demo:hover, .user_guide_plugin:hover, .user_guide_support_forum:hover, .user_guide_addons:hover, .user_guide_faq:hover{
135
+ background-color: #F5F5F5;
136
+ background-repeat: no-repeat;
137
+ background-position: right -4px center;
138
+ border-top-left-radius: 25px;
139
+ border-bottom-left-radius: 25px;
140
+ padding: 3px 23px 3px 16px;
141
+ width: 144px;
142
+ font-weight: bold;
143
+ text-transform: uppercase;
144
+ color: #192D3B;
145
+ margin-bottom: 7px;
146
+ display: block;
147
+ text-decoration: none;
148
+ }
149
+ .user_guide_demo{
150
+ background-image: url(img/ug-icon-1.png);
151
+ }
152
+ .user_guide_plugin{
153
+ background-image: url(img/ug-icon-2.png);
154
+ }
155
+ .user_guide_support_forum{
156
+ background-image: url(img/ug-icon-3.png);
157
+ }
158
+ .user_guide_addons{
159
+ background-image: url(img/ug-icon-4.png);
160
+ }
161
+ .user_guide_faq{
162
+ background-image: url(img/ug-icon-5.png);
163
+ }
164
+
165
+ #support .wd-support-main{
166
+ width: 800px;
167
+ margin: 0 auto;
168
+ font-size: 16px;
169
+ text-align: center;
170
+ margin-bottom: 15px;
171
+
172
+ }
173
+ .wd-overview-site-deatils{
174
+ width: 800px;
175
+ background: #FBFBFB;
176
+ padding: 10px;
177
+ margin: 0 auto;
178
+ }
179
+ .wd-overview-site-deatils h2, .wd-overview-site-deatils p{
180
+ text-align: center;
181
+ }
182
+ .wd-overview-site-deatils p{
183
+ font-size: 16px;
184
+ }
185
+ .contact_us, .contact_us:hover, .contact_us:focus{
186
+ display: block;
187
+ background: #27475D;
188
+ color: #fff;
189
+ text-decoration: none;
190
+ width: 173px;
191
+ padding: 8px 0px;
192
+ text-align: center;
193
+ margin-bottom: 5px;
194
+ font-size: 16px;
195
+ margin-left: 8px;
196
+ border: 1px solid #B7B7B7;
197
+ text-transform: uppercase;
198
+ }
199
+
200
+ .support_email{
201
+ color: #F47A31;
202
+ }
203
+ .wd-site-deatils{
204
+ padding: 23px;
205
+ background: #f1f1f1;
206
+ box-sizing: border-box;
207
+ }
208
+ .wd-site-deatils textarea{
209
+ width: 100%;
210
+ }
211
+ .contact_us{
212
+ margin-left: auto !important;
213
+ margin-right: auto;
214
+ margin-top: 10px;
215
+ }
216
+ #wd-copy{
217
+ display: block;
218
+ background: #27475D;
219
+ color: #fff;
220
+ padding: 5px 8px;
221
+ text-align: center;
222
+ margin-bottom: 5px;
223
+ font-size: 14px;
224
+ border: 1px solid #B7B7B7;
225
+ cursor: pointer;
226
+ }
227
+ #plugins{
228
+ padding-bottom: 15px;
229
+ background: #fff;
230
+ }
231
+
232
+ .deals_header_plugins{
233
+ background: url(img/plugins_header_bg.png) #fff no-repeat;
234
+ }
235
+ .deals_header_themes{
236
+ background: url(img/themes_headrer_bg.png) #fff no-repeat;
237
+ }
238
+ .deals_header{
239
+ background-size: cover;
240
+ height: 241px;
241
+ }
242
+ .deals_header .wd-table .wd-cell{
243
+ position: relative;
244
+ }
245
+ .deals_header_plugins .wd-table .wd-cell{
246
+ padding: 27px 10px 10px;
247
+ }
248
+ .deals_header_themes .wd-table .wd-cell{
249
+ padding: 0px 10px 10px;
250
+ }
251
+ .deals_header_plugins .wd-table .wd-cell:first-child{
252
+ padding-left: 23px;
253
+ width: 30%;
254
+ }
255
+ .deals_header_themes .wd-table .wd-cell:first-child{
256
+ padding-left: 23px;
257
+ width: 36%;
258
+ }
259
+ .deals_header_themes .wd-table{
260
+ height: 100%
261
+ }
262
+
263
+ .titles_wrap{
264
+ display: inline-block;
265
+ }
266
+ .deals_main_title, .deals_secondary_title{
267
+ color: #00425A;
268
+ font-weight: bold;
269
+ line-height: 55px;
270
+ text-align: center;
271
+ text-transform: uppercase;
272
+ }
273
+
274
+ .deals_main_title{
275
+ font-size: 39px;
276
+ }
277
+ .deals_secondary_title{
278
+ font-size: 30px;
279
+ }
280
+
281
+ .higlight{
282
+ color: #E5682E;
283
+ }
284
+
285
+ .deals_save{
286
+ position: absolute;
287
+ right: 87px;
288
+ -webkit-transform: rotate(-27deg);
289
+ transform: rotate(-30deg);
290
+ font-weight: bold;
291
+ font-size: 39px;
292
+ color: #E5682E;
293
+ text-transform: uppercase;
294
+ }
295
+ .deals_header_plugins .deals_save{
296
+ bottom: 37px;
297
+ }
298
+ .deals_header_themes .deals_save{
299
+ bottom: 76px;
300
+ }
301
+ .deal_block{
302
+ width: 31.2%;
303
+ display: inline-block;
304
+ vertical-align: top;
305
+ margin: 5px;
306
+ }
307
+ .deal_title{
308
+ text-align: center;
309
+ text-transform: uppercase;
310
+ font-size: 20px;
311
+ background: #FAFAFA;
312
+ padding: 10px 5px;
313
+ line-height: 23px;
314
+ }
315
+ .deal_title a, .deal_title a:hover, .deal_title a:focus{
316
+ text-decoration: none !important;
317
+ color: #000 !important;
318
+ }
319
+ .deal_desc{
320
+ background: #F5F5F5;
321
+ padding: 10px 5px;
322
+ }
323
+ .deal_desc p{
324
+ margin-bottom: 15px;
325
+ }
326
+
327
+ .deal_desc_footer .downloads{
328
+ float: left;
329
+ }
330
+ .deal_desc_footer .download_btn{
331
+ /*float: right;*/
332
+ margin-top: 10px;
333
+ text-align: center;
334
+ }
335
+ .deal_desc_footer .downloads .spans span:first-child{
336
+ background: #26455A;
337
+ color: #fff;
338
+ text-transform: uppercase;
339
+ padding: 5px;
340
+ display: inline-block;
341
+ }
342
+ .deal_desc_footer .downloads .spans span:last-child{
343
+ background: #fff;
344
+ padding: 5px;
345
+ border-top-right-radius: 25px;
346
+ border-bottom-right-radius: 25px;
347
+ margin-left: -3px;
348
+ }
349
+
350
+ .download_btn a, .download_btn a:hover, .download_btn a:focus{
351
+ color: #fff !important;
352
+ background: #E97025;
353
+ text-decoration: none;
354
+ padding: 4px 16px;
355
+ display: inline-block;
356
+ margin-top: 10px;
357
+ border-radius: 13px;
358
+ text-transform: uppercase;
359
+ }
360
+
361
+ .stars-container {
362
+ position: relative;
363
+ display: inline-block;
364
+ color: transparent;
365
+ font-size: 21px;
366
+ }
367
+
368
+ .stars-container:before {
369
+ position: absolute;
370
+ top: 0;
371
+ left: 0;
372
+ content: '★★★★★';
373
+ color: #F4AB7F;
374
+ }
375
+
376
+ .stars-container:after {
377
+ position: absolute;
378
+ top: 0;
379
+ left: 0;
380
+ content: '★★★★★';
381
+ color: #F4762A;
382
+ overflow: hidden;
383
+ }
384
+
385
+ .get_all_deals{
386
+ margin: 15px 0px;
387
+ text-align: center;
388
+ }
389
+ .get_all_deals a, .get_all_deals a:hover, .get_all_deals a:active, .get_all_deals a:focus {
390
+ color: #fff !important;
391
+ background: #E97025;
392
+ text-decoration: none;
393
+ padding: 8px 21px;
394
+ display: inline-block;
395
+ margin-top: 10px;
396
+ text-transform: uppercase;
397
+ border: 2px solid #D2631E;
398
+ font-size: 21px;
399
+ }
400
+
401
+ #themes{
402
+ border-top: 35px solid #F1F1F1;
403
+ padding-bottom: 15px;
404
+ }
405
+
406
+ .theme_block{
407
+ width: 48%;
408
+ margin: 5px;
409
+ border: 1px solid #ECE9E9;
410
+ float: left;
411
+ }
412
+ .theme_block a, .theme_block a:hover, .theme_block a:focus{
413
+ display: block;
414
+ text-decoration: none !important;
415
+ background: #F7F7F7;
416
+ color: #000 !important;
417
+ padding: 5px;
418
+ }
419
+
420
+ /* noteices */
421
+ .notice_wrap{
422
+ padding: 15px;
423
+ border: 1px solid #C4C4C4;
424
+ width: 98%;
425
+ margin: 10px auto;
426
+ box-sizing: border-box;
427
+
428
+ }
429
+ .notice_wrap .notice_title, .notice_wrap .notice_title:hover, .notice_wrap .notice_title:focus{
430
+ color: #E5682E !important;
431
+ text-decoration: none;
432
+ margin-bottom: 17px;
433
+ font-size: 20px;
434
+ display: block;
435
+ }
436
+
437
+ .notice_wrap .notice_txt{
438
+ font-size: 15px;
439
+ }
440
+
441
+
442
+ .wd-tour{
443
+ text-align: right;
444
+ }
445
+ .wd-tour-btn, .wd-tour-btn:hover, .wd-tour-btn:focus{
446
+ background: #F47629;
447
+ color: #fff;
448
+ text-decoration: none;
449
+ padding: 5px;
450
+ display: inline-block;
451
+ font-size: 16px;
452
+ }
453
+
454
+
455
+
wd/assets/css/subscribe.css ADDED
@@ -0,0 +1,114 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ body {
2
+ color: #444;
3
+ font-family: "Open Sans",sans-serif;
4
+ line-height: 1.4em;
5
+ min-width: 600px;
6
+ }
7
+
8
+ .wd-subscribe{
9
+ background: #fff;
10
+ border: 2px solid #E2E5EC;
11
+ width: 55%;
12
+ margin-top: 40px;
13
+ }
14
+ .wd-subscribe-content{
15
+ padding: 30px 92px;
16
+ }
17
+ .imgs{
18
+ text-align: center;
19
+ }
20
+ .imgs img{
21
+ vertical-align: middle;
22
+ width: 125px;
23
+ }
24
+ .imgs span {
25
+ color: #21759B;
26
+ font-weight: bold;
27
+ font-size: 52px;
28
+ padding: 0px 28px;
29
+ }
30
+ .texts{
31
+ margin-top: 10px;
32
+ margin-bottom: 25px;
33
+ }
34
+
35
+ .btns .allow_and_continue, .btns .allow_and_continue:hover, .btns .allow_and_continue:focus{
36
+ display: inline-block;
37
+ background: url(img/allow&continue.png) no-repeat;
38
+ width: 279px;
39
+ height: 61px;
40
+ border: none;
41
+
42
+ }
43
+ .btns .skip, .btns .skip:hover, .btns .skip:focus{
44
+ margin-left: 66px;
45
+ display: inline-block;
46
+ background: url(img/skip.png) no-repeat;
47
+ width: 76px;
48
+ height: 59px;
49
+ }
50
+ .permissions{
51
+ color: #525252 !important;
52
+ }
53
+ .list{
54
+ margin-top: 15px;
55
+ display:none;
56
+ }
57
+ .list_item{
58
+ display: table;
59
+ margin-bottom: 15px;
60
+ }
61
+ .list_item:after{
62
+ content: "";
63
+ clear: both;
64
+ display: table;
65
+ }
66
+ .list_img_wrap{
67
+ float: left;
68
+ }
69
+ .list_img_wrap img{
70
+ width: 27px;
71
+ }
72
+ .list_text_wrap{
73
+ margin-left: 33px;
74
+ float: right;
75
+ }
76
+ .list_title, .list_text{
77
+ color: #525252;
78
+ font-size: 13px;
79
+ }
80
+ .wd_loader{
81
+ vertical-align: top;
82
+ width: 30px;
83
+ margin-top: 11px;
84
+ visibility: hidden;
85
+ }
86
+ .wd-subscribe-footer{
87
+ text-align: center;
88
+ padding: 4px 0px;
89
+ border-top: 1px solid rgba(204, 204, 204, 0.52);
90
+ }
91
+ .wd-footer-menu {
92
+ display: inline-block;
93
+ list-style-type: none;
94
+ padding: 0;
95
+ margin: 0;
96
+ }
97
+ .wd-footer-menu li{
98
+ float: left;
99
+ }
100
+ .wd-footer-menu li, .wd-footer-menu li a{
101
+ color: rgba(62, 60, 60, 0.57) !important;
102
+ text-decoration: none;
103
+ font-size: 12px;
104
+ padding: 2px;
105
+ font-weight: bold;
106
+ display: inline-block;
107
+ vertical-align: middle;
108
+ }
109
+
110
+
111
+ .wd-footer-menu li a:hover{
112
+ color: rgba(62, 60, 60, 0.57) !important;
113
+ text-decoration: underline;
114
+ }
wd/assets/img/bwg_main_plugin.png ADDED
Binary file
wd/assets/img/ecwd_main_plugin.png ADDED
Binary file
wd/assets/img/faqwd_main_plugin.png ADDED
Binary file
wd/assets/img/ffwd_main_plugin.png ADDED
Binary file
wd/assets/img/fwd_main_plugin.png ADDED
Binary file
wd/assets/img/gawd_main_plugin.png ADDED
Binary file
wd/assets/img/gmwd_main_plugin.png ADDED
Binary file
wd/assets/img/loader.gif ADDED
Binary file
wd/assets/img/mwd_main_plugin.png ADDED
Binary file
wd/assets/img/plugins/business_elite.png ADDED
Binary file
wd/assets/img/plugins/business_world.png ADDED
Binary file
wd/assets/img/plugins/event-calendar-wd.png ADDED
Binary file
wd/assets/img/plugins/form-maker.png ADDED
Binary file
wd/assets/img/plugins/photo-gallery.png ADDED
Binary file
wd/assets/img/plugins/portfolio_gallery.png ADDED
Binary file
wd/assets/img/plugins/sauron.png ADDED
Binary file
wd/assets/img/plugins/slider-wd.png ADDED
Binary file
wd/assets/img/plugins/spider-event-calendar.png ADDED
Binary file
wd/assets/img/plugins/wd-google-maps.png ADDED
Binary file
wd/assets/img/plugins/wd-instagram-feed.png ADDED
Binary file
wd/assets/img/sp_calendar_main_plugin.png ADDED
Binary file
wd/assets/img/spinner.gif ADDED
Binary file
wd/assets/img/sub_1.png ADDED
Binary file
wd/assets/img/sub_2.png ADDED
Binary file
wd/assets/img/sub_4.png ADDED
Binary file
wd/assets/img/twd_main_plugin.png ADDED
Binary file
wd/assets/img/wd_ads_main_plugin.png ADDED
Binary file
wd/assets/img/wde_main_plugin.png ADDED
Binary file
wd/assets/img/wdi_main_plugin.png ADDED
Binary file
wd/assets/img/wdps_main_plugin.png ADDED
Binary file
wd/assets/img/wds_main_plugin.png ADDED
Binary file
wd/assets/img/wp_logo.png ADDED
Binary file
wd/assets/img/ytwd_main_plugin.png ADDED
Binary file
wd/assets/js/deactivate_popup.js ADDED
@@ -0,0 +1,104 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ////////////////////////////////////////////////////////////////////////////////////////
2
+ // Events //
3
+ ////////////////////////////////////////////////////////////////////////////////////////
4
+ ////////////////////////////////////////////////////////////////////////////////////////
5
+ // Constants //
6
+ ////////////////////////////////////////////////////////////////////////////////////////
7
+ ////////////////////////////////////////////////////////////////////////////////////////
8
+ // Variables //
9
+ ////////////////////////////////////////////////////////////////////////////////////////
10
+ var deactivated = false;
11
+ var additionalInfo = "";
12
+ var btnVal = 3;
13
+
14
+ ////////////////////////////////////////////////////////////////////////////////////////
15
+ // Constructor & Destructor //
16
+ ////////////////////////////////////////////////////////////////////////////////////////
17
+
18
+
19
+ ////////////////////////////////////////////////////////////////////////////////////////
20
+ // Public Methods //
21
+ ////////////////////////////////////////////////////////////////////////////////////////
22
+ function wdReady(prefix){
23
+
24
+ jQuery(document).on("click", "." + window[prefix + "WDDeactivateVars"].deactivate_class, function(){
25
+ jQuery(".wd-" + prefix + "-opacity").show();
26
+ jQuery(".wd-" + prefix + "-deactivate-popup").show();
27
+ if(jQuery(this).attr("data-uninstall") == "1"){
28
+ btnVal = 2 ;
29
+ }
30
+
31
+ return false;
32
+ });
33
+
34
+ jQuery(document).on("change", "[name=" + prefix + "_reasons]", function(){
35
+ jQuery("." + prefix + "_additional_details_wrap").html("");
36
+ jQuery(".wd-" + prefix + "-deactivate-popup").removeClass("wd-popup-active1 wd-popup-active2");
37
+ if(jQuery(this).val() == "reason_plugin_is_hard_to_use_technical_problems"){
38
+
39
+ additionalInfo = '<div class="wd-additional-active"><div><strong>Please describe your issue.</strong></div><br>' +
40
+ '<textarea name="' + prefix + '_additional_details" rows = "4"></textarea><br>' +
41
+ '<div>Our support will contact <input type="text" name="' + prefix + '_email" value="' + window[prefix + "WDDeactivateVars"].email + '"> shortly.</div>'+
42
+ '<br><div><button class="button button-primary wd-' + prefix + '-deactivate" data-val="' + btnVal + '">Submit support ticket</button></div></div>';
43
+ jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
44
+ jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active1");
45
+
46
+ }
47
+ else if(jQuery(this).val() == "reason_free_version_limited"){
48
+ additionalInfo = '<div class="wd-additional-active">' +
49
+ '<div><strong>We believe our premium version will fit your needs.</strong></div>' +
50
+ '<div><a href="' + window[prefix + "WDDeactivateVars"].plugin_wd_url+ '" target="_blank">Try with 30 day money back guarantee.</a></div>';
51
+
52
+ jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
53
+ jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active2");
54
+ }
55
+ else if(jQuery(this).val() == "reason_premium_expensive"){
56
+ additionalInfo = '<div class="wd-additional-active">' +
57
+ '<div><strong>We have a special offer for you.</strong></div>' +
58
+ '<div>Submit this form to get the offer to <input type="text" name="' + prefix + '_email" value="' + window[prefix + "WDDeactivateVars"].email + '"></div>' +
59
+ '<br><div><button class="button button-primary wd-' + prefix + '-deactivate" data-val="' + btnVal + '">Submit</button></div></div>';
60
+
61
+ jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
62
+ jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active2");
63
+ }
64
+
65
+ jQuery("#wd-" + prefix + "-deactivate").hide();
66
+ jQuery("#wd-" + prefix + "-submit-and-deactivate").show();
67
+
68
+ });
69
+ jQuery(document).on("keyup", "[name=" + prefix + "_additional_details]", function(){
70
+ if(jQuery(this).val().trim() || jQuery("[name=" + prefix + "_reasons]:checked").length > 0){
71
+ jQuery("#wd-" + prefix + "-deactivate").hide();
72
+ jQuery("#wd-" + prefix + "-submit-and-deactivate").show();
73
+ }
74
+ else{
75
+ jQuery("#wd-" + prefix + "-deactivate").show();
76
+ jQuery("#wd-" + prefix + "-submit-and-deactivate").hide();
77
+ }
78
+
79
+ });
80
+ jQuery(document).on("click", ".wd-" + prefix + "-deactivate", function(){
81
+ jQuery(".wd-deactivate-popup-opacity-" + prefix).show();
82
+ if(jQuery(this).hasClass("wd-clicked") == false){
83
+ jQuery("[name=" + prefix + "_submit_and_deactivate]").val(jQuery(this).attr("data-val"));
84
+ jQuery("#" + prefix + "_deactivate_form").submit();
85
+ }
86
+ return false;
87
+ });
88
+
89
+ jQuery(document).on("click", ".wd-" + prefix + "-cancel, .wd-opacity", function(){
90
+ jQuery(".wd-" + prefix + "-opacity").hide();
91
+ jQuery(".wd-" + prefix + "-deactivate-popup").hide();
92
+ return false;
93
+ });
94
+
95
+ }
96
+ ////////////////////////////////////////////////////////////////////////////////////////
97
+ // Getters & Setters //
98
+ ////////////////////////////////////////////////////////////////////////////////////////
99
+ ////////////////////////////////////////////////////////////////////////////////////////
100
+ // Private Methods //
101
+ ////////////////////////////////////////////////////////////////////////////////////////
102
+ ////////////////////////////////////////////////////////////////////////////////////////
103
+ // Listeners //
104
+ ////////////////////////////////////////////////////////////////////////////////////////
wd/assets/js/overview.js ADDED
@@ -0,0 +1,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ////////////////////////////////////////////////////////////////////////////////////////
2
+ // Events //
3
+ ////////////////////////////////////////////////////////////////////////////////////////
4
+ ////////////////////////////////////////////////////////////////////////////////////////
5
+ // Constants //
6
+ ////////////////////////////////////////////////////////////////////////////////////////
7
+ ////////////////////////////////////////////////////////////////////////////////////////
8
+ // Variables //
9
+ ////////////////////////////////////////////////////////////////////////////////////////
10
+ ////////////////////////////////////////////////////////////////////////////////////////
11
+ // Constructor & Destructor //
12
+ ////////////////////////////////////////////////////////////////////////////////////////
13
+ jQuery(document).ready(function () {
14
+ jQuery(".overview_content > div:not(#welcome)").hide();
15
+ jQuery(".overview_tabs li a:not(.not_tab)").click(function(){
16
+ jQuery(".overview_tabs li a").removeClass("overview_tab_active");
17
+ jQuery(this).addClass("overview_tab_active");
18
+ jQuery(".overview_content > div").hide();
19
+ var id = jQuery(this).attr("href");
20
+ jQuery(id).show();
21
+ return false;
22
+ });
23
+
24
+ // rating
25
+ // jQuery(".rating").each(function(){
26
+ // var rate = jQuery(this).attr("data-rating");
27
+ // jQuery("<span class='stars-container'>")
28
+ // .addClass("stars-" + rate.toString())
29
+ // .text("★★★★★")
30
+ // .appendTo(jQuery(this));
31
+ // jQuery("body").append('<style>.stars-' + rate.toString() + ':after{width:' + rate + '%;}</style>');
32
+ // });
33
+
34
+ jQuery("#wd-copy").click(function(){
35
+ var selector = document.querySelector('#wd-site-deatils-textarea');
36
+ selector.select();
37
+ document.execCommand('copy');
38
+
39
+ return false;
40
+
41
+ });
42
+
43
+ });
44
+
45
+ ////////////////////////////////////////////////////////////////////////////////////////
46
+ // Public Methods //
47
+ ////////////////////////////////////////////////////////////////////////////////////////
48
+ ////////////////////////////////////////////////////////////////////////////////////////
49
+ // Getters & Setters //
50
+ ////////////////////////////////////////////////////////////////////////////////////////
51
+ ////////////////////////////////////////////////////////////////////////////////////////
52
+ // Private Methods //
53
+ ////////////////////////////////////////////////////////////////////////////////////////
54
+ ////////////////////////////////////////////////////////////////////////////////////////
55
+ // Listeners //
56
+ ////////////////////////////////////////////////////////////////////////////////////////
wd/assets/js/subsribe.js ADDED
@@ -0,0 +1,36 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ////////////////////////////////////////////////////////////////////////////////////////
2
+ // Events //
3
+ ////////////////////////////////////////////////////////////////////////////////////////
4
+ ////////////////////////////////////////////////////////////////////////////////////////
5
+ // Constants //
6
+ ////////////////////////////////////////////////////////////////////////////////////////
7
+ ////////////////////////////////////////////////////////////////////////////////////////
8
+ // Variables //
9
+ ////////////////////////////////////////////////////////////////////////////////////////
10
+ ////////////////////////////////////////////////////////////////////////////////////////
11
+ // Constructor & Destructor //
12
+ ////////////////////////////////////////////////////////////////////////////////////////
13
+ jQuery(document).ready(function () {
14
+ jQuery(".permissions").click(function(){
15
+ jQuery(".list").toggle();
16
+ return false;
17
+ });
18
+
19
+ jQuery(".allow_and_continue").click(function(){
20
+ jQuery(this).css("opacity", "0.5");
21
+ jQuery(".wd_loader").css("visibility", "visible");
22
+ });
23
+ });
24
+
25
+ ////////////////////////////////////////////////////////////////////////////////////////
26
+ // Public Methods //
27
+ ////////////////////////////////////////////////////////////////////////////////////////
28
+ ////////////////////////////////////////////////////////////////////////////////////////
29
+ // Getters & Setters //
30
+ ////////////////////////////////////////////////////////////////////////////////////////
31
+ ////////////////////////////////////////////////////////////////////////////////////////
32
+ // Private Methods //
33
+ ////////////////////////////////////////////////////////////////////////////////////////
34
+ ////////////////////////////////////////////////////////////////////////////////////////
35
+ // Listeners //
36
+ ////////////////////////////////////////////////////////////////////////////////////////
wd/config.php ADDED
@@ -0,0 +1,127 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+
6
+ class DoradoWebConfig {
7
+ public static $instance;
8
+
9
+ public $prefix = null;
10
+ public $wd_plugin_id = null;
11
+ public $plugin_title = null;
12
+ public $plugin_wordpress_slug = null;
13
+ public $plugin_dir = null;
14
+ public $plugin_main_file = null;
15
+ public $description = null;
16
+ public $plugin_features = null;
17
+ public $user_guide = null;
18
+ public $overview_welcome_image = null;
19
+ public $video_youtube_id = null;
20
+ public $plugin_wd_url = null;
21
+ public $plugin_wd_demo_link = null;
22
+ public $plugin_wd_addons_link = null;
23
+ public $plugin_wizard_link = null;
24
+ public $after_subscribe = null;
25
+ public $plugin_menu_title = null;
26
+ public $plugin_menu_icon = null;
27
+ public $wd_dir = null;
28
+ public $wd_dir_includes = null;
29
+ public $wd_dir_templates = null;
30
+ public $wd_dir_assets = null;
31
+ public $wd_url_css = null;
32
+ public $wd_url_js = null;
33
+ public $wd_url_img = null;
34
+ public $deactivate = null;
35
+ public $subscribe = null;
36
+ public $custom_post = null;
37
+ public $menu_capability = null;
38
+ public $menu_position = null;
39
+
40
+ public function set_options( $options ){
41
+
42
+ if(isset( $options["prefix"] )) {
43
+ $this->prefix = $options["prefix"];
44
+ }
45
+ if(isset( $options["wd_plugin_id"] )) {
46
+ $this->wd_plugin_id = $options["wd_plugin_id"];
47
+ }
48
+ if(isset( $options["plugin_title"] )) {
49
+ $this->plugin_title = $options["plugin_title"];
50
+ }
51
+ if(isset( $options["plugin_wordpress_slug"] )) {
52
+ $this->plugin_wordpress_slug = $options["plugin_wordpress_slug"];
53
+ }
54
+ if(isset( $options["plugin_dir"] )) {
55
+ $this->plugin_dir = $options["plugin_dir"];
56
+ }
57
+ if(isset( $options["plugin_main_file"] )) {
58
+ $this->plugin_main_file = $options["plugin_main_file"];
59
+ }
60
+
61
+ if(isset( $options["description"] )) {
62
+ $this->description = $options["description"];
63
+ }
64
+ if(isset( $options["plugin_features"] )) {
65
+ $this->plugin_features = $options["plugin_features"];
66
+ }
67
+ if(isset( $options["user_guide"] )) {
68
+ $this->user_guide = $options["user_guide"];
69
+ }
70
+ if(isset( $options["video_youtube_id"] )) {
71
+ $this->video_youtube_id = $options["video_youtube_id"];
72
+ }
73
+ if(isset( $options["overview_welcome_image"] )) {
74
+ $this->overview_welcome_image = $options["overview_welcome_image"];
75
+ }
76
+ if(isset( $options["plugin_wd_url"] )) {
77
+ $this->plugin_wd_url = $options["plugin_wd_url"];
78
+ }
79
+ if(isset( $options["plugin_wd_demo_link"] )) {
80
+ $this->plugin_wd_demo_link = $options["plugin_wd_demo_link"];
81
+ }
82
+ if(isset( $options["plugin_wd_addons_link"] )) {
83
+ $this->plugin_wd_addons_link = $options["plugin_wd_addons_link"];
84
+ }
85
+ if(isset( $options["plugin_wizard_link"] )) {
86
+ $this->plugin_wizard_link = $options["plugin_wizard_link"];
87
+ }
88
+ if(isset( $options["after_subscribe"] )) {
89
+ $this->after_subscribe = $options["after_subscribe"];
90
+ }
91
+ if(isset( $options["plugin_menu_title"] )) {
92
+ $this->plugin_menu_title = $options["plugin_menu_title"];
93
+ }
94
+ if(isset( $options["plugin_menu_icon"] )) {
95
+ $this->plugin_menu_icon = $options["plugin_menu_icon"];
96
+ }
97
+ if(isset( $options["deactivate"] )) {
98
+ $this->deactivate = $options["deactivate"];
99
+ }
100
+ if(isset( $options["subscribe"] )) {
101
+ $this->subscribe = $options["subscribe"];
102
+ }
103
+ if(isset( $options["custom_post"] )) {
104
+ $this->custom_post = $options["custom_post"];
105
+ }
106
+ if(isset( $options["menu_capability"] )) {
107
+ $this->menu_capability = $options["menu_capability"];
108
+ }
109
+ if(isset( $options["menu_position"] )) {
110
+ $this->menu_position = $options["menu_position"];
111
+ }
112
+
113
+ // directories
114
+ $this->wd_dir = dirname( $this->plugin_main_file ) . '/wd';
115
+ $this->wd_dir_includes = $this->wd_dir . '/includes';
116
+ $this->wd_dir_templates = $this->wd_dir . '/templates';
117
+ $this->wd_dir_assets = $this->wd_dir . '/assets';
118
+ $this->wd_url_css = plugins_url( plugin_basename( $this->wd_dir ) ) . '/assets/css';
119
+ $this->wd_url_js = plugins_url( plugin_basename( $this->wd_dir ) ) . '/assets/js';
120
+ $this->wd_url_img = plugins_url( plugin_basename( $this->wd_dir ) ) . '/assets/img';
121
+ }
122
+
123
+
124
+ }
125
+
126
+
127
+
wd/includes/api.php ADDED
@@ -0,0 +1,81 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( !defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+
6
+ class DoradoWebApi{
7
+ ////////////////////////////////////////////////////////////////////////////////////////
8
+ // Events //
9
+ ////////////////////////////////////////////////////////////////////////////////////////
10
+ ////////////////////////////////////////////////////////////////////////////////////////
11
+ // Constants //
12
+ ////////////////////////////////////////////////////////////////////////////////////////
13
+ ////////////////////////////////////////////////////////////////////////////////////////
14
+ // Variables //
15
+ ////////////////////////////////////////////////////////////////////////////////////////
16
+
17
+ public $config ;
18
+ public $userhash = array();
19
+
20
+
21
+ ////////////////////////////////////////////////////////////////////////////////////////
22
+ // Constructor & Destructor //
23
+ ////////////////////////////////////////////////////////////////////////////////////////
24
+ public function __construct( $config = array() ) {
25
+ $this->config = $config;
26
+ $this->userhash = $this->get_userhash();
27
+ }
28
+ ////////////////////////////////////////////////////////////////////////////////////////
29
+ // Public Methods //
30
+ ////////////////////////////////////////////////////////////////////////////////////////
31
+
32
+
33
+ public function get_remote_data( $id ) {
34
+ $remote_data_path = DORADO_WEB_API_PLUGIN_DATA_PATH . '/' . $this->userhash;
35
+ $request = wp_remote_get( ( str_replace( '_id_', $id, $remote_data_path ) ) );
36
+
37
+ if ( !is_wp_error($request) || wp_remote_retrieve_response_code($request) === 200 ) {
38
+ return json_decode($request['body'], true);
39
+ }
40
+ return false;
41
+ }
42
+
43
+
44
+ public function get_userhash(){
45
+ $wd_options = $this->config;
46
+ $userhash = 'nohash';
47
+ if ( file_exists( $wd_options->plugin_dir . '/.keep') && is_readable( $wd_options->plugin_dir . '/.keep' ) ) {
48
+ $f = fopen( $wd_options->plugin_dir . '/.keep', 'r' );
49
+ $userhash = fgets( $f );
50
+ fclose( $f );
51
+ }
52
+ return $userhash;
53
+ }
54
+
55
+ public function get_hash(){
56
+ $response = wp_remote_get("https://api.web-dorado.com/hash/" . $_SERVER['REMOTE_ADDR'] . "/" . $_SERVER['HTTP_HOST']);
57
+
58
+ $response_body = isset($response["body"]) ? json_decode($response["body"], true) : null;
59
+
60
+ if(is_array($response_body)){
61
+ $hash = $response_body["body"]["hash"];
62
+ }
63
+ else{
64
+ $hash = null;
65
+ }
66
+
67
+ return $hash;
68
+ }
69
+
70
+
71
+ ////////////////////////////////////////////////////////////////////////////////////////
72
+ // Getters & Setters //
73
+ ////////////////////////////////////////////////////////////////////////////////////////
74
+ ////////////////////////////////////////////////////////////////////////////////////////
75
+ // Private Methods //
76
+ ////////////////////////////////////////////////////////////////////////////////////////
77
+ ////////////////////////////////////////////////////////////////////////////////////////
78
+ // Listeners //
79
+ ////////////////////////////////////////////////////////////////////////////////////////
80
+
81
+ }
wd/includes/deactivate.php ADDED
@@ -0,0 +1,168 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+
6
+ class DoradoWebDeactivate{
7
+ ////////////////////////////////////////////////////////////////////////////////////////
8
+ // Events //
9
+ ////////////////////////////////////////////////////////////////////////////////////////
10
+ ////////////////////////////////////////////////////////////////////////////////////////
11
+ // Constants //
12
+ ////////////////////////////////////////////////////////////////////////////////////////
13
+ ////////////////////////////////////////////////////////////////////////////////////////
14
+ // Variables //
15
+ ////////////////////////////////////////////////////////////////////////////////////////
16
+ public $deactivate_reasons = array();
17
+ public $config;
18
+ // Reason IDs
19
+ const REASON_PLUGIN_IS_HARD_TO_USE_TECHNICAL_PROBLEMS = "reason_plugin_is_hard_to_use_technical_problems";
20
+ const REASON_FREE_VERSION_IS_LIMITED = "reason_free_version_limited";
21
+ const REASON_PRO_EXPENSIVE = "reason_premium_expensive";
22
+ const REASON_UPGRADING_TO_PAID_VERSION = "reason_upgrading_to_paid_version";
23
+ const REASON_TEMPORARY_DEACTIVATION = "reason_temporary_deactivation";
24
+
25
+ ////////////////////////////////////////////////////////////////////////////////////////
26
+ // Constructor & Destructor //
27
+ ////////////////////////////////////////////////////////////////////////////////////////
28
+ public function __construct( $config = array() ) {
29
+ $this->config = $config;
30
+ $wd_options = $this->config;
31
+
32
+ $this->deactivate_reasons = array(
33
+ 1 => array(
34
+ 'id' => self::REASON_PLUGIN_IS_HARD_TO_USE_TECHNICAL_PROBLEMS,
35
+ 'text' => __( 'Technical problems / hard to use', $wd_options->prefix ),
36
+ ),
37
+ 2 => array(
38
+ 'id' => self::REASON_FREE_VERSION_IS_LIMITED,
39
+ 'text' => __( 'Free version is limited', $wd_options->prefix ),
40
+ ),
41
+ 3 => array(
42
+ 'id' => self::REASON_PRO_EXPENSIVE,
43
+ 'text' => __( 'Premium is expensive', $wd_options->prefix ),
44
+ ),
45
+ 4 => array(
46
+ 'id' => self::REASON_UPGRADING_TO_PAID_VERSION,
47
+ 'text' => __( 'Upgrading to paid version', $wd_options->prefix ),
48
+ ),
49
+ 5 => array(
50
+ 'id' => self::REASON_TEMPORARY_DEACTIVATION,
51
+ 'text' => __( 'Temporary deactivation', $wd_options->prefix ),
52
+ ),
53
+ );
54
+
55
+ add_action( 'admin_footer', array( $this, 'add_deactivation_feedback_dialog_box' ) );
56
+ add_action( 'admin_init', array( $this, 'submit_and_deactivate' ) );
57
+
58
+
59
+ add_action( 'admin_enqueue_scripts', array( $this, 'scripts' ) );
60
+
61
+
62
+
63
+
64
+ }
65
+ ////////////////////////////////////////////////////////////////////////////////////////
66
+ // Public Methods //
67
+ ////////////////////////////////////////////////////////////////////////////////////////
68
+ public function add_deactivation_feedback_dialog_box(){
69
+ $deactivate_reasons = $this->deactivate_reasons;
70
+ $wd_options = $this->config;
71
+
72
+ ?>
73
+ <script>
74
+ jQuery(document).ready(function () {
75
+ wdReady("<?php echo $wd_options->prefix; ?>");
76
+ });
77
+ </script>
78
+ <?php
79
+ require ( $wd_options->wd_dir_templates . '/display_deactivation_popup.php' );
80
+ }
81
+
82
+
83
+
84
+ public function scripts(){
85
+ $wd_options = $this->config;
86
+ wp_enqueue_style( 'wd-deactivate-popup', $wd_options->wd_url_css . '/deactivate_popup.css', array(), get_option($wd_options->prefix . "_version" ) );
87
+ wp_enqueue_script( 'wd-deactivate-popup', $wd_options->wd_url_js . '/deactivate_popup.js', array(), get_option($wd_options->prefix . "_version" ));
88
+
89
+ $admin_data = wp_get_current_user();
90
+ wp_localize_script( 'wd-deactivate-popup', $wd_options->prefix . 'WDDeactivateVars' , array(
91
+ "prefix" => $wd_options->prefix ,
92
+ "deactivate_class" => $wd_options->prefix . '_deactivate_link',
93
+ "email" => $admin_data->data->user_email,
94
+ "plugin_wd_url" => $wd_options->plugin_wd_url,
95
+ ));
96
+
97
+
98
+ }
99
+ public function submit_and_deactivate(){
100
+ $wd_options = $this->config;
101
+ if( isset( $_POST[$wd_options->prefix . "_submit_and_deactivate"] ) ){
102
+
103
+ if( $_POST[$wd_options->prefix . "_submit_and_deactivate"] == 2 || $_POST[$wd_options->prefix . "_submit_and_deactivate"] == 3 ){
104
+ $api = new DoradoWebApi( $wd_options );
105
+ $hash = $api->get_hash();
106
+ if($hash != null){
107
+ $data = array();
108
+
109
+ $data["reason"] = isset($_POST[$wd_options->prefix . "_reasons"]) ? $_POST[$wd_options->prefix . "_reasons"] : "";
110
+ $data["site_url"] = site_url();
111
+ $data["plugin_id"] = $wd_options->wd_plugin_id;
112
+
113
+ $data["additional_details"] = isset($_POST[$wd_options->prefix . "_additional_details"]) ? $_POST[$wd_options->prefix . "_additional_details"] : "";
114
+ $admin_data = wp_get_current_user();
115
+ $data["email"] = isset($_POST[$wd_options->prefix . "_email"]) ? $_POST[$wd_options->prefix . "_email"] : $admin_data->data->user_email;
116
+ $user_first_name = get_user_meta( $admin_data->ID, "first_name", true );
117
+ $user_last_name = get_user_meta( $admin_data->ID, "last_name", true );
118
+
119
+ $data["name"] = $user_first_name || $user_last_name ? $user_first_name . " " . $user_last_name : $admin_data->data->user_login;
120
+ $data["hash"] = $hash;
121
+ $response = wp_remote_post( "https://api.web-dorado.com/deactivatereasons", array(
122
+ 'method' => 'POST',
123
+ 'timeout' => 45,
124
+ 'redirection' => 5,
125
+ 'httpversion' => '1.0',
126
+ 'blocking' => true,
127
+ 'headers' => array(),
128
+ 'body' => json_encode($data),
129
+ 'cookies' => array()
130
+ )
131
+ );
132
+
133
+ $response_body = isset( $response["body"] ) ? json_decode( $response["body"], true ) : null;
134
+ if( is_array( $response_body ) && $response_body["body"]["msg"] == "Access" ) {
135
+
136
+ }
137
+ }
138
+ }
139
+ if($_POST[$wd_options->prefix . "_submit_and_deactivate"] == 2 || $_POST[$wd_options->prefix . "_submit_and_deactivate"] == 1 ){
140
+ $deactivate_url =
141
+ add_query_arg(
142
+ array(
143
+ 'action' => 'deactivate',
144
+ 'plugin' => plugin_basename( $wd_options->plugin_main_file ),
145
+ '_wpnonce' => wp_create_nonce( 'deactivate-plugin_' . plugin_basename( $wd_options->plugin_main_file ) )
146
+ ),
147
+ admin_url( 'plugins.php' )
148
+ );
149
+ echo '<script>window.location.href="' . $deactivate_url . '";</script>';
150
+ }
151
+
152
+ }
153
+ }
154
+
155
+ ////////////////////////////////////////////////////////////////////////////////////////
156
+ // Getters & Setters //
157
+ ////////////////////////////////////////////////////////////////////////////////////////
158
+ ////////////////////////////////////////////////////////////////////////////////////////
159
+ // Private Methods //
160
+ ////////////////////////////////////////////////////////////////////////////////////////
161
+
162
+ ////////////////////////////////////////////////////////////////////////////////////////
163
+ // Listeners //
164
+ ////////////////////////////////////////////////////////////////////////////////////////
165
+
166
+ }
167
+
168
+
wd/includes/notices.php ADDED
@@ -0,0 +1,223 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( !defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+
6
+ class DoradoWebNotices {
7
+
8
+ protected $promo_link = '';
9
+
10
+ public $config;
11
+ public $notice_spam = 0;
12
+ public $notice_spam_max = 2;
13
+
14
+ // Basic actions to run
15
+ public function __construct( $config = array() ) {
16
+ $this->config = $config;
17
+ // Runs the admin notice ignore function incase a dismiss button has been clicked
18
+ add_action( 'admin_init', array( $this, 'admin_notice_ignore' ) );
19
+ // Runs the admin notice temp ignore function incase a temp dismiss link has been clicked
20
+ add_action( 'admin_init', array( $this, 'admin_notice_temp_ignore' ) );
21
+ add_action( 'admin_notices', array( $this, 'wd_admin_notices' ) );
22
+ }
23
+
24
+ // Checks to ensure notices aren't disabled and the user has the correct permissions.
25
+ public function wd_admin_notice() {
26
+ $wd_options = $this->config;
27
+ $settings = get_option($wd_options->prefix . '_admin_notice');
28
+ if ( !isset( $settings['disable_admin_notices'] ) || ( isset( $settings['disable_admin_notices'] ) && $settings['disable_admin_notices'] == 0 ) ) {
29
+ if ( current_user_can( 'manage_options' ) ) {
30
+ return true;
31
+ }
32
+ }
33
+ return false;
34
+ }
35
+
36
+ // Primary notice function that can be called from an outside function sending necessary variables
37
+ public function admin_notice( $admin_notices ) {
38
+ $wd_options = $this->config;
39
+ // Check options
40
+ if ( !$this->wd_admin_notice() ) {
41
+ return false;
42
+ }
43
+ foreach ( $admin_notices as $slug => $admin_notice ) {
44
+ // Call for spam protection
45
+ if ( $this->anti_notice_spam() ) {
46
+ return false;
47
+ }
48
+
49
+ // Check for proper page to display on
50
+ if (isset( $admin_notices[$slug]['pages']) && is_array( $admin_notices[$slug]['pages'])) {
51
+ if ( !$this->admin_notice_pages( $admin_notices[$slug]['pages'] ) ) {
52
+ return false;
53
+ }
54
+ }
55
+
56
+ // Check for required fields
57
+ if ( !$this->required_fields( $admin_notices[$slug] ) ) {
58
+
59
+ // Get the current date then set start date to either passed value or current date value and add interval
60
+ $current_date = current_time( "n/j/Y" );
61
+ $start = ( isset( $admin_notices[$slug]['start'] ) ? $admin_notices[$slug]['start'] : $current_date );
62
+ $start = date( "n/j/Y", strtotime( $start ) );
63
+ $date_array = explode( '/', $start );
64
+ $interval = ( isset( $admin_notices[$slug]['int'] ) ? $admin_notices[$slug]['int'] : 0 );
65
+
66
+ $date_array[1] += $interval;
67
+ $start = date( "n/j/Y", mktime( 0, 0, 0, $date_array[0], $date_array[1], $date_array[2] ) );
68
+
69
+ // This is the main notices storage option
70
+ $admin_notices_option = get_option( $wd_options->prefix . '_admin_notice', array() );
71
+ // Check if the message is already stored and if so just grab the key otherwise store the message and its associated date information
72
+ if ( !array_key_exists( $slug, $admin_notices_option ) ) {
73
+ $admin_notices_option[$slug]['start'] = $start;
74
+ $admin_notices_option[$slug]['int'] = $interval;
75
+ update_option( $wd_options->prefix . '_admin_notice', $admin_notices_option );
76
+ }
77
+
78
+ // Sanity check to ensure we have accurate information
79
+ // New date information will not overwrite old date information
80
+ $admin_display_check = ( isset( $admin_notices_option[$slug]['dismissed'] ) ? $admin_notices_option[$slug]['dismissed'] : 0 );
81
+ $admin_display_start = ( isset( $admin_notices_option[$slug]['start'] ) ? $admin_notices_option[$slug]['start'] : $start );
82
+ $admin_display_interval = ( isset($admin_notices_option[$slug]['int'] ) ? $admin_notices_option[$slug]['int'] : $interval );
83
+ $admin_display_msg = ( isset($admin_notices[$slug]['msg'] ) ? $admin_notices[$slug]['msg'] : '' );
84
+ $admin_display_title = ( isset($admin_notices[$slug]['title'] ) ? $admin_notices[$slug]['title'] : '' );
85
+ $admin_display_link = ( isset( $admin_notices[$slug]['link'] ) ? $admin_notices[$slug]['link'] : '' );
86
+ $output_css = false;
87
+
88
+ // Ensure the notice hasn't been hidden and that the current date is after the start date
89
+ if ( $admin_display_check == 0 && strtotime($admin_display_start) <= strtotime($current_date ) ) {
90
+
91
+ // Get remaining query string
92
+ $query_str = ( isset( $admin_notices[$slug]['later_link'] ) ? $admin_notices[$slug]['later_link'] : esc_url(add_query_arg( $wd_options->prefix . '_admin_notice_ignore', $slug ) ) );
93
+ if ( strpos($slug, 'promo' ) === FALSE ) {
94
+ // Admin notice display output
95
+ echo '<div class="update-nag wd-admin-notice">
96
+ <div class="wd-notice-logo" style="background-image: url(' . $wd_options->wd_url_img . '/' . $wd_options->prefix . '_main_plugin.png);"></div>
97
+ <p class="wd-notice-title">' . $admin_display_title . '</p>
98
+ <p class="wd-notice-body">' . $admin_display_msg . '</p>
99
+ <ul class="wd-notice-body wd-blue">' . $admin_display_link . '</ul>
100
+ <a href="' . $query_str . '" class="dashicons dashicons-dismiss"></a>
101
+ </div>';
102
+ }
103
+ else {
104
+ echo '<div class="admin-notice-promo">';
105
+ echo $admin_display_msg;
106
+ echo '<ul class="notice-body-promo blue">
107
+ ' . $admin_display_link . '
108
+ </ul>';
109
+ echo '<a href="' . $query_str . '" class="dashicons dashicons-dismiss close-promo"></a>';
110
+ echo '</div>';
111
+ }
112
+ $this->notice_spam += 1;
113
+ $output_css = true;
114
+ }
115
+ if ( $output_css ) {
116
+ wp_enqueue_style( $wd_options->prefix . '-admin-notices', $wd_options->wd_url_css . '/notices.css', array(), get_option($wd_options->prefix . "_version" ) );
117
+ }
118
+ }
119
+ }
120
+ }
121
+
122
+ // Spam protection check
123
+ public function anti_notice_spam() {
124
+ if ( $this->notice_spam >= $this->notice_spam_max ) {
125
+ return true;
126
+ }
127
+ return false;
128
+ }
129
+
130
+ // Ignore function that gets ran at admin init to ensure any messages that were dismissed get marked
131
+ public function admin_notice_ignore() {
132
+ $wd_options = $this->config;
133
+ // If user clicks to ignore the notice, update the option to not show it again
134
+ if ( isset( $_GET[$wd_options->prefix . '_admin_notice_ignore'] ) ) {
135
+ $admin_notices_option = get_option( $wd_options->prefix . '_admin_notice', array() );
136
+ $admin_notices_option[$_GET[$wd_options->prefix . '_admin_notice_ignore']]['dismissed'] = 1;
137
+ update_option( $wd_options->prefix . '_admin_notice', $admin_notices_option );
138
+ $query_str = remove_query_arg( $wd_options->prefix . '_admin_notice_ignore' );
139
+ wp_redirect( $query_str );
140
+ exit;
141
+ }
142
+ }
143
+
144
+ // Temp Ignore function that gets ran at admin init to ensure any messages that were temp dismissed get their start date changed
145
+ public function admin_notice_temp_ignore() {
146
+ $wd_options = $this->config;
147
+ // If user clicks to temp ignore the notice, update the option to change the start date - default interval of 14 days
148
+ if ( isset( $_GET[$wd_options->prefix . '_admin_notice_temp_ignore'] ) ) {
149
+ $admin_notices_option = get_option( $wd_options->prefix . '_admin_notice', array() );
150
+ $current_date = current_time( "n/j/Y" );
151
+ $date_array = explode( '/', $current_date );
152
+ $interval = (isset($_GET['wd_int']) ? $_GET['wd_int'] : 14);
153
+ $date_array[1] += $interval;
154
+ $new_start = date( "n/j/Y", mktime( 0, 0, 0, $date_array[0], $date_array[1], $date_array[2] ) );
155
+
156
+ $admin_notices_option[$_GET[$wd_options->prefix . '_admin_notice_temp_ignore']]['start'] = $new_start;
157
+ $admin_notices_option[$_GET[$wd_options->prefix . '_admin_notice_temp_ignore']]['dismissed'] = 0;
158
+ update_option( $wd_options->prefix . '_admin_notice', $admin_notices_option );
159
+ $query_str = remove_query_arg( array( $wd_options->prefix . '_admin_notice_temp_ignore', 'wd_int' ) );
160
+ wp_redirect( $query_str );
161
+ exit;
162
+ }
163
+ }
164
+
165
+ public function admin_notice_pages($pages) {
166
+ $wd_options = $this->config;
167
+ foreach ( $pages as $key => $page ) {
168
+ if (is_array($page)) {
169
+ if ( isset( $_GET['page'] ) && $_GET['page'] == $page[0] && isset($_GET['tab']) && $_GET['tab'] == $page[1] ) {
170
+ return true;
171
+ }
172
+ }
173
+ else {
174
+ if ( $page == 'all' ) {
175
+ return true;
176
+ }
177
+ if ( get_current_screen()->id === $page ) {
178
+ return true;
179
+ }
180
+ if ( isset($_GET['page']) && $_GET['page'] == $page ) {
181
+ return true;
182
+ }
183
+ }
184
+ return false;
185
+ }
186
+ }
187
+
188
+ // Required fields check
189
+ public function required_fields( $fields ) {
190
+ if ( !isset( $fields['msg'] ) || ( isset($fields['msg'] ) && empty( $fields['msg'] ) ) ) {
191
+ return true;
192
+ }
193
+ if ( !isset( $fields['title'] ) || ( isset( $fields['title'] ) && empty( $fields['title'] ) ) ) {
194
+ return true;
195
+ }
196
+ return false;
197
+ }
198
+
199
+ // Special parameters function that is to be used in any extension of this class
200
+ public function special_parameters($admin_notices) {
201
+ // Intentionally left blank
202
+ }
203
+
204
+ public function wd_admin_notices() {
205
+ $wd_options = $this->config;
206
+ $two_week_review_ignore = add_query_arg( array( $wd_options->prefix . '_admin_notice_ignore' => 'two_week_review' ) );
207
+ $two_week_review_temp = add_query_arg( array( $wd_options->prefix . '_admin_notice_temp_ignore' => 'two_week_review', 'int' => 14 ) );
208
+ $promo_close = add_query_arg( array( $wd_options->prefix . '_admin_notice_ignore' => 'ecommerce_promo' ) );
209
+
210
+ $notices['two_week_review'] = array(
211
+ 'title' => __('Leave A Review?', $wd_options->prefix),
212
+ 'msg' => sprintf(__('We hope you\'ve enjoyed using WordPress %s! Would you consider leaving us a review on WordPress.org?', $wd_options->prefix), $wd_options->plugin_title),
213
+ 'link' => '<li><span class="dashicons dashicons-external"></span><a href="https://wordpress.org/support/view/plugin-reviews/' . $wd_options->plugin_wordpress_slug . '?filter=5" target="_blank">' . __('Sure! I\'d love to!', $wd_options->prefix) . '</a></li>
214
+ <li><span class="dashicons dashicons-smiley"></span><a href="' . $two_week_review_ignore . '"> ' . __('I\'ve already left a review', $wd_options->prefix) . '</a></li>
215
+ <li><span class="dashicons dashicons-calendar-alt"></span><a href="' . $two_week_review_temp . '">' . __('Maybe Later', $wd_options->prefix) . '</a></li>
216
+ <li><span class="dashicons dashicons-dismiss"></span><a href="' . $two_week_review_ignore . '">' . __('Never show again', $wd_options->prefix) . '</a></li>',
217
+ 'later_link' => $two_week_review_temp,
218
+ 'int' => 14
219
+ );
220
+
221
+ $this->admin_notice($notices);
222
+ }
223
+ }
wd/includes/overview.php ADDED
@@ -0,0 +1,310 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( !defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+
6
+ class DoradoWebOverview{
7
+ ////////////////////////////////////////////////////////////////////////////////////////
8
+ // Events //
9
+ ////////////////////////////////////////////////////////////////////////////////////////
10
+ ////////////////////////////////////////////////////////////////////////////////////////
11
+ // Constants //
12
+ ////////////////////////////////////////////////////////////////////////////////////////
13
+ ////////////////////////////////////////////////////////////////////////////////////////
14
+ // Variables //
15
+ ////////////////////////////////////////////////////////////////////////////////////////
16
+ public $config ;
17
+ private $tabs = array();
18
+
19
+ ////////////////////////////////////////////////////////////////////////////////////////
20
+ // Constructor & Destructor //
21
+ ////////////////////////////////////////////////////////////////////////////////////////
22
+ public function __construct( $config = array() ) {
23
+ $this->config = $config;
24
+ $wd_options = $this->config;
25
+ $this->tabs = array(
26
+ 'welcome' => array(
27
+ 'name' => __( "Welcome", $wd_options->prefix ),
28
+ 'view' => array( $this, 'wd_overview_welcome' )
29
+ ),
30
+ 'user_guide' => array(
31
+ 'name' => __( "User Guide", $wd_options->prefix ),
32
+ 'view' => array( $this, 'wd_overview_user_guide' )
33
+ ),
34
+ 'deals' => array(
35
+ 'name' => __( 'Deals', $wd_options->prefix ),
36
+ 'view' => array( $this, 'wd_overview_deals' )
37
+ ),
38
+ 'support' => array(
39
+ 'name' => __( "Support", $wd_options->prefix ),
40
+ 'view' => array( $this, 'wd_overview_support' )
41
+ ),
42
+ 'https://web-dorado.com/support/submit-your-idea.html' => array(
43
+ 'name' => __( "Submit Your Idea", $wd_options->prefix ),
44
+ 'view' => false
45
+ ),
46
+ 'https://wordpress.org/support/plugin/' . $wd_options->plugin_wordpress_slug => array(
47
+ 'name' => __( "Forum", $wd_options->prefix ),
48
+ 'view' => false
49
+ )
50
+ );
51
+
52
+
53
+
54
+ }
55
+ ////////////////////////////////////////////////////////////////////////////////////////
56
+ // Public Methods //
57
+ ////////////////////////////////////////////////////////////////////////////////////////
58
+ public function display_overview_page(){
59
+ $wd_options = $this->config;
60
+ $tabs = $this->tabs;
61
+ require_once( $wd_options->wd_dir_templates . "/display_overview.php" );
62
+ }
63
+ public function wd_overview_welcome(){
64
+ $wd_options = $this->config;
65
+ //http://api.wordpress.org/plugins/info/1.0/wd-google-maps
66
+ require_once( $wd_options->wd_dir_templates . "/display_overview_welcome.php" );
67
+ }
68
+ public function wd_overview_user_guide(){
69
+ $wd_options = $this->config;
70
+ $user_guide = $wd_options->user_guide;
71
+ require_once( $wd_options->wd_dir_templates . "/display_overview_user_guide.php" );
72
+ }
73
+ public function wd_overview_deals(){
74
+
75
+ $wd_options = $this->config;
76
+ $plugins = array(
77
+ "form-maker" => array(
78
+ 'title' => 'Form Maker',
79
+ 'text' => __( 'Wordpress form builder plugin', $wd_options->prefix ),
80
+ 'content' => __( 'Form Maker is a modern and advanced tool for creating WordPress forms easily and fast.', $wd_options->prefix ),
81
+ 'href' => 'https://web-dorado.com/products/wordpress-form.html'
82
+ ),
83
+ "photo-gallery" => array(
84
+ 'title' => 'Photo Gallery',
85
+ 'text' => __( 'WordPress Photo Gallery plugin', $wd_options->prefix ),
86
+ 'content' => __( 'Photo Gallery is a fully responsive WordPress Gallery plugin with advanced functionality.', $wd_options->prefix ),
87
+ 'href' => 'https://web-dorado.com/products/wordpress-photo-gallery-plugin.html'
88
+ ),
89
+ "event-calendar-wd" => array(
90
+ 'title' => 'Event Calendar WD',
91
+ 'text' => __( 'WordPress calendar plugin', $wd_options->prefix ),
92
+ 'content' => __( 'Organize and publish your events in an easy and elegant way using Event Calendar WD.', $wd_options->prefix ),
93
+ 'href' => 'https://web-dorado.com/products/wordpress-event-calendar-wd.html'
94
+ ),
95
+ "wd-google-maps" => array(
96
+ 'title' => 'WD Google Maps',
97
+ 'text' => __( 'WD Google Maps plugin', $wd_options->prefix ),
98
+ 'content' => __( 'Google Maps WD is an intuitive tool for creating Google maps with advanced markers, custom layers and overlays for your website.', $wd_options->prefix ),
99
+ 'href' => 'https://web-dorado.com/products/wordpress-google-maps-plugin.html'
100
+ ),
101
+ "slider-wd" => array(
102
+ 'title' => 'Slider WD',
103
+ 'text' => __( 'WordPress slider plugin', $wd_options->prefix ),
104
+ 'content' => __( 'Create responsive, highly configurable sliders with various effects for your WordPress site.', $wd_options->prefix ),
105
+ 'href' => 'https://web-dorado.com/products/wordpress-slider-plugin.html'
106
+ ),
107
+ "spider-event-calendar" => array(
108
+ 'title' => 'Spider Calendar',
109
+ 'text' => __( 'WordPress event calendar plugin', $wd_options->prefix ),
110
+ 'content' => __( 'Spider Event Calendar is a highly configurable product which allows you to have multiple organized events.', $wd_options->prefix ),
111
+ 'href' => 'https://web-dorado.com/products/wordpress-calendar.html'
112
+ ),
113
+ "wd-instagram-feed" => array(
114
+ 'title' => 'Instagram Feed WD',
115
+ 'text' => __( 'WordPress Instagram Feed plugin', $wd_options->prefix ),
116
+ 'content' => __( 'WD Instagram Feed is a user-friendly tool for displaying user or hashtag-based feeds on your website.', $wd_options->prefix ),
117
+ 'href' => 'https://web-dorado.com/products/wordpress-instagram-feed-wd.html'
118
+ ),
119
+ );
120
+ unset($plugins[$wd_options->plugin_wordpress_slug]) ;
121
+
122
+ // foreach ( $plugins as $wp_slug => &$plugin ){
123
+ // $wp_data = $this->remote_get($wp_slug);
124
+ // $plugin["downloaded"] = $wp_data["downloaded"];
125
+ // $plugin["rating"] = $wp_data["rating"];
126
+ // }
127
+
128
+ $themes = array(
129
+ "business_elite" => array(
130
+ 'title' => 'Business Elite Theme',
131
+ 'href' => 'https://web-dorado.com/wordpress-themes/business-elite.html'
132
+ ),
133
+ "portfolio_gallery" => array(
134
+ 'title' => 'Portfolio Gallery Theme',
135
+ 'href' => 'https://web-dorado.com/wordpress-themes/portfolio-gallery.html'
136
+ ),
137
+ "sauron" => array(
138
+ 'title' => 'Sauron Theme',
139
+ 'href' => 'https://web-dorado.com/wordpress-themes/sauron.html'
140
+ ),
141
+ "business_world" => array(
142
+ 'title' => 'Business World Theme',
143
+ 'href' => 'https://web-dorado.com/wordpress-themes/business-world.html'
144
+ ),
145
+ );
146
+
147
+ require_once( $wd_options->wd_dir_templates . "/display_overview_deals.php" );
148
+ }
149
+ public function wd_overview_support(){
150
+ $wd_options = $this->config;
151
+ global $wpdb;
152
+ $server_info = array();
153
+
154
+ // Get PHP Version
155
+ $server_info["Operating System"] = PHP_OS . " (" . ( PHP_INT_SIZE * 8 ) . ")";
156
+ $server_info["PHP Version"] = PHP_VERSION;
157
+ $server_info["Server"] = $_SERVER["SERVER_SOFTWARE"];
158
+
159
+ // Get MYSQL Version
160
+ $sql_version = $wpdb->get_var( "SELECT VERSION() AS version" );
161
+ $server_info["MySQL Version"] = $sql_version;
162
+
163
+ // GET SQL Mode
164
+ $mysqlinfo = $wpdb->get_results( "SHOW VARIABLES LIKE 'sql_mode'" );
165
+ if ( is_array( $mysqlinfo ) )
166
+ $sql_mode = $mysqlinfo[0]->Value;
167
+ if ( empty( $sql_mode ) )
168
+ $sql_mode = __( 'Not set', $wd_options->prefix );
169
+ $server_info["SQL Mode"] = $sql_mode;
170
+
171
+ // Get PHP Safe Mode
172
+ if( ini_get( 'safe_mode' ) )
173
+ $safe_mode = __( 'On', $wd_options->prefix );
174
+ else
175
+ $safe_mode = __( 'Off', $wd_options->prefix );
176
+ $server_info["PHP Safe Mode"] = $safe_mode;
177
+
178
+ // Get PHP allow_url_fopen
179
+ if( ini_get( 'allow_url_fopen' ) )
180
+ $allow_url_fopen = __( 'On', $wd_options->prefix );
181
+ else
182
+ $allow_url_fopen = __( 'Off', $wd_options->prefix );
183
+ $server_info["PHP Allow URL fopen"] = $allow_url_fopen;
184
+
185
+ // Get PHP Max Upload Size
186
+ if (function_exists('wp_max_upload_size'))
187
+ $upload_max = strval(round((int) wp_max_upload_size() / (1024 * 1024))) . 'M';
188
+ else if(ini_get('upload_max_filesize'))
189
+ $upload_max = ini_get('upload_max_filesize');
190
+ else
191
+ $upload_max = __('N/A', $wd_options->prefix);
192
+
193
+ $server_info["PHP Max Upload Size"] = $upload_max;
194
+
195
+ // Get PHP Output buffer Size
196
+ if( ini_get( 'pcre.backtrack_limit' ) )
197
+ $backtrack_limit = ini_get( 'pcre.backtrack_limit' );
198
+ else
199
+ $backtrack_limit = __( 'N/A', $wd_options->prefix );
200
+ $server_info["PCRE Backtracking Limit"] = $backtrack_limit;
201
+
202
+ // Get PHP Max Post Size
203
+ if( ini_get( 'post_max_size' ) )
204
+ $post_max = ini_get( 'post_max_size' );
205
+ else
206
+ $post_max = __( 'N/A', $wd_options->prefix );
207
+ $server_info["PHP Max Post Size"] = $post_max;
208
+
209
+ // Get PHP Max execution time
210
+ if( ini_get( 'max_execution_time' ) )
211
+ $max_execute = ini_get( 'max_execution_time' );
212
+ else
213
+ $max_execute = __( 'N/A', $wd_options->prefix );
214
+ $server_info["PHP Max Script Execute Time"] = $max_execute;
215
+
216
+
217
+ // Get PHP Memory Limit
218
+ if( ini_get( 'memory_limit' ) )
219
+ $memory_limit = ini_get( 'memory_limit' );
220
+ else
221
+ $memory_limit = __( 'N/A', $wd_options->prefix );
222
+ $server_info["PHP Memory Limit"] = $memory_limit;
223
+
224
+ // Get actual memory_get_usage
225
+ if ( function_exists( 'memory_get_usage' ) )
226
+ $memory_usage = round( memory_get_usage() / 1024 / 1024, 2 ) . __( ' MByte', $wd_options->prefix );
227
+ else
228
+ $memory_usage = __( 'N/A', $wd_options->prefix );
229
+ $server_info["Memory usage"] = $memory_usage;
230
+
231
+ // required for EXIF read
232
+ if ( is_callable( 'exif_read_data' ) )
233
+ $exif = __( 'Yes', $wd_options->prefix ). " (V" . substr( phpversion( 'exif' ), 0, 4 ) . ")" ;
234
+ else
235
+ $exif = __( 'No', $wd_options->prefix );
236
+ $server_info["PHP Exif support"] = $exif;
237
+
238
+ // required for meta data
239
+ if ( is_callable( 'iptcparse' ) )
240
+ $iptc = __( 'Yes', $wd_options->prefix );
241
+ else
242
+ $iptc = __( 'No', $wd_options->prefix );
243
+ $server_info["PHP IPTC support"] = $iptc;
244
+
245
+ // required for meta data
246
+ if ( is_callable( 'xml_parser_create' ) )
247
+ $xml = __( 'Yes', $wd_options->prefix );
248
+ else
249
+ $xml = __( 'No', $wd_options->prefix );
250
+ $server_info["PHP XML support"] = $xml;
251
+
252
+ $gd_info = array( "GD support" => __( 'No', $wd_options->prefix ) );
253
+ if( function_exists( "gd_info" ) ){
254
+ $gd_info = array();
255
+ foreach( gd_info() as $key => $val ){
256
+ if( is_bool($val) ){
257
+ $gd_info[$key] = $val ? __( 'Yes', $wd_options->prefix ) : __( 'No', $wd_options->prefix );
258
+ }
259
+ else{
260
+ $gd_info[$key] = $val;
261
+ }
262
+ }
263
+ }
264
+
265
+ require_once( $wd_options->wd_dir_templates . "/display_overview_support.php" );
266
+ }
267
+
268
+ public function overview_styles() {
269
+ $wd_options = $this->config;
270
+ $version = get_option( $wd_options->prefix . "_version" );
271
+ wp_enqueue_style( $wd_options->prefix . '_overview_css', $wd_options->wd_url_css . '/overview.css', array(), $version );
272
+
273
+ }
274
+ public function overview_scripts() {
275
+ $wd_options = $this->config;
276
+ $version = get_option( $wd_options->prefix . "_version" );
277
+ wp_enqueue_script( $wd_options->prefix . '_overview_js', $wd_options->wd_url_js . '/overview.js', array(), $version );
278
+
279
+ }
280
+ ////////////////////////////////////////////////////////////////////////////////////////
281
+ // Getters & Setters //
282
+ ////////////////////////////////////////////////////////////////////////////////////////
283
+ ////////////////////////////////////////////////////////////////////////////////////////
284
+ // Private Methods //
285
+ ////////////////////////////////////////////////////////////////////////////////////////
286
+ private function remote_get($plugin_wp_slug){
287
+ $request = wp_remote_get(" http://api.wordpress.org/plugins/info/1.0/" . $plugin_wp_slug);
288
+ $data = array();
289
+ if (!is_wp_error($request) || wp_remote_retrieve_response_code($request) === 200) {
290
+ $body = unserialize($request['body']);
291
+ $data["downloaded"] = $body->downloaded;
292
+ $ratings = $body->ratings;
293
+ if( $ratings[5] == 0 && $ratings[4] == 0 && $ratings[3] == 0 && $ratings[2] == 0 && $ratings[1] == 0){
294
+ $data["rating"] = 100;
295
+ }
296
+ else{
297
+ $data["rating"] = round( ( ( $ratings[5] * 5 + $ratings[4] * 4 + $ratings[3] * 3 + $ratings[2] * 2 + $ratings[1] * 1 ) / $body->num_ratings ) , 1 );
298
+
299
+ $data["rating"] = round( ( $data["rating"] / 5 ) * 100 );
300
+ }
301
+ return $data;
302
+ }
303
+ return false;
304
+
305
+ }
306
+ ////////////////////////////////////////////////////////////////////////////////////////
307
+ // Listeners //
308
+ ////////////////////////////////////////////////////////////////////////////////////////
309
+
310
+ }
wd/includes/subscribe.php ADDED
@@ -0,0 +1,138 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+ class DoradoWebSubscribe {
6
+ // //////////////////////////////////////////////////////////////////////////////////////
7
+ // Events //
8
+ // //////////////////////////////////////////////////////////////////////////////////////
9
+ // //////////////////////////////////////////////////////////////////////////////////////
10
+ // Constants //
11
+ // //////////////////////////////////////////////////////////////////////////////////////
12
+ // //////////////////////////////////////////////////////////////////////////////////////
13
+ // Variables //
14
+ // //////////////////////////////////////////////////////////////////////////////////////
15
+ public $config;
16
+ // //////////////////////////////////////////////////////////////////////////////////////
17
+ // Constructor & Destructor //
18
+ // //////////////////////////////////////////////////////////////////////////////////////
19
+ public function __construct( $config = array() ){
20
+ $this->config = $config;
21
+ add_action( 'admin_init', array( $this, 'after_subscribe' ) );
22
+ }
23
+ // //////////////////////////////////////////////////////////////////////////////////////
24
+ // Public Methods //
25
+ // //////////////////////////////////////////////////////////////////////////////////////
26
+
27
+ public function subscribe_scripts() {
28
+ $wd_options = $this->config;
29
+ wp_register_script ( 'subscribe_js', $wd_options->wd_url_js . '/subsribe.js' );
30
+ wp_enqueue_script ( 'subscribe_js' );
31
+
32
+ }
33
+ public function subscribe_styles() {
34
+ $wd_options = $this->config;
35
+ wp_enqueue_style( $wd_options->prefix . 'subscribe', $wd_options->wd_url_css . '/subscribe.css' );
36
+
37
+ }
38
+
39
+ public function subscribe_display_page() {
40
+ $wd_options = $this->config;
41
+ $list = array(
42
+ 0 => array(
43
+ "title" => __( "Your name &", $wd_options->prefix ),
44
+ "small_text" => __( "Email address", $wd_options->prefix ),
45
+ "img" => $wd_options->wd_url_img . '/sub_1.png',
46
+ ),
47
+ 1 => array(
48
+ "title" => __( "Site URL", $wd_options->prefix ),
49
+ "small_text" => __( "Wordpress version", $wd_options->prefix ),
50
+ "img" => $wd_options->wd_url_img . '/sub_2.png',
51
+ ),
52
+ 2 => array(
53
+ "title" => __( "List of plugins", $wd_options->prefix ),
54
+ "small_text" => "",
55
+ "img" => $wd_options->wd_url_img . '/sub_4.png',
56
+ ),
57
+ );
58
+
59
+ require_once ( $wd_options->wd_dir_templates . "/display_subscribe.php" );
60
+ }
61
+ public function after_subscribe(){
62
+ $wd_options = $this->config;
63
+ if( isset( $_GET[ $wd_options->prefix . "_sub_action"] ) ){
64
+
65
+ if( $_GET[$wd_options->prefix . "_sub_action"] == "allow" ){
66
+ $api = new DoradoWebApi($wd_options);
67
+ $hash = $api->get_hash();
68
+
69
+ if( $hash != null ){
70
+ $all_plugins = array();
71
+ $plugins = get_plugins();
72
+ foreach ( $plugins as $slug => $data ) {
73
+ $plugin = array(
74
+ "Name" => $data["Name"],
75
+ "PluginURI" => $data["PluginURI"],
76
+ "Author" => $data["Author"],
77
+ "AuthorURI" => $data["AuthorURI"]
78
+ );
79
+ $all_plugins[$slug] = $plugin;
80
+ }
81
+
82
+ $data = array();
83
+ $data["site_url"] = site_url();
84
+
85
+ $admin_data = wp_get_current_user();
86
+
87
+ $user_first_name = get_user_meta( $admin_data->ID, "first_name", true );
88
+ $user_last_name = get_user_meta( $admin_data->ID, "last_name", true );
89
+
90
+ $data["name"] = $user_first_name || $user_last_name ? $user_first_name . " " . $user_last_name : $admin_data->data->user_login;
91
+
92
+ $data["email"] = $admin_data->data->user_email;
93
+ $data["wp_version"] = get_bloginfo( 'version' );
94
+ $data["plugin_id"] = $wd_options->wd_plugin_id;
95
+ $data["hash"] = $hash;
96
+ $data["all_plugins"] = $all_plugins;
97
+
98
+
99
+ $response = wp_remote_post( "https://api.web-dorado.com/collectuserdata", array(
100
+ 'method' => 'POST',
101
+ 'timeout' => 45,
102
+ 'redirection' => 5,
103
+ 'httpversion' => '1.0',
104
+ 'blocking' => true,
105
+ 'headers' => array(),
106
+ 'body' => json_encode($data),
107
+ 'cookies' => array()
108
+ )
109
+ );
110
+
111
+ $response_body = isset( $response["body"] ) ? json_decode( $response["body"], true ) : null;
112
+
113
+ if( is_array( $response_body ) && $response_body["body"]["msg"] == "Access" ) {
114
+
115
+ }
116
+ }
117
+ }
118
+ if ( get_option( $wd_options->prefix . "_subscribe_done" ) != 1 ) {
119
+ update_option( $wd_options->prefix . "_subscribe_done", 1 );
120
+ }
121
+ else {
122
+ add_option( $wd_options->prefix . "_subscribe_done" , "1", '', 'no');
123
+ }
124
+
125
+ wp_safe_redirect( $wd_options->after_subscribe );
126
+ }
127
+
128
+ }
129
+ // //////////////////////////////////////////////////////////////////////////////////////
130
+ // Getters & Setters //
131
+ // //////////////////////////////////////////////////////////////////////////////////////
132
+ // //////////////////////////////////////////////////////////////////////////////////////
133
+ // Private Methods //
134
+ // //////////////////////////////////////////////////////////////////////////////////////
135
+ // //////////////////////////////////////////////////////////////////////////////////////
136
+ // Listeners //
137
+ // //////////////////////////////////////////////////////////////////////////////////////
138
+ }
wd/start.php ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+ define( 'DORADO_WEB_API_PLUGIN_DATA_PATH', 'https://api.web-dorado.com/v2/_id_/plugindata' );
6
+ require_once dirname( __FILE__ ) . '/config.php';
7
+
8
+ /**
9
+ * @param options for Plugin details.
10
+ * prefix;
11
+ * wd_plugin_id;
12
+ * plugin_title;
13
+ * plugin_dir;
14
+ * plugin_main_file;
15
+ * description;
16
+ * plugin_features;
17
+ * user_guide;
18
+ * video_youtube_id;
19
+ * plugin_wd_url;
20
+ * plugin_wd_demo_link;
21
+ * plugin_wd_addons_link;
22
+ * plugin_wizard_link;
23
+ * after_subscribe;
24
+ * plugin_menu_title;
25
+ * plugin_menu_icon;
26
+ * custom_post;
27
+ */
28
+
29
+ function dorado_web_init( $options ) {
30
+
31
+ // load files
32
+ require_once dirname( __FILE__ ) . '/wd.php';
33
+
34
+ $wd = new DoradoWeb();
35
+ $wd->wd_init( $options );
36
+
37
+ }
38
+
39
+
40
+
41
+
wd/templates/display_deactivation_popup.php ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="wd-opacity wd-<?php echo $wd_options->prefix; ?>-opacity"></div>
2
+ <div class="wd-deactivate-popup wd-<?php echo $wd_options->prefix; ?>-deactivate-popup">
3
+ <div class="wd-deactivate-popup-opacity wd-deactivate-popup-opacity-<?php echo $wd_options->prefix; ?>">
4
+ <img src="<?php echo $wd_options->wd_url_img . '/spinner.gif'; ?>" class="wd-img-loader" >
5
+ </div>
6
+ <form method="post" id="<?php echo $wd_options->prefix; ?>_deactivate_form">
7
+ <div class="wd-deactivate-popup-header">
8
+ <?php _e( "Please let us know why you are deactivating. Your answer will help us to serve you better", $wd_options->prefix ); ?>:
9
+ </div>
10
+
11
+ <div class="wd-deactivate-popup-body">
12
+ <?php foreach( $deactivate_reasons as $deactivate_reason_slug => $deactivate_reason ) { ?>
13
+ <div class="wd-<?php echo $wd_options->prefix; ?>-reasons">
14
+ <input type="radio" value="<?php echo $deactivate_reason["id"];?>" id="<?php echo $wd_options->prefix . "-" .$deactivate_reason["id"]; ?>" name="<?php echo $wd_options->prefix; ?>_reasons" >
15
+ <label for="<?php echo $wd_options->prefix . "-" . $deactivate_reason["id"]; ?>"><?php echo $deactivate_reason["text"];?></label>
16
+ </div>
17
+ <?php } ?>
18
+ <div class="<?php echo $wd_options->prefix; ?>_additional_details_wrap"></div>
19
+ </div>
20
+ <div class="wd-btns">
21
+ <a href="#" data-val="1" class="button button-secondary button-close wd-<?php echo $wd_options->prefix; ?>-deactivate" id="wd-<?php echo $wd_options->prefix; ?>-deactivate"><?php _e( "Deactivate" , $wd_options->prefix ); ?></a>
22
+ <a href="#" data-val="2" class="button button-secondary button-close wd-<?php echo $wd_options->prefix; ?>-deactivate" id="wd-<?php echo $wd_options->prefix; ?>-submit-and-deactivate" style="display:none;"><?php _e( "Submit and deactivate" , $wd_options->prefix ); ?></a>
23
+ <a href="#" class="button button-primary wd-<?php echo $wd_options->prefix; ?>-cancel"><?php _e( "Cancel" , $wd_options->prefix ); ?></a>
24
+ </div>
25
+ <input type="hidden" name="<?php echo $wd_options->prefix . "_submit_and_deactivate"; ?>" value="" >
26
+ <?php wp_nonce_field( $wd_options->prefix . '_save_form', $wd_options->prefix . '_save_form_fild'); ?>
27
+ </form>
28
+ </div>
wd/templates/display_overview.php ADDED
@@ -0,0 +1,33 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="overview_welcome">
2
+ <div class="wd-cell wd-valign-middle">
3
+ <a href="<?php echo $wd_options->plugin_wd_url; ?>" target="_blank"><img src="<?php echo $wd_options->wd_url_img . '/' . $wd_options->prefix . '_main_plugin.png'; ?>"></a>
4
+ </div>
5
+ <div class="wd-cell wd-valign-middle">
6
+ <h2><?php echo sprintf( __( "Welcome to %s", $wd_options->prefix ), $wd_options->plugin_title ); ?></h2>
7
+ <div class="overview_welcome_text">
8
+ <div><?php echo sprintf( __( "CONGRATS! You've successfully installed %s WordPress plugin.", $wd_options->prefix ), $wd_options->plugin_title ) ; ?></div>
9
+ <div><?php echo $wd_options->description ; ?></div>
10
+ </div>
11
+ </div>
12
+ </div>
13
+ <div class="overview_wrap">
14
+ <ul class="overview_tabs">
15
+ <?php
16
+ foreach ( $tabs as $tab_key => $tab ) {
17
+ $href = $tab['view'] !== false ? "#" . $tab_key : $tab_key;
18
+ $target = $tab['view'] == false ? 'target="_blank" class="not_tab"' : '';
19
+ $overview_tab_active_class = $tab_key == 'welcome' ? 'class="overview_tab_active"' : ''
20
+ ?>
21
+ <li class=""><a href="<?php echo $href; ?>" <?php echo $overview_tab_active_class; ?> <?php echo $target; ?>><?php echo esc_html( $tab['name'] ); ?></a></li>
22
+ <?php } ?>
23
+ </ul>
24
+ <div class="overview_content">
25
+ <?php
26
+ foreach ( $tabs as $tab_key => $tab ) {
27
+ if( $tab['view'] !== false ){
28
+ echo call_user_func( $tab['view'] );
29
+ }
30
+ }
31
+ ?>
32
+ </div>
33
+ </div>
wd/templates/display_overview_deals.php ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div id="deals">
2
+
3
+ <div id="plugins">
4
+ <div class="deals_header deals_header_plugins">
5
+ <a href="https://web-dorado.com/wordpress-plugins-bundle.html" target="_blank">
6
+ <div class="wd-table">
7
+ <div class="wd-cell wd-text-right wd-valign-middle">
8
+ <img src="<?php echo $wd_options->wd_url_img . '/' . $wd_options->prefix . '_main_plugin.png'; ?>" width="100px">
9
+ </div>
10
+ <div class="wd-cell wd-valign-middle">
11
+ <div class="titles_wrap">
12
+ <div class="deals_main_title"><?php echo sprintf( __( "Get %s", $wd_options->prefix ), $wd_options->plugin_title ); ?></div>
13
+ <div class="deals_main_title"><span class="higlight">+27 </span><?php echo __( "plugins", $wd_options->prefix ); ?></div>
14
+ <div class="deals_secondary_title"><?php echo __( "for", $wd_options->prefix ); ?><span class="higlight"> $99 </span><?php echo __( "only", $wd_options->prefix ); ?></div>
15
+ </div>
16
+ <div class="deals_save"><?php echo __( "Save 80%", $wd_options->prefix ); ?></div>
17
+ </div>
18
+ </div>
19
+ </a>
20
+ </div>
21
+ <div class="deals_content">
22
+ <?php foreach( $plugins as $wp_slug => &$plugin ){ ?>
23
+
24
+ <div class="deal_block">
25
+ <div class="deal_title">
26
+ <a href="<?php echo $plugin["href"]; ?>" target="_blank" >
27
+ <img src = "<?php echo $wd_options->wd_url_img . '/plugins/' . $wp_slug . '.png'; ?>">
28
+ <h2><?php echo $plugin["title"]; ?></h2>
29
+ </a>
30
+ </div>
31
+ <div class="deal_desc">
32
+ <p><?php echo $plugin["content"]; ?></p>
33
+ <div class="deal_desc_footer">
34
+ <!--<div class="downloads">
35
+ <div class="rating" data-rating="<?php echo $plugin["rating"]; ?>"></div>
36
+ <div class="spans">
37
+ <span><?php _e( "Downloads", $wd_options->prefix ); ?></span>
38
+ <span><?php echo number_format($plugin["downloaded"], 0); ?></span>
39
+ </div>
40
+ </div>-->
41
+ <div class="download_btn">
42
+ <a href="<?php echo $plugin["href"]; ?>" target="_blank" ><?php _e( "Download", $wd_options->prefix ); ?></a>
43
+ </div>
44
+ </div>
45
+ </div>
46
+
47
+ </div>
48
+ <?php } ?>
49
+ </div>
50
+ <div class="get_all_deals">
51
+ <a href="https://web-dorado.com/wordpress-plugins-bundle.html" target="_blank" >
52
+ <?php _e( "Get all plugins", $wd_options->prefix ); ?>
53
+ </a>
54
+ </div>
55
+ </div>
56
+ <div id="themes">
57
+ <div class="deals_header deals_header_themes">
58
+ <a href="https://web-dorado.com/wordpress-themes-bundle.html" target="_blank">
59
+ <div class="wd-table">
60
+ <div class="wd-cell wd-text-right wd-valign-middle">
61
+ </div>
62
+ <div class="wd-cell wd-valign-middle">
63
+ <div class="titles_wrap">
64
+ <div class="deals_main_title"><?php echo __( "Get all 11 themes", $wd_options->prefix ); ?></div>
65
+ <div class="deals_main_title"><?php echo __( "for", $wd_options->prefix ); ?><span class="higlight"> $40 </span><?php echo __( "only", $wd_options->prefix ); ?></div>
66
+ </div>
67
+ <div class="deals_save"><?php echo __( "Save 70%", $wd_options->prefix ); ?></div>
68
+ </div>
69
+ </div>
70
+ </a>
71
+ </div>
72
+ <div class="deals_content">
73
+ <?php foreach( $themes as $slug => $theme ){ ?>
74
+ <div class="theme_block">
75
+ <a href="<?php echo $theme["href"]; ?>" target="_blank" >
76
+ <img src = "<?php echo $wd_options->wd_url_img . '/plugins/' . $slug . '.png'; ?>" width="100%;">
77
+ <div><?php echo $theme["title"]; ?></div>
78
+ </a>
79
+ </div>
80
+ <?php } ?>
81
+ </div>
82
+ <div class="get_all_deals">
83
+ <a href="https://web-dorado.com/wordpress-themes-bundle.html" target="_blank" >
84
+ <?php _e( "Find out more", $wd_options->prefix ); ?>
85
+ </a>
86
+ </div>
87
+ </div>
88
+ </div>
wd/templates/display_overview_support.php ADDED
@@ -0,0 +1,43 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div id="support">
2
+ <p class="wd-support-main">
3
+ <?php echo sprintf( __("You may contact us by filling in this form or by email %s any time you need professional support or have any questions. You can also fill in the form to leave your comments or feedback.", $wd_options->prefix), "<span class='support_email'>(support@web-dorado.com)</span>") ;?>
4
+ </p>
5
+ <div class="wd-overview-site-deatils">
6
+ <h2><?php _e( "Site Details", $wd_options->prefix ); ?></h2>
7
+ <p>
8
+ <?php _e( "When contacting support, consider copying and pasting this information in your support request.", $wd_options->prefix ); ?>
9
+ <br>
10
+ <?php _e( "It helps us troubleshoot more quickly.", $wd_options->prefix ); ?>
11
+ </p>
12
+ <?php
13
+ if ( function_exists('current_user_can' ) ) {
14
+ if ( current_user_can('manage_options') ) {
15
+ ?>
16
+ <div class="wd-site-deatils wd-table">
17
+ <button id="wd-copy"><?php _e( "Copy to Clipboard", $wd_options->prefix ); ?></button>
18
+ <div id="wd-site-deatils">
19
+ <textarea rows="10" id="wd-site-deatils-textarea"><?php
20
+ _e( "Server Settings", $wd_options->prefix );
21
+ echo '&#13;&#10;&#13;&#10;';
22
+ foreach( $server_info as $key => $val ){
23
+ echo $key . ": " . $val . '&#13;&#10;';
24
+ }
25
+ echo '&#13;&#10;';
26
+ _e( "Graphic Library", $wd_options->prefix );
27
+ echo '&#13;&#10;&#13;&#10;';
28
+ foreach( $gd_info as $key => $val ){
29
+ echo $key . ": " . $val . '&#13;&#10;';
30
+ }
31
+ ?></textarea>
32
+ </div>
33
+ </div>
34
+ <?php
35
+ }
36
+ }
37
+ ?>
38
+
39
+ </div>
40
+ <div class="contact_us_wrap">
41
+ <a href="https://web-dorado.com/support/contact-us.html" target="_blank" class="contact_us"><?php _e("Contact us", $wd_options->prefix); ?></a>
42
+ </div>
43
+ </div>
wd/templates/display_overview_user_guide.php ADDED
@@ -0,0 +1,46 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div id="user_guide">
2
+ <div class="wd-table">
3
+ <div class="wd-cell">
4
+ <?php for( $i = 0; $i < ceil( count($user_guide) / 2 ); $i++) { ?>
5
+ <div class="user_guide_item">
6
+ <a href="<?php echo $user_guide[$i]["url"]; ?>" class="user_guide_title" target="_blank"><?php echo $user_guide[$i]["main_title"]; ?></a>
7
+ <?php foreach( $user_guide[$i]["titles"] as $title ) { ?>
8
+ <div><a href="<?php echo $title["url"]; ?>" target="_blank" class="user_guide_titles"><?php echo $title["title"]; ?></a></div>
9
+ <?php } ?>
10
+ </div>
11
+ <?php } ?>
12
+ </div>
13
+ <div class="wd-cell">
14
+ <?php for( $i = $i; $i < count($user_guide); $i++) { ?>
15
+ <div class="user_guide_item">
16
+ <a href="<?php echo $user_guide[$i]["url"]; ?>" class="user_guide_title" target="_blank"><?php echo $user_guide[$i]["main_title"]; ?></a>
17
+ <?php foreach( $user_guide[$i]["titles"] as $title ) { ?>
18
+ <div><a href="<?php echo $title["url"]; ?>" target="_blank" class="user_guide_titles"><?php echo $title["title"]; ?></a></div>
19
+ <?php } ?>
20
+ </div>
21
+ <?php } ?>
22
+ </div>
23
+ <div class="wd-cell">
24
+ <?php if($wd_options->plugin_wd_demo_link) { ?>
25
+ <a href="<?php echo $wd_options->plugin_wd_demo_link; ?>" class="user_guide_demo" target="_blank">
26
+ <?php _e( "Demo", $wd_options->prefix ); ?>
27
+ </a>
28
+ <?php } ?>
29
+ <a href="<?php echo $wd_options->plugin_wd_url; ?>" class="user_guide_plugin" target="_blank">
30
+ <?php echo $wd_options->plugin_title; ?>
31
+ </a>
32
+ <a href="https://wordpress.org/support/plugin/<?php echo $wd_options->plugin_wordpress_slug; ?>" class="user_guide_support_forum" target="_blank">
33
+ <?php _e( "Support Forum", $wd_options->prefix ); ?>
34
+ </a>
35
+ <a href="https://web-dorado.com/support/faq.html" class="user_guide_faq" target="_blank">
36
+ <?php _e( "FAQ", $wd_options->prefix ); ?>
37
+ </a>
38
+ <?php if($wd_options->plugin_wd_addons_link) { ?>
39
+ <a href="<?php echo $wd_options->plugin_wd_addons_link; ?>" class="user_guide_addons" target="_blank">
40
+ <?php _e( "Addons", $wd_options->prefix ); ?>
41
+ </a>
42
+ <?php } ?>
43
+ </div>
44
+ </div>
45
+ </div>
46
+
wd/templates/display_overview_welcome.php ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div id="welcome">
2
+ <!-- display plugin video -->
3
+ <?php if( $wd_options->video_youtube_id ){ ?>
4
+ <div class="wd-video_container">
5
+ <iframe width="100%" height="400" src="//www.youtube.com/embed/<?php echo $wd_options->video_youtube_id; ?>?rel=0" frameborder="0" allowfullscreen></iframe>
6
+ </div>
7
+ <?php }
8
+ else if( $wd_options->overview_welcome_image ) { ?>
9
+ <img src="<?php echo $wd_options->overview_welcome_image; ?>" width="100%" />
10
+
11
+ <?php } ?>
12
+
13
+ <!-- display plugin features -->
14
+ <div class="plugin_features">
15
+ <!-- if your plugin has a wizard-->
16
+ <?php if( $wd_options->plugin_wizard_link ) { ?>
17
+ <div class="wd-tour">
18
+ <a class="wd-tour-btn" href="<?php echo $wd_options->plugin_wizard_link;?>"><?php _e( "Run Install Wizard ",$wd_options->prefix); ?></a>
19
+ </div>
20
+ <?php } ?>
21
+ <?php foreach( $wd_options->plugin_features as $feature ){ ?>
22
+ <h2 class="plugin_feature_title"><?php echo $feature["title"]; ?></h2>
23
+ <div class="plugin_feature_description"><?php echo $feature["description"]; ?></div>
24
+ <?php } ?>
25
+ <div class="more_features_wrap">
26
+ <a href="<?php echo $wd_options->plugin_wd_url; ?>" class="more_features" target="_blank"><?php _e( "More features", $wd_options->prefix ); ?></a>
27
+ </div>
28
+ </div>
29
+
30
+ </div>
31
+
wd/templates/display_subscribe.php ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="wd-subscribe">
2
+ <div class="wd-subscribe-content">
3
+ <div class="imgs">
4
+ <img src="<?php echo $wd_options->wd_url_img . '/wp_logo.png'; ?>">
5
+ <span>+</span>
6
+ <img src="<?php echo $wd_options->wd_url_img . '/' . $wd_options->prefix . '_main_plugin.png'; ?>">
7
+ </div>
8
+ <div class="texts">
9
+ <p><?php _e( "Hi there", $wd_options->prefix ); ?>,</p>
10
+ <p>
11
+ <?php echo sprintf( __( "Allow %s to collect some usage data. This will allow you to get more out of your plugin experience – get awesome customer support, receive exclusive deals and discounts on premium products and more. You can choose to skip this step, %s will still work just fine.", $wd_options->prefix ), '<strong>Web-Dorado</strong>', $wd_options->plugin_title ); ?>
12
+ </p>
13
+ </div>
14
+ <div class="btns">
15
+ <a href="<?php echo "admin.php?page=" . $wd_options->prefix . "_subscribe&". $wd_options->prefix . "_sub_action=allow" ;?>" class="allow_and_continue"></a>
16
+ <img src="<?php echo $wd_options->wd_url_img . '/loader.gif';?>" class="wd_loader">
17
+ <a href="<?php echo "admin.php?page=" . $wd_options->prefix . "_subscribe&" . $wd_options->prefix . "_sub_action=skip" ;?>" class="skip" ></a>
18
+ </div>
19
+ <a href="#" class="permissions"><?php _e( "What data is being collected?" , $wd_options->prefix ); ?></a>
20
+ <div class="list">
21
+ <?php foreach( $list as $list_item ) { ?>
22
+ <div class="list_item">
23
+ <div class="list_img_wrap"><img src="<?php echo $list_item["img"]; ?>"></div>
24
+ <div class="list_text_wrap">
25
+ <div class="list_title"><?php echo $list_item["title"]; ?></div>
26
+ <div class="list_text"><?php echo $list_item["small_text"]; ?></div>
27
+ </div>
28
+ </div>
29
+ <?php } ?>
30
+ </div>
31
+ </div>
32
+ <div class="wd-subscribe-footer">
33
+ <ul class="wd-footer-menu">
34
+ <li>
35
+ <a href="https://web-dorado.com/web-dorado-privacy-statement.html" target="_blank">
36
+ <?php _e( "Privacy Policy", $wd_options->prefix ); ?>
37
+ </a>
38
+ <span>.</span>
39
+ </li>
40
+ <li>
41
+ <a href="https://web-dorado.com/terms-of-service.html" target="_blank">
42
+ <?php _e( "Terms of Use", $wd_options->prefix ); ?>
43
+ </a>
44
+ </li>
45
+ </ul>
46
+ </div>
47
+ </div>
wd/wd.php ADDED
@@ -0,0 +1,146 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+
6
+ class DoradoWeb {
7
+ ////////////////////////////////////////////////////////////////////////////////////////
8
+ // Events //
9
+ ////////////////////////////////////////////////////////////////////////////////////////
10
+ ////////////////////////////////////////////////////////////////////////////////////////
11
+ // Constants //
12
+ ////////////////////////////////////////////////////////////////////////////////////////
13
+ ////////////////////////////////////////////////////////////////////////////////////////
14
+ // Variables //
15
+ ////////////////////////////////////////////////////////////////////////////////////////
16
+ public static $instance;
17
+ public $overview_instance;
18
+ public $subscribe_instance;
19
+ public $config;
20
+ private $version = "1.0.2";
21
+
22
+ ////////////////////////////////////////////////////////////////////////////////////////
23
+ // Constructor & Destructor //
24
+ ////////////////////////////////////////////////////////////////////////////////////////
25
+ public function __construct() {
26
+ // Add menu for Overview page
27
+ add_action( 'admin_menu', array( $this, 'wd_overview_menu_page' ), 10 );
28
+
29
+ }
30
+ ////////////////////////////////////////////////////////////////////////////////////////
31
+ // Public Methods //
32
+ ////////////////////////////////////////////////////////////////////////////////////////
33
+
34
+ // Init plugin data
35
+ public function wd_init( $options ) {
36
+
37
+ if(!is_array($options)){
38
+ return false;
39
+ }
40
+ $config = new DoradoWebConfig();
41
+ $config->set_options( $options );
42
+ $this->config = $config;
43
+ if( !class_exists("DoradoWebApi") ){
44
+ $this->wd_includes();
45
+ }
46
+
47
+ $this->init_classes();
48
+ $this->register_hooks();
49
+
50
+ }
51
+
52
+ // Create overview menu page
53
+ public function wd_overview_menu_page() {
54
+ $wd_options = $this->config;
55
+
56
+ $capability = $wd_options->menu_capability ? $wd_options->menu_capability : "manage_options";
57
+ if( get_option( $wd_options->prefix . "_subscribe_done" ) == 1 || $wd_options->subscribe === false ){
58
+ $parent_slug = $wd_options->custom_post;
59
+ }
60
+ else{
61
+
62
+ $subscribe_page = add_menu_page( $wd_options->plugin_menu_title, $wd_options->plugin_menu_title, "manage_options", $wd_options->prefix . '_subscribe' , array( $this, 'display_subscribew_page' ), $wd_options->plugin_menu_icon, $wd_options->menu_position );
63
+
64
+ $subscribe_instance = new DoradoWebSubscribe($this->config);
65
+ $this->subscribe_instance = $subscribe_instance;
66
+ add_action( 'admin_print_styles-' . $subscribe_page, array( $subscribe_instance, 'subscribe_styles' ) );
67
+ add_action( 'admin_print_scripts-' . $subscribe_page, array( $subscribe_instance, 'subscribe_scripts' ) );
68
+
69
+ $parent_slug = null;
70
+ }
71
+
72
+ $overview_page = add_submenu_page( $parent_slug, __( 'Overview', $wd_options->prefix ), __( 'Overview', $wd_options->prefix ), $capability, 'overview_' . $wd_options->prefix, array( $this, 'display_overview_page' ));
73
+
74
+
75
+ $overview_instance = new DoradoWebOverview($this->config);
76
+ $this->overview_instance = $overview_instance;
77
+ add_action( 'admin_print_styles-' . $overview_page, array( $overview_instance, 'overview_styles' ) );
78
+ add_action( 'admin_print_scripts-' . $overview_page, array( $overview_instance, 'overview_scripts' ) );
79
+ }
80
+
81
+ public function display_subscribew_page(){
82
+ $this->subscribe_instance->subscribe_display_page();
83
+ }
84
+
85
+ // Display overview page
86
+ public function display_overview_page() {
87
+ $this->overview_instance->display_overview_page();
88
+ }
89
+
90
+
91
+ // Includs
92
+ public function wd_includes(){
93
+ $wd_options = $this->config;
94
+
95
+ require_once $wd_options->wd_dir_includes . '/deactivate.php' ;
96
+ // notices
97
+ require_once $wd_options->wd_dir_includes . '/api.php';
98
+ require_once $wd_options->wd_dir_includes . '/notices.php';
99
+ require_once $wd_options->wd_dir_includes . "/overview.php";
100
+ require_once $wd_options->wd_dir_includes . "/subscribe.php";
101
+
102
+ }
103
+ public function init_classes(){
104
+ $wd_options = $this->config;
105
+
106
+ $current_url = $_SERVER['REQUEST_URI'];
107
+ if( $wd_options->deactivate === true ){
108
+ if(strpos( $current_url, "plugins.php" ) !== false ){
109
+ new DoradoWebDeactivate( $this->config );
110
+ }
111
+ }
112
+
113
+ new DoradoWebNotices( $this->config );
114
+
115
+ }
116
+
117
+ public function register_hooks(){
118
+ $wd_options = $this->config;
119
+ if( $wd_options->deactivate === true ){
120
+ add_filter( 'plugin_action_links_' . plugin_basename( $wd_options->plugin_main_file ), array( $this, 'change_deactivation_link' ) );
121
+ }
122
+
123
+ }
124
+
125
+
126
+ public function change_deactivation_link ( $links ) {
127
+ $wd_options = $this->config;
128
+ $links["deactivate"] = '<a href="#" class="' . $wd_options->prefix . '_deactivate_link">Deactivate</a>';
129
+ return $links;
130
+ }
131
+
132
+ ////////////////////////////////////////////////////////////////////////////////////////
133
+ // Getters & Setters //
134
+ ////////////////////////////////////////////////////////////////////////////////////////
135
+ ////////////////////////////////////////////////////////////////////////////////////////
136
+ // Private Methods //
137
+ ////////////////////////////////////////////////////////////////////////////////////////
138
+
139
+ ////////////////////////////////////////////////////////////////////////////////////////
140
+ // Listeners //
141
+ ////////////////////////////////////////////////////////////////////////////////////////
142
+
143
+ }
144
+
145
+
146
+
widget_Theme_functions.php CHANGED
@@ -9,7 +9,9 @@ function add_theme_calendar_widget() {
9
 
10
  function show_theme_calendar_widget() {
11
  global $wpdb;
12
- $order = " ORDER BY title ASC";
 
 
13
  $sort["default_style"] = "manage-column column-autor sortable desc";
14
  $sort["sortid_by"] = "title";
15
  $sort["custom_style"] = "manage-column column-title sorted asc";
@@ -21,12 +23,14 @@ function show_theme_calendar_widget() {
21
  if (isset($_POST['asc_or_desc']) && ($_POST['asc_or_desc'] == 1)) {
22
  $sort["custom_style"] = "manage-column column-title sorted asc";
23
  $sort["1_or_2"] = "2";
24
- $order = "ORDER BY " . $sort["sortid_by"] . " ASC";
 
25
  }
26
  else {
27
  $sort["custom_style"] = "manage-column column-title sorted desc";
28
  $sort["1_or_2"] = "1";
29
- $order = "ORDER BY " . $sort["sortid_by"] . " DESC";
 
30
  }
31
  if ($_POST['page_number']) {
32
  $limit = ($_POST['page_number'] - 1) * 20;
@@ -45,7 +49,7 @@ function show_theme_calendar_widget() {
45
  $search_tag = "";
46
  }
47
  if ($search_tag) {
48
- $where = ' WHERE title LIKE "%%' . like_escape($search_tag) . '%%"';
49
  }
50
  else {
51
  $where = '';
@@ -55,7 +59,9 @@ function show_theme_calendar_widget() {
55
  $total = $wpdb->get_var($query);
56
  $pageNav['total'] = $total;
57
  $pageNav['limit'] = $limit / 20 + 1;
58
- $query = $wpdb->prepare ("SELECT * FROM " . $wpdb->prefix . "spidercalendar_widget_theme" . $where . " " . $order . " " . " LIMIT %d,20", $limit);
 
 
59
  $rows = $wpdb->get_results($query);
60
  html_show_theme_calendar_widget($rows, $pageNav, $sort);
61
  }
9
 
10
  function show_theme_calendar_widget() {
11
  global $wpdb;
12
+ $order = "title";
13
+ $asc_desc = "ASC";
14
+ $order_by = "";
15
  $sort["default_style"] = "manage-column column-autor sortable desc";
16
  $sort["sortid_by"] = "title";
17
  $sort["custom_style"] = "manage-column column-title sorted asc";
23
  if (isset($_POST['asc_or_desc']) && ($_POST['asc_or_desc'] == 1)) {
24
  $sort["custom_style"] = "manage-column column-title sorted asc";
25
  $sort["1_or_2"] = "2";
26
+ $order = esc_sql(esc_html($sort["sortid_by"]));
27
+ $asc_desc = "ASC";
28
  }
29
  else {
30
  $sort["custom_style"] = "manage-column column-title sorted desc";
31
  $sort["1_or_2"] = "1";
32
+ $order = esc_sql(esc_html($sort["sortid_by"]));
33
+ $asc_desc = "DESC";
34
  }
35
  if ($_POST['page_number']) {
36
  $limit = ($_POST['page_number'] - 1) * 20;
49
  $search_tag = "";
50
  }
51
  if ($search_tag) {
52
+ $where = ' WHERE title LIKE "%%' . esc_sql(esc_html($search_tag)) . '%%"';
53
  }
54
  else {
55
  $where = '';
59
  $total = $wpdb->get_var($query);
60
  $pageNav['total'] = $total;
61
  $pageNav['limit'] = $limit / 20 + 1;
62
+
63
+ if( $order == "id" || $order == "title" ) $order_by = " ORDER BY " . $order . " " . $asc_desc;
64
+ $query = $wpdb->prepare ("SELECT * FROM " . $wpdb->prefix . "spidercalendar_widget_theme" . $where . " " . $order_by . " " . " LIMIT %d,20", $limit);
65
  $rows = $wpdb->get_results($query);
66
  html_show_theme_calendar_widget($rows, $pageNav, $sort);
67
  }
widget_Themes_function.html.php CHANGED
@@ -2,31 +2,8 @@
2
  if (!current_user_can('manage_options')) {
3
  die('Access Denied');
4
  }
5
- function html_show_theme_calendar_widget() {
6
- ?>
7
- <div class="updated" style="font-size: 14px; color:red !important">
8
- <p><strong>
9
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;"> This feature is disabled for the non-commercial version.</a>
10
- </strong>
11
- </p>
12
- </div>
13
- <table width="95%">
14
- <tr>
15
- <td width="100%" style="font-size:14px; font-weight:bold">
16
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-6/6-1.html" target="_blank" style="color:blue; text-decoration:none;">User Manual</a><br />
17
- This section allows you to create/edit themes for the calendars for the widget mode.<br />
18
- This feature is disabled for the non-commercial version.
19
- <a href="https://web-dorado.com/spider-calendar-wordpress-guide-step-6/6-1.html" target="_blank" style="color:blue; text-decoration:none;">More...</a><br />
20
- Here are examples of 6 standard templates included in the commercial version.
21
- <a href="http://wpdemo.web-dorado.com/spider-calendar/" target="_blank" style="color:blue; text-decoration:none;">Demo</a>
22
- </td>
23
- <td colspan="7" align="right" style="font-size:16px;">
24
- <a href="https://web-dorado.com/files/fromSpiderCalendarWP.php" target="_blank" style="color:red; text-decoration:none;">
25
- <img src="<?php echo plugins_url('images/header.png', __FILE__); ?>" border="0" alt="https://web-dorado.com/files/fromSpiderCalendarWP.php" width="215">
26
- </a>
27
- </td>
28
- </tr>
29
- </table>
30
  <br /><br />
31
  <img src="<?php echo plugins_url('images/spider_calendar_widget_themes.png', __FILE__); ?>" />
32
  <?php
2
  if (!current_user_can('manage_options')) {
3
  die('Access Denied');
4
  }
5
+ function html_show_theme_calendar_widget() { ?>
6
+ <?php upgrade_pro_sp("themes"); ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
7
  <br /><br />
8
  <img src="<?php echo plugins_url('images/spider_calendar_widget_themes.png', __FILE__); ?>" />
9
  <?php