WD Instagram Feed – Instagram Gallery - Version 1.1.24

Version Description

Added: Overview page
Changed: Deactivation

Download this release

Release Info

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

Code changes from version 1.1.23 to 1.1.24

Files changed (106) hide show
  1. admin-functions.php +8 -1
  2. admin/controllers/WDIControllerUninstall_wdi.php +20 -1
  3. admin/views/WDIViewUninstall_wdi.php +4 -2
  4. featured/WDIFeaturedPlugins.php +0 -518
  5. featured/WDIFeaturedThemes.php +0 -302
  6. featured/images/admanager-wd.png +0 -0
  7. featured/images/catalog.png +0 -0
  8. featured/images/contact.builder.png +0 -0
  9. featured/images/contact.maker.png +0 -0
  10. featured/images/contacts.png +0 -0
  11. featured/images/down.png +0 -0
  12. featured/images/download_plugins.png +0 -0
  13. featured/images/download_themes.png +0 -0
  14. featured/images/ecommerce.png +0 -0
  15. featured/images/events-wd.png +0 -0
  16. featured/images/facebook-feed.png +0 -0
  17. featured/images/facebook.png +0 -0
  18. featured/images/faq.png +0 -0
  19. featured/images/faq_wd.png +0 -0
  20. featured/images/flash.calendar.png +0 -0
  21. featured/images/folder.menu.png +0 -0
  22. featured/images/form.png +0 -0
  23. featured/images/google-maps.png +0 -0
  24. featured/images/instagram_feed.png +0 -0
  25. featured/images/mailchimp.png +0 -0
  26. featured/images/photo-gallery.png +0 -0
  27. featured/images/player.png +0 -0
  28. featured/images/post-slider.png +0 -0
  29. featured/images/random.post.png +0 -0
  30. featured/images/slider.png +0 -0
  31. featured/images/spider.calendar.png +0 -0
  32. featured/images/staff-team.png +0 -0
  33. featured/images/twittertools.png +0 -0
  34. featured/images/wd-google-analytics.png +0 -0
  35. featured/images/youtube-wd.png +0 -0
  36. featured/images/zoom.png +0 -0
  37. instagram-wdi-notices.php +1 -1
  38. js/wdi_admin.js +32 -32
  39. readme.txt +5 -1
  40. wd-instagram-feed.php +228 -72
  41. wd/README.md +129 -0
  42. wd/assets/css/deactivate_popup.css +86 -0
  43. wd/assets/css/img/allow&continue.png +0 -0
  44. wd/assets/css/img/coupon_bg.png +0 -0
  45. wd/assets/css/img/plugins_header_bg.png +0 -0
  46. wd/assets/css/img/skip.png +0 -0
  47. wd/assets/css/img/themes_headrer_bg.png +0 -0
  48. wd/assets/css/img/ug-icon-1.png +0 -0
  49. wd/assets/css/img/ug-icon-2.png +0 -0
  50. wd/assets/css/img/ug-icon-3.png +0 -0
  51. wd/assets/css/img/ug-icon-4.png +0 -0
  52. wd/assets/css/img/ug-icon-5.png +0 -0
  53. wd/assets/css/img/welcome_bg.png +0 -0
  54. {css → wd/assets/css}/notices.css +33 -36
  55. wd/assets/css/overview.css +455 -0
  56. wd/assets/css/subscribe.css +114 -0
  57. wd/assets/img/bwg_main_plugin.png +0 -0
  58. wd/assets/img/ecwd_main_plugin.png +0 -0
  59. wd/assets/img/faqwd_main_plugin.png +0 -0
  60. wd/assets/img/ffwd_main_plugin.png +0 -0
  61. wd/assets/img/fwd_main_plugin.png +0 -0
  62. wd/assets/img/gawd_main_plugin.png +0 -0
  63. wd/assets/img/gmwd_main_plugin.png +0 -0
  64. wd/assets/img/loader.gif +0 -0
  65. wd/assets/img/mwd_main_plugin.png +0 -0
  66. wd/assets/img/plugins/business_elite.png +0 -0
  67. wd/assets/img/plugins/business_world.png +0 -0
  68. wd/assets/img/plugins/event-calendar-wd.png +0 -0
  69. wd/assets/img/plugins/form-maker.png +0 -0
  70. wd/assets/img/plugins/photo-gallery.png +0 -0
  71. wd/assets/img/plugins/portfolio_gallery.png +0 -0
  72. wd/assets/img/plugins/sauron.png +0 -0
  73. wd/assets/img/plugins/slider-wd.png +0 -0
  74. wd/assets/img/plugins/spider-event-calendar.png +0 -0
  75. wd/assets/img/plugins/wd-google-maps.png +0 -0
  76. wd/assets/img/plugins/wd-instagram-feed.png +0 -0
  77. wd/assets/img/spinner.gif +0 -0
  78. wd/assets/img/sub_1.png +0 -0
  79. wd/assets/img/sub_2.png +0 -0
  80. wd/assets/img/sub_4.png +0 -0
  81. wd/assets/img/twd_main_plugin.png +0 -0
  82. wd/assets/img/wd_ads_main_plugin.png +0 -0
  83. wd/assets/img/wde_main_plugin.png +0 -0
  84. wd/assets/img/wdi_main_plugin.png +0 -0
  85. wd/assets/img/wdps_main_plugin.png +0 -0
  86. wd/assets/img/wds_main_plugin.png +0 -0
  87. wd/assets/img/wp_logo.png +0 -0
  88. wd/assets/img/ytwd_main_plugin.png +0 -0
  89. wd/assets/js/deactivate_popup.js +106 -0
  90. wd/assets/js/overview.js +56 -0
  91. wd/assets/js/subsribe.js +36 -0
  92. wd/config.php +127 -0
  93. wd/includes/api.php +81 -0
  94. wd/includes/deactivate.php +168 -0
  95. wd/includes/notices.php +223 -0
  96. wd/includes/overview.php +310 -0
  97. wd/includes/subscribe.php +138 -0
  98. wd/start.php +41 -0
  99. wd/templates/display_deactivation_popup.php +28 -0
  100. wd/templates/display_overview.php +33 -0
  101. wd/templates/display_overview_deals.php +88 -0
  102. wd/templates/display_overview_support.php +43 -0
  103. wd/templates/display_overview_user_guide.php +46 -0
  104. wd/templates/display_overview_welcome.php +31 -0
  105. wd/templates/display_subscribe.php +47 -0
  106. wd/wd.php +146 -0
admin-functions.php CHANGED
@@ -4,7 +4,6 @@
4
  */
5
 
6
  function wdi_check_necessary_params(){
7
-
8
  global $wdi_options;
9
  if(!isset($wdi_options['wdi_access_token']) || !isset($wdi_options['wdi_user_name']) || $wdi_options['wdi_access_token']=='' || $wdi_options['wdi_user_name'] ==''){
10
  ?>
@@ -16,6 +15,14 @@ function wdi_check_necessary_params(){
16
 
17
  }
18
 
 
 
 
 
 
 
 
 
19
 
20
 
21
  /**
4
  */
5
 
6
  function wdi_check_necessary_params(){
 
7
  global $wdi_options;
8
  if(!isset($wdi_options['wdi_access_token']) || !isset($wdi_options['wdi_user_name']) || $wdi_options['wdi_access_token']=='' || $wdi_options['wdi_user_name'] ==''){
9
  ?>
15
 
16
  }
17
 
18
+ function wdi_get_create_feeds_cap(){
19
+ global $wdi_options;
20
+ $min_feeds_capability = isset($wdi_options['wdi_feeds_min_capability']) ? $wdi_options['wdi_feeds_min_capability'] : "manage_options";
21
+ $min_feeds_capability = $min_feeds_capability == 'publish_posts' ? 'publish_posts' : "manage_options";
22
+
23
+ return $min_feeds_capability;
24
+ }
25
+
26
 
27
 
28
  /**
admin/controllers/WDIControllerUninstall_wdi.php CHANGED
@@ -6,7 +6,23 @@ class WDIControllerUninstall_wdi{
6
  ////////////////////////////////////////////////////////////////////////////////////////
7
  function __construct(){
8
 
9
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
10
  ////////////////////////////////////////////////////////////////////////////////////////
11
  // Public Methods //
12
  ////////////////////////////////////////////////////////////////////////////////////////
@@ -96,6 +112,9 @@ class WDIControllerUninstall_wdi{
96
  }else{
97
  $this->already_uninstalled();
98
  }
 
 
 
99
  }
100
 
101
  private function is_uninstalled(){
6
  ////////////////////////////////////////////////////////////////////////////////////////
7
  function __construct(){
8
 
9
+ global $wdi_wd_plugin_options;
10
+ if(!class_exists("DoradoWebConfig")){
11
+ include_once (WDI_DIR . "/wd/config.php");
12
+ }
13
+
14
+ if(!class_exists("DoradoWebDeactivate")) {
15
+ include_once(WDI_DIR . "/wd/includes/deactivate.php");
16
+ }
17
+ $config = new DoradoWebConfig();
18
+
19
+ $config->set_options( $wdi_wd_plugin_options );
20
+ $deactivate_reasons = new DoradoWebDeactivate($config);
21
+ //$deactivate_reasons->add_deactivation_feedback_dialog_box();
22
+ $deactivate_reasons->submit_and_deactivate();
23
+
24
+
25
+ }
26
  ////////////////////////////////////////////////////////////////////////////////////////
27
  // Public Methods //
28
  ////////////////////////////////////////////////////////////////////////////////////////
112
  }else{
113
  $this->already_uninstalled();
114
  }
115
+ delete_option('wdi_subscribe_done');
116
+ delete_option('wdi_redirect_to_settings');
117
+ delete_option('wdi_do_activation_set_up_redirect');
118
  }
119
 
120
  private function is_uninstalled(){
admin/views/WDIViewUninstall_wdi.php CHANGED
@@ -70,7 +70,8 @@ public function display(){
70
  <h2>
71
  <?php _e('Uninstalling Instagram Feed WD', "wdi"); ?>
72
  </h2>
73
- <p style="color:green;font-size:15px"> <?php _e('Instagram Feed WD is uninstalled','wdi') ?><a style="text-decoration:none;padding:3px;" href="<?php echo $deactivate_url ?>"> <?php _e('Click Here') ?> </a><?php _e('to deactivate it','wdi') ?></p>
 
74
 
75
  <?php
76
  }
@@ -93,7 +94,8 @@ public function display(){
93
  <li style="padding-bottom:5px;padding-left:5px;font-weight: bold;margin:0;">4)wdi_access_token</li>
94
  </ul>
95
  </div>
96
- <p style="color:green;font-size:15px"> <?php _e('Instagram Feed WD is successfully uninstalled','wdi') ?><a style="text-decoration:none;padding:3px;" href="<?php echo $deactivate_url ?>"> <?php _e('Click Here') ?> </a><?php _e('to deactivate it','wdi') ?></p>
 
97
 
98
  <?php
99
  }
70
  <h2>
71
  <?php _e('Uninstalling Instagram Feed WD', "wdi"); ?>
72
  </h2>
73
+ <!--<p style="color:green;font-size:15px"> <?php /*_e('Instagram Feed WD is uninstalled','wdi') */?><a style="text-decoration:none;padding:3px;" href="<?php /*echo $deactivate_url */?>"> <?php /*_e('Click Here') */?> </a><?php /*_e('to deactivate it','wdi') */?></p>-->
74
+ <p><strong><a href="#" class="wdi_deactivate_link" data-uninstall="1"><?php _e("Click Here","wdi"); ?></a><?php _e(" To Finish the Uninstallation and Instagram Feed WD will be Deactivated Automatically.","wdi"); ?></strong></p>
75
 
76
  <?php
77
  }
94
  <li style="padding-bottom:5px;padding-left:5px;font-weight: bold;margin:0;">4)wdi_access_token</li>
95
  </ul>
96
  </div>
97
+ <!--<p style="color:green;font-size:15px"> <?php /*_e('Instagram Feed WD is successfully uninstalled','wdi') */?><a style="text-decoration:none;padding:3px;" href="<?php /*echo $deactivate_url */?>"> <?php /*_e('Click Here') */?> </a><?php /*_e('to deactivate it','wdi') */?></p>-->
98
+ <p><strong><a href="#" class="wdi_deactivate_link" data-uninstall="1"><?php _e("Click Here","wdi"); ?></a><?php _e(" To Finish the Uninstallation and Instagram Feed WD will be Deactivated Automatically.","wdi"); ?></strong></p>
99
 
100
  <?php
101
  }
featured/WDIFeaturedPlugins.php DELETED
@@ -1,518 +0,0 @@
1
- <?php
2
-
3
- class WDIFeaturedPlugins
4
- {
5
- private $plugins = array(
6
- "form-maker" => array(
7
- 'title' => 'Form Maker',
8
- 'text' => 'Wordpress form builder plugin',
9
- 'content' => 'Form Maker is a modern and advanced tool for creating WordPress forms easily and fast.',
10
- 'href' => 'https://web-dorado.com/products/wordpress-form.html'
11
- ),
12
- "photo-gallery" => array(
13
- 'title' => 'Photo Gallery',
14
- 'text' => 'WordPress Photo Gallery plugin',
15
- 'content' => 'Photo Gallery is a fully responsive WordPress Gallery plugin with advanced functionality.',
16
- 'href' => 'https://web-dorado.com/products/wordpress-photo-gallery-plugin.html'
17
- ),
18
- "wd-google-analytics" => array(
19
- 'title' => 'Wd Google Analytics',
20
- 'text' => 'WordPress Google Analytics Plugin',
21
- 'content' => 'WD Google Analytics is a user-friendly all in one plugin, which allows to manage and monitor your website analytics from WordPress dashboard.',
22
- 'href' => 'https://web-dorado.com/products/wordpress-google-analytics-plugin.html'
23
- ),
24
- "ecommerce-wd" => array(
25
- 'title' => 'Ecommerce',
26
- 'text' => 'WordPress Ecommerce Plugin',
27
- 'content' => 'Ecommerce WD is a highly-functional, user friendly WordPress Ecommerce plugin, which is perfect for developing online stores for any level of complexity.',
28
- 'href' => 'https://web-dorado.com/products/wordpress-ecommerce.html'
29
- ),
30
- "google-maps" => array(
31
- 'title' => 'Google Map',
32
- 'text' => 'WordPress Google Maps Plugin',
33
- 'content' => 'Google Maps WD is an intuitive tool for creating Google maps with advanced markers, custom layers and overlays for your website.',
34
- 'href' => 'https://web-dorado.com/products/wordpress-google-maps-plugin.html'
35
- ),
36
- "facebook-wd" => array(
37
- 'title' => 'Facebook Feed WD',
38
- 'text' => 'WordPress facebook feed plugin',
39
- 'content' => 'Facebook Feed WD is a completely customizable, responsive solution to help you display your Facebook feed on your WordPress website.',
40
- 'href' => 'https://web-dorado.com/products/wordpress-facebook-feed-plugin.html'
41
- ),
42
-
43
- "slider_wd" => array(
44
- 'title' => 'Slider WD',
45
- 'text' => 'WordPress slider plugin',
46
- 'content' => 'Create responsive, highly configurable sliders with various effects for your WordPress site.',
47
- 'href' => 'https://web-dorado.com/products/wordpress-slider-plugin.html'
48
- ),
49
- "events-wd" => array(
50
- 'title' => 'Event Calendar WD',
51
- 'text' => 'WordPress calendar plugin',
52
- 'content' => 'Organize and publish your events in an easy and elegant way using Event Calendar WD.',
53
- 'href' => 'https://web-dorado.com/products/wordpress-event-calendar-wd.html'
54
- ),
55
- "youtube-wd" => array(
56
- 'title' => 'Youtube WD',
57
- 'text' => 'WordPress Youtube plugin',
58
- 'content' => 'Adding YouTube videos, channels and playlists to your WordPress website is super easy with YouTube WD plugin.',
59
- 'href' => 'https://web-dorado.com/products/wordpress-youtube-plugin.html'
60
- ),
61
- "admanager-wd" => array(
62
- 'title' => 'Ad Manager WD',
63
- 'text' => 'WordPress ads plugin',
64
- 'content' => 'Thinking of ways to monetize your WordPress website with ads? Now you can do it without any difficulty.',
65
- 'href' => 'https://web-dorado.com/products/wordpress-ad-manager-wd.html'
66
- ),
67
- "mailchimp" => array(
68
- 'title' => 'Mailchimp Forms WD',
69
- 'text' => 'WordPress Mailchimp forms plugin',
70
- 'content' => 'Access customizable themes, custom emails, PayPal Integration and more.',
71
- 'href' => 'https://web-dorado.com/products/wordpress-mailchimp-wd.html'
72
- ),
73
-
74
- "contact_form_bulder" => array(
75
- 'title' => 'Contact Form Builder',
76
- 'text' => 'WordPress contact form builder plugin',
77
- 'content' => 'Contact Form Builder is the best tool for quickly arranging a contact form for your clients and visitors.',
78
- 'href' => 'https://web-dorado.com/products/wordpress-contact-form-builder.html'
79
- ),
80
- "contact-maker" => array(
81
- 'title' => 'Contact Form Maker',
82
- 'text' => 'WordPress contact form maker plugin',
83
- 'content' => 'WordPress Contact Form Maker is an advanced and easy-to-use tool for creating forms.',
84
- 'href' => 'https://web-dorado.com/products/wordpress-contact-form-maker-plugin.html'
85
- ),
86
- "spider-calendar" => array(
87
- 'title' => 'Spider Calendar',
88
- 'text' => 'WordPress event calendar plugin',
89
- 'content' => 'Spider Event Calendar is a highly configurable product which allows you to have multiple organized events.',
90
- 'href' => 'https://web-dorado.com/products/wordpress-calendar.html'
91
- ),
92
- "faq_wd" => array(
93
- 'title' => 'FAQ WD',
94
- 'text' => 'WordPress FAQ plugin',
95
- 'content' => 'Organize and publish your FAQs in an easy and elegant way using FAQ WD.',
96
- 'href' => 'https://web-dorado.com/products/wordpress-faq-wd.html'
97
- ),
98
- "staff-team" => array(
99
- 'title' => 'Team WD',
100
- 'text' => 'WordPress team plugin',
101
- 'content' => 'Team WD plugin is a perfect solution to display the members of your staff, team or employees on your WordPress website.',
102
- 'href' => 'https://web-dorado.com/products/wordpress-team-wd.html'
103
- ),
104
- "instagram_feed" => array(
105
- 'title' => 'Instagram Feed WD',
106
- 'text' => 'WordPress Instagram Feed plugin',
107
- 'content' => 'WD Instagram Feed is a user-friendly tool for displaying user or hashtag-based feeds on your website.',
108
- 'href' => 'https://web-dorado.com/products/wordpress-instagram-feed-wd.html'
109
- ),
110
- "post-slider" => array(
111
- 'title' => 'Post Slider',
112
- 'text' => 'WordPress Post Slider plugin',
113
- 'content' => 'Post Slider WD is designed to show off the selected posts of your website in a slider.',
114
- 'href' => 'https://web-dorado.com/products/wordpress-post-slider-plugin.html'
115
- ),
116
- "catalog" => array(
117
- 'title' => 'Spider Catalog',
118
- 'text' => 'WordPress product catalog plugin',
119
- 'content' => 'Spider Catalog for WordPress is a convenient tool for organizing the products represented on your website into catalogs.',
120
- 'href' => 'https://web-dorado.com/products/wordpress-catalog.html'
121
- ),
122
- "player" => array(
123
- 'title' => 'Video Player',
124
- 'text' => 'WordPress Video player plugin',
125
- 'content' => 'Spider Video Player for WordPress is a Flash & HTML5 video player plugin that allows you to easily add videos to your website with the possibility.',
126
- 'href' => 'https://web-dorado.com/products/wordpress-player.html'
127
- ),
128
- "contacts" => array(
129
- 'title' => 'Spider Contacts',
130
- 'text' => 'Wordpress staff list plugin',
131
- 'content' => 'Spider Contacts helps you to display information about the group of people more intelligible, effective and convenient.',
132
- 'href' => 'https://web-dorado.com/products/wordpress-contacts-plugin.html'
133
- ),
134
- "facebook" => array(
135
- 'title' => 'Spider Facebook',
136
- 'text' => 'WordPress Facebook plugin',
137
- 'content' => 'Spider Facebook is a WordPress integration tool for Facebook.It includes all the available Facebook social plugins and widgets.',
138
- 'href' => 'https://web-dorado.com/products/wordpress-facebook.html'
139
- ),
140
- "twitter-widget" => array(
141
- 'title' => 'Widget Twitter',
142
- 'text' => 'WordPress Widget Twitter plugin',
143
- 'content' => 'The Widget Twitter plugin lets you to fully integrate your WordPress site with your Twitter account.',
144
- 'href' => 'https://web-dorado.com/products/wordpress-twitter-integration-plugin.html'
145
- ),
146
- "faq" => array(
147
- 'title' => 'Spider FAQ',
148
- 'text' => 'WordPress FAQ Plugin',
149
- 'content' => 'The Spider FAQ WordPress plugin is for creating an FAQ (Frequently Asked Questions) section for your website.',
150
- 'href' => 'https://web-dorado.com/products/wordpress-faq-plugin.html'
151
- ),
152
- "zoom" => array(
153
- 'title' => 'Zoom',
154
- 'text' => 'WordPress text zoom plugin',
155
- 'content' => 'Zoom enables site users to resize the predefined areas of the web site.',
156
- 'href' => 'https://web-dorado.com/products/wordpress-zoom.html'
157
- ),
158
- "flash-calendar" => array(
159
- 'title' => 'Flash Calendar',
160
- 'text' => 'WordPress flash calendar plugin',
161
- 'content' => 'Spider Flash Calendar is a highly configurable Flash calendar plugin which allows you to have multiple organized events.',
162
- 'href' => 'https://web-dorado.com/products/wordpress-events-calendar.html'
163
- ),
164
- "folder_menu" => array(
165
- 'title' => 'Folder Menu',
166
- 'text' => 'WordPress folder menu plugin',
167
- 'content' => 'Folder Menu Vertical is a WordPress Flash menu module for your website, designed to meet your needs and preferences.',
168
- 'href' => 'https://web-dorado.com/products/wordpress-menu-vertical.html'
169
- ),
170
- "random_post" => array(
171
- 'title' => 'Random post',
172
- 'text' => 'WordPress random post plugin',
173
- 'content' => 'Spider Random Post is a small but very smart solution for your WordPress web site.',
174
- 'href' => 'https://web-dorado.com/products/wordpress-random-post.html'
175
- ),
176
-
177
- );
178
-
179
- public function display($current_plugin = "instagram_feed")
180
- {
181
- $this->print_css();
182
- ?>
183
- <div id="main_featured_plugins_page">
184
- <h3>Featured Plugins</h3>
185
- <div class="featured_header">
186
- <a target="_blank"
187
- href="https://web-dorado.com/wordpress-plugins.html?source=<?php echo $current_plugin; ?>">
188
- <h1>GET <?php echo $this->plugins[$current_plugin]["title"]; ?> +23 PLUGINS</h1>
189
- <h1 class="get_plugins">FOR $100 ONLY <span>- SAVE 70%</span></h1>
190
- <div class="try-now">
191
- <span>TRY NOW</span>
192
- </div>
193
- </a>
194
- </div>
195
- <ul id="featured-plugins-list">
196
- <?php
197
- foreach ($this->plugins as $key => $plugins) {
198
- if ($current_plugin != $key) {
199
- ?>
200
- <li class="<?php echo $key; ?>">
201
- <div class="product"></div>
202
- <div class="title">
203
- <strong class="heading"><?php echo $plugins['title']; ?></strong>
204
- </div>
205
- <div class="description">
206
- <p><?php echo $plugins['content']; ?></p>
207
- </div>
208
- <a target="_blank" href="<?php echo $plugins['href']; ?>?source=<?php echo $current_plugin; ?>"
209
- class="download">Download Plugin &#9658;</a>
210
- </li>
211
- <?php
212
- }
213
- }
214
- ?>
215
- </ul>
216
- </div><?php
217
- }
218
-
219
- public function print_css()
220
- {
221
- ?>
222
- <style>
223
- @import url(http://fonts.googleapis.com/css?family=Oswald);
224
-
225
- #main_featured_plugins_page {
226
- font-family: Oswald;
227
- width: 90%;
228
- margin: 15px auto 0px auto;
229
- }
230
-
231
- #main_featured_plugins_page h3 {
232
- border-bottom: 2px solid #CECECE;
233
- color: rgb(111, 111, 111);
234
- font-family: Segoe UI;
235
- font-size: 18px;
236
- margin: 0px auto 15px auto;
237
- padding: 20px 0;
238
- }
239
-
240
- #main_featured_plugins_page #featured-plugins-list {
241
- position: relative;
242
- margin: 0px auto;
243
- height: auto;
244
- display: table;
245
- list-style: none;
246
- text-align: center;
247
- width: 100%;
248
- }
249
-
250
- #main_featured_plugins_page #featured-plugins-list li {
251
- display: inline-table;
252
- width: 200px;
253
- margin: 20px 10px 0px 10px;
254
- background: #FFFFFF;
255
- border-right: 3px solid #E5E5E5;
256
- height: 335px;
257
- border-bottom: 3px solid #E5E5E5;
258
- position: relative;
259
- }
260
-
261
- #main_featured_plugins_page #featured-plugins-list li .product {
262
- position: relative;
263
- height: 113px;
264
- background-color: transparent !important;
265
- background-position-x: 50% !important;
266
- margin: 7px;
267
- border-radius: 3px;
268
- background-size: 115px !important;
269
- }
270
-
271
- #main_featured_plugins_page #featured-plugins-list li .title {
272
- width: 90%;
273
- text-align: center;
274
- margin: 0 auto;
275
- }
276
-
277
- #main_featured_plugins_page #featured-plugins-list li.form-maker .product {
278
- background: url("<?php echo WDI_URL; ?>/featured/images/form.png") center center no-repeat;
279
- }
280
-
281
- #main_featured_plugins_page #featured-plugins-list li.catalog .product {
282
- background: url("<?php echo WDI_URL; ?>/featured/images/catalog.png") center center no-repeat;
283
- }
284
-
285
- #main_featured_plugins_page #featured-plugins-list li.contact-maker .product {
286
- background: url("<?php echo WDI_URL; ?>/featured/images/contact.maker.png") center center no-repeat;
287
- }
288
-
289
- #main_featured_plugins_page #featured-plugins-list li.contacts .product {
290
- background: url("<?php echo WDI_URL; ?>/featured/images/contacts.png") center center no-repeat;
291
- }
292
-
293
- #main_featured_plugins_page #featured-plugins-list li.ecommerce-wd .product {
294
- background: url("<?php echo WDI_URL; ?>/featured/images/ecommerce.png") center center no-repeat;
295
- }
296
-
297
- #main_featured_plugins_page #featured-plugins-list li.facebook .product {
298
- background: url("<?php echo WDI_URL; ?>/featured/images/facebook.png") center center no-repeat;
299
- }
300
- #main_featured_plugins_page #featured-plugins-list li.facebook-wd .product {
301
- background: url("<?php echo WDI_URL; ?>/featured/images/facebook-feed.png") center center no-repeat;
302
- }
303
-
304
- #main_featured_plugins_page #featured-plugins-list li.faq .product {
305
- background: url("<?php echo WDI_URL; ?>/featured/images/faq.png") center center no-repeat;
306
- }
307
-
308
- #main_featured_plugins_page #featured-plugins-list li.flash-calendar .product {
309
- background: url("<?php echo WDI_URL; ?>/featured/images/flash.calendar.png") center center no-repeat;
310
- }
311
-
312
- #main_featured_plugins_page #featured-plugins-list li.player .product {
313
- background: url("<?php echo WDI_URL; ?>/featured/images/player.png") center center no-repeat;
314
- }
315
-
316
- #main_featured_plugins_page #featured-plugins-list li.spider-calendar .product {
317
- background: url("<?php echo WDI_URL; ?>/featured/images/spider.calendar.png") center center no-repeat;
318
- }
319
-
320
- #main_featured_plugins_page #featured-plugins-list li.contact_form_bulder .product {
321
- background: url("<?php echo WDI_URL; ?>/featured/images/contact.builder.png") center center no-repeat;
322
- }
323
-
324
- #main_featured_plugins_page #featured-plugins-list li.random_post .product {
325
- background: url("<?php echo WDI_URL; ?>/featured/images/random.post.png") center center no-repeat;
326
- }
327
-
328
- #main_featured_plugins_page #featured-plugins-list li.slider_wd .product {
329
- background: url("<?php echo WDI_URL; ?>/featured/images/slider.png") center center no-repeat;
330
- }
331
-
332
- #main_featured_plugins_page #featured-plugins-list li.folder_menu .product {
333
- background: url("<?php echo WDI_URL; ?>/featured/images/folder.menu.png") center center no-repeat;
334
- }
335
-
336
- #main_featured_plugins_page #featured-plugins-list li.zoom .product {
337
- background: url("<?php echo WDI_URL; ?>/featured/images/zoom.png") center center no-repeat;
338
- }
339
-
340
- #main_featured_plugins_page #featured-plugins-list li.photo-gallery .product {
341
- background: url("<?php echo WDI_URL; ?>/featured/images/photo-gallery.png") center center no-repeat;
342
- }
343
-
344
- #main_featured_plugins_page #featured-plugins-list li.twitter-widget .product {
345
- background: url("<?php echo WDI_URL; ?>/featured/images/twittertools.png") center center no-repeat;
346
- }
347
-
348
- #main_featured_plugins_page #featured-plugins-list li.events-wd .product {
349
- background: url("<?php echo WDI_URL; ?>/featured/images/events-wd.png") center center no-repeat;
350
- }
351
- #main_featured_plugins_page #featured-plugins-list li.youtube-wd .product {
352
- background: url("<?php echo WDI_URL; ?>/featured/images/youtube-wd.png") center center no-repeat;
353
- }
354
- #main_featured_plugins_page #featured-plugins-list li.admanager-wd .product {
355
- background: url("<?php echo WDI_URL; ?>/featured/images/admanager-wd.png") center center no-repeat;
356
- }
357
- #main_featured_plugins_page #featured-plugins-list li.mailchimp .product {
358
- background: url("<?php echo WDI_URL; ?>/featured/images/mailchimp.png") center center no-repeat;
359
- }
360
-
361
- #main_featured_plugins_page #featured-plugins-list li.faq_wd .product {
362
- background: url("<?php echo WDI_URL; ?>/featured/images/faq_wd.png") center center no-repeat;
363
- }
364
- #main_featured_plugins_page #featured-plugins-list li.staff-team .product {
365
- background: url("<?php echo WDI_URL; ?>/featured/images/staff-team.png") center center no-repeat;
366
- }
367
-
368
- #main_featured_plugins_page #featured-plugins-list li.instagram_feed .product {
369
- background: url("<?php echo WDI_URL; ?>/featured/images/instagram_feed.png") center center no-repeat;
370
- }
371
-
372
- #main_featured_plugins_page #featured-plugins-list li.wd-google-analytics .product {
373
- background: url("<?php echo WDI_URL; ?>/featured/images/wd-google-analytics.png") center center no-repeat;
374
- }
375
-
376
- #main_featured_plugins_page #featured-plugins-list li.post-slider .product {
377
- background: url("<?php echo WDI_URL; ?>/featured/images/post-slider.png") center center no-repeat;
378
- }
379
-
380
- #main_featured_plugins_page #featured-plugins-list li.google-maps .product {
381
- background: url("<?php echo WDI_URL; ?>/featured/images/google-maps.png") center center no-repeat;
382
- }
383
-
384
- #main_featured_plugins_page #featured-plugins-list li .title .heading {
385
- display: block;
386
- position: relative;
387
- font-size: 17px;
388
- color: #767676;
389
- margin: 13px 0px 13px 0px;
390
- text-transform: uppercase;
391
- }
392
-
393
- #main_featured_plugins_page #featured-plugins-list li .title p {
394
- font-size: 14px;
395
- color: #444;
396
- margin-left: 20px;
397
- }
398
-
399
- #main_featured_plugins_page #featured-plugins-list li .description {
400
- height: 127px;
401
- width: 90%;
402
- margin: 0 auto;
403
- }
404
-
405
- #main_featured_plugins_page #featured-plugins-list li .description p {
406
- text-align: center;
407
- width: 100%;
408
- color: #9A9A9A;
409
- font-family: Segoe UI Light;
410
- }
411
-
412
- #featured-plugins-list li a.download {
413
- display: block;
414
- border-top: 1px solid #CACACA;
415
- outline: none;
416
- width: 90%;
417
- margin: 0 auto;
418
- font-size: 14px;
419
- line-height: 40px;
420
- text-decoration: none;
421
- font-weight: bolder;
422
- text-align: center;
423
- color: #134D68;
424
- position: absolute;
425
- text-transform: uppercase;
426
- bottom: 0;
427
- left: 10px;
428
- font-family: Segoe UI Black;
429
- text-shadow: 1px 0;
430
- }
431
-
432
- #featured-plugins-list li a.download:hover {
433
- color: #F47629;
434
- }
435
-
436
- .featured_header {
437
- background: #11465F;
438
- border-right: 3px solid #E5E5E5;
439
- border-bottom: 3px solid #E5E5E5;
440
- position: relative;
441
- padding: 20px 0;
442
- }
443
-
444
- .featured_header .old_price {
445
- color: rgba(180, 180, 180, 0.3);
446
- text-decoration: line-through;
447
- font-family: Oswald;
448
- }
449
-
450
- .featured_header h1.get_plugins {
451
- color: #FFFFFF;
452
- height: 85px;
453
- margin: 0;
454
- background-size: 85% 100%;
455
- background-position: center;
456
- line-height: 60px;
457
- }
458
-
459
- .featured_header .try-now {
460
- text-align: center;
461
- }
462
-
463
- .featured_header .try-now span {
464
- display: inline-block;
465
- padding: 7px 16px;
466
- background: #F47629;
467
- border-radius: 10px;
468
- color: #ffffff;
469
- font-size: 23px;
470
- }
471
-
472
- .featured_header h1 {
473
- font-size: 50px;
474
- text-align: center;
475
- color: #FFFFFF;
476
- letter-spacing: 3px;
477
- text-transform: uppercase;
478
- }
479
-
480
- .featured_header a {
481
- text-decoration: none;
482
- }
483
-
484
- .featured_header a:hover {
485
- text-decoration: none;
486
- }
487
-
488
- @media screen and (max-width: 1105px) {
489
- .featured_header h1 {
490
- font-size: 37px;
491
- line-height: 0;
492
- }
493
- }
494
-
495
- @media screen and (max-width: 835px) {
496
- .get_plugins span {
497
- display: none;
498
- }
499
- }
500
-
501
- @media screen and (max-width: 700px) {
502
- .featured_header h1 {
503
- line-height: 40px;
504
- }
505
- }
506
-
507
- @media screen and (max-width: 435px) {
508
- .featured_header h1 {
509
- font-size: 20px;
510
- line-height: 25px;
511
- }
512
- } </style><?php
513
- }
514
- }
515
-
516
-
517
-
518
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
featured/WDIFeaturedThemes.php DELETED
@@ -1,302 +0,0 @@
1
- <?php
2
-
3
- class WDIFeaturedThemes {
4
-
5
-
6
- private $slug = 'wd-instagram-feed';
7
- private $lang_slug = 'wdi';
8
-
9
- private $image_url = '';
10
- private $demo_url = 'http://themedemo.web-dorado.com/';
11
- private $site_url = 'https://web-dorado.com/wordpress-themes/';
12
-
13
- public function __construct() {
14
- $this->image_url = WDI_URL . "/images/featured_themes/";
15
-
16
- }
17
-
18
- ////////////////////////////////////////////////////////////////////////////////////////
19
- // Public Methods //
20
- ////////////////////////////////////////////////////////////////////////////////////////
21
-
22
- public function display() {
23
- ?>
24
-
25
- <style>
26
- @import url(https://fonts.googleapis.com/css?family=Oswald);
27
-
28
- #main_featured_themes_page #featured-themes-list {
29
- position:relative;
30
- margin:0px auto;
31
- height:auto;
32
- display:table;
33
- list-style:none;
34
- text-align: center;
35
- width: 100%;
36
- }
37
- #main_featured_themes_page #featured-themes-list li {
38
- display: inline-table;
39
- width: 300px;
40
- margin: 20px 10px 0px 10px;
41
- background: #FFFFFF;
42
- border-right: 3px solid #E5E5E5;
43
- border-bottom: 3px solid #E5E5E5;
44
- position: relative;
45
- }
46
- @media screen and (min-width: 1600px) {
47
- #main_featured_themes_page #featured-themes-list li {
48
- width:400px;
49
- }
50
-
51
- }
52
- #main_featured_themes_page .theme_img img {
53
- max-width: 100%;
54
- }
55
- #main_featured_themes_page .theme_img {
56
- display: inline-block;
57
- overflow: hidden;
58
- outline: 1px solid #D6D1D1;
59
- position:relative;
60
- /*height: 168px; */
61
- }
62
- #main_featured_themes_page #featured-themes-list li .title {
63
- width: 91%;
64
- text-align: center;
65
- margin: 0 auto;
66
- }
67
- #main_featured_themes_page {
68
- font-family: Oswald;
69
- }
70
- #main_featured_themes_page #featured-themes-list li .title .heading {
71
- display: block;
72
- position: relative;
73
- font-size: 17px;
74
- color: #666666;
75
- margin: 13px 0px 13px 0px;
76
- text-transform: uppercase;
77
- }
78
- #main_featured_themes_page #featured-themes-list li .title p {
79
- font-size:14px;
80
- color:#444;
81
- margin-left:20px;
82
- }
83
- #main_featured_themes_page #featured-themes-list li .description {
84
- height:130px;
85
- width: 90%;
86
- margin: 0 auto;
87
- }
88
- #main_featured_themes_page #featured-themes-list li .description p {
89
- text-align: center;
90
- width: 100%;
91
- color: #666666;
92
- font-family: "Open Sans",sans-serif;
93
- font-size: 14px;
94
- }
95
- #main_featured_themes_page #featured-themes-list li .links {
96
- border-top: 1px solid #d8d8d8;
97
- width: 90%;
98
- margin: 0 auto;
99
- font-size: 14px;
100
- line-height: 40px;
101
- font-weight: bolder;
102
- text-align: center;
103
- padding-top: 9px;
104
- padding-bottom: 12px;
105
- }
106
- #main_featured_themes_page .page_header h1 {
107
- margin: 0px;
108
- font-family: Segoe UI;
109
- padding-bottom: 15px;
110
- color: rgb(111, 111, 111);
111
- font-size: 24px;
112
- text-align:center;
113
- }
114
- #main_featured_themes_page .page_header {
115
- height: 40px;
116
- padding: 22px 0px 0px 0px;
117
- margin-bottom: 15px;
118
- /*border-bottom: rgb(111, 111, 111) solid 1px;*/
119
- }
120
- #main_featured_themes_page #featured-themes-list li a {
121
- outline: none;
122
- line-height: 29px;
123
- text-decoration: none;
124
- color: #134d68;
125
- font-family: "Open Sans",sans-serif;
126
- text-shadow: 1px 0;
127
- display: inline-block;
128
- font-size: 15px;
129
- }
130
- #main_featured_themes_page #featured-themes-list li a.demo {
131
- color: #ffffff;
132
- background: #F47629;
133
- border-radius: 3px;
134
- width: 76px;
135
- text-align:center;
136
- margin-right: 12px;
137
- }
138
- #main_featured_themes_page #featured-themes-list li a.download {
139
- padding-right: 30px;
140
- background:url(<?php echo $this->image_url; ?>down.png) no-repeat right;
141
- }
142
- #main_featured_themes_page .featured_header{
143
- background: #11465F;
144
- border-right: 3px solid #E5E5E5;
145
- border-bottom: 3px solid #E5E5E5;
146
- position: relative;
147
- padding: 20px 0;
148
- }
149
- #main_featured_themes_page .featured_header .try-now {
150
- text-align: center;
151
- }
152
- #main_featured_themes_page .featured_header .try-now span {
153
- display: inline-block;
154
- padding: 7px 16px;
155
- background: #F47629;
156
- border-radius: 10px;
157
- color: #ffffff;
158
- font-size: 23px;
159
- }
160
- #main_featured_themes_page .featured_container {
161
- position: relative;
162
- width: 90%;
163
- margin: 15px auto 0px auto;
164
- }
165
- #main_featured_themes_page .featured_container .old_price{
166
- color: rgba(180, 180, 180, 0.3);
167
- text-decoration: line-through;
168
- font-family: Oswald;
169
- }
170
- #main_featured_themes_page .featured_container .get_themes{
171
- color: #FFFFFF;
172
- height: 85px;
173
- margin: 0;
174
- background-size: 95% 100%;
175
- background-position: center;
176
- line-height: 60px;
177
- font-size: 45px;
178
- text-align: center;
179
- letter-spacing: 3px;
180
- }
181
- #main_featured_themes_page .featured_header h1{
182
- font-size: 45px;
183
- text-align: center;
184
- color: #ffffff;
185
- letter-spacing: 3px;
186
- line-height: 10px;
187
- }
188
- #main_featured_themes_page .featured_header a{
189
- text-decoration: none;
190
- }
191
- @media screen and (max-width: 1035px) {
192
- #main_featured_themes_page .featured_header h1{
193
- font-size: 37px;
194
- line-height: 0;
195
- }
196
- }
197
- @media screen and (max-width: 835px) {
198
- #main_featured_themes_page .get_themes span{
199
- display: none;
200
- }
201
- }
202
- @media screen and (max-width: 435px) {
203
- #main_featured_themes_page .featured_header h1 {
204
- font-size: 20px;
205
- line-height: 17px;
206
- }
207
- }
208
- </style>
209
-
210
- <?php
211
- $WDWThemes = array(
212
- "business_elite" => array(
213
- "title" => "Business Elite",
214
- "description" => __("Business Elite is a robust parallax theme for business websites. The theme uses smooth transitions and many functional sections.",$this->lang_slug),
215
- "link" => "business-elite.html",
216
- "demo" => "theme-businesselite",
217
- "image" => "business_elite.jpg"
218
- ),
219
- "portfolio" => array(
220
- "title" => "Portfolio Gallery",
221
- "description" => __("Portfolio Gallery helps to display images using various color schemes and layouts combined with elegant fonts and content parts.",$this->lang_slug),
222
- "link" => "portfolio-gallery.html",
223
- "demo" => "theme-portfoliogallery",
224
- "image" => "portfolio_gallery.jpg"
225
- ),
226
- "sauron" => array(
227
- "title" => "Sauron",
228
- "description" => __("Sauron is a multipurpose parallax theme, which uses multiple interactive sections designed for the client-engagement.",$this->lang_slug),
229
- "link" => "sauron.html",
230
- "demo" => "theme-sauron",
231
- "image" => "sauron.jpg"
232
- ),
233
- "business_world" => array(
234
- "title" => "Business World",
235
- "description" => __("Business World is an innovative WordPress theme great for Business websites.",$this->lang_slug),
236
- "link" => "business-world.html",
237
- "demo" => "theme-businessworld",
238
- "image" => "business_world.jpg"
239
- ),
240
- "best_magazine" => array(
241
- "title" => "Best Magazine",
242
- "description" => __("Best Magazine is an ultimate selection when you are dealing with multi-category news websites.",$this->lang_slug),
243
- "link" => "best-magazine.html",
244
- "demo" => "theme-bestmagazine",
245
- "image" => "best_magazine.jpg"
246
- ),
247
- "magazine" => array(
248
- "title" => "News Magazine",
249
- "description" => __("Magazine theme is a perfect solution when creating news and informational websites. It comes with a wide range of layout options.",$this->lang_slug),
250
- "link" => "news-magazine.html",
251
- "demo" => "theme-newsmagazine",
252
- "image" => "news_magazine.jpg"
253
- )
254
- );
255
- ?>
256
- <div id="main_featured_themes_page">
257
- <div class="featured_container">
258
- <div class="page_header">
259
- <h1><?php echo __("Featured Themes",$this->lang_slug); ?></h1>
260
- </div>
261
- <div class="featured_header">
262
- <a target="_blank" href="https://web-dorado.com/wordpress-themes.html?source=<?php echo $this->slug; ?>">
263
- <h1><?php echo __("WORDPRESS THEMES",$this->lang_slug); ?></h1>
264
- <h2 class="get_themes"><?php echo __("ALL FOR $40 ONLY ",$this->lang_slug); ?><span>- <?php echo __("SAVE 80%",$this->lang_slug); ?></span></h2>
265
- <div class="try-now">
266
- <span><?php echo __("TRY NOW",$this->lang_slug); ?></span>
267
- </div>
268
- </a>
269
- </div>
270
- <ul id="featured-themes-list">
271
- <?php foreach($WDWThemes as $key=>$WDWTheme) : ?>
272
- <li class="<?php echo $key; ?>">
273
- <div class="theme_img">
274
- <img src="<?php echo $this->image_url . $WDWTheme["image"]; ?>">
275
- </div>
276
- <div class="title">
277
- <h3 class="heading"><?php echo $WDWTheme["title"]; ?></h3>
278
- </div>
279
- <div class="description">
280
- <p><?php echo $WDWTheme["description"]; ?></p>
281
- </div>
282
- <div class="links">
283
- <a target="_blank" href="<?php echo $this->demo_url . $WDWTheme["demo"]."?source=".$this->slug; ?>" class="demo"><?php echo __("Demo",$this->lang_slug); ?></a>
284
- <a target="_blank" href="<?php echo $this->site_url . $WDWTheme["link"]."?source=".$this->slug; ?>" class="download"><?php echo __("Free Download",$this->lang_slug); ?></a>
285
- </div>
286
- </li>
287
- <?php endforeach; ?>
288
- </ul>
289
- </div>
290
- </div>
291
- <?php }
292
-
293
- ////////////////////////////////////////////////////////////////////////////////////////
294
- // Getters & Setters //
295
- ////////////////////////////////////////////////////////////////////////////////////////
296
- ////////////////////////////////////////////////////////////////////////////////////////
297
- // Private Methods //
298
- ////////////////////////////////////////////////////////////////////////////////////////
299
- ////////////////////////////////////////////////////////////////////////////////////////
300
- // Listeners //
301
- ////////////////////////////////////////////////////////////////////////////////////////
302
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
featured/images/admanager-wd.png DELETED
Binary file
featured/images/catalog.png DELETED
Binary file
featured/images/contact.builder.png DELETED
Binary file
featured/images/contact.maker.png DELETED
Binary file
featured/images/contacts.png DELETED
Binary file
featured/images/down.png DELETED
Binary file
featured/images/download_plugins.png DELETED
Binary file
featured/images/download_themes.png DELETED
Binary file
featured/images/ecommerce.png DELETED
Binary file
featured/images/events-wd.png DELETED
Binary file
featured/images/facebook-feed.png DELETED
Binary file
featured/images/facebook.png DELETED
Binary file
featured/images/faq.png DELETED
Binary file
featured/images/faq_wd.png DELETED
Binary file
featured/images/flash.calendar.png DELETED
Binary file
featured/images/folder.menu.png DELETED
Binary file
featured/images/form.png DELETED
Binary file
featured/images/google-maps.png DELETED
Binary file
featured/images/instagram_feed.png DELETED
Binary file
featured/images/mailchimp.png DELETED
Binary file
featured/images/photo-gallery.png DELETED
Binary file
featured/images/player.png DELETED
Binary file
featured/images/post-slider.png DELETED
Binary file
featured/images/random.post.png DELETED
Binary file
featured/images/slider.png DELETED
Binary file
featured/images/spider.calendar.png DELETED
Binary file
featured/images/staff-team.png DELETED
Binary file
featured/images/twittertools.png DELETED
Binary file
featured/images/wd-google-analytics.png DELETED
Binary file
featured/images/youtube-wd.png DELETED
Binary file
featured/images/zoom.png DELETED
Binary file
instagram-wdi-notices.php CHANGED
@@ -119,7 +119,7 @@ class WDI_Notices {
119
  $output_css = true;
120
  }
121
  if ($output_css) {
122
- wp_enqueue_style($this->prefix . '-admin-notices', $this->plugin_url . '/css/notices.css', array(), get_option($this->plugin_version));
123
  }
124
  }
125
 
119
  $output_css = true;
120
  }
121
  if ($output_css) {
122
+ //wp_enqueue_style($this->prefix . '-admin-notices', $this->plugin_url . '/css/notices.css', array(), get_option($this->plugin_version));
123
  }
124
  }
125
 
js/wdi_admin.js CHANGED
@@ -33,7 +33,7 @@ wdi_controller.getParameterByName = function(name) {
33
  }
34
 
35
  /**
36
- * Was tirggerd when redirected from api page
37
  * Sets access token from query string to input
38
  */
39
  wdi_controller.apiRedirected = function() {
@@ -60,7 +60,7 @@ wdi_controller.apiRedirected = function() {
60
  /**
61
  * Used in Settings page for finding access token owners username
62
  * and and for filling it in username input field
63
- *
64
  * @param {String} access_token [Instagram API access token]
65
  */
66
  wdi_controller.getUserInfo = function(access_token) {
@@ -100,7 +100,7 @@ wdi_controller.switchFeedTabs = function(tabname, section) {
100
  //showing only requested display_type tab elements
101
  jQuery('.display_type[tab="' + tabname + '"]').css('display', 'block');
102
 
103
- //swap active tab class
104
  jQuery('.wdi_feed_tabs').filter('.wdi_feed_tab_active').each(function() {
105
  jQuery(this).removeClass('wdi_feed_tab_active');
106
  });
@@ -199,7 +199,7 @@ wdi_controller.displaySettingsSection = function($this) {
199
  wdi_controller.switchThemeTabs = function(tabname, section) {
200
 
201
 
202
- //swap active tab class
203
  jQuery('.wdi_feed_tabs').filter('.wdi_feed_tab_active').each(function() {
204
  jQuery(this).removeClass('wdi_feed_tab_active');
205
  });
@@ -344,10 +344,10 @@ wdi_controller.save_feed = function(task) {
344
  * instagram request for getting meta info such as username and user id
345
  * stores getted data in wdi_controller.feed_users array and updates some admin elements which
346
  * depend on users
347
- *
348
  * @param {String} user_input [username or hashtag, Note. hashtags should start with #]
349
  * @param {String} backend [if is set to 'backend' all confirms will be ignored while making requests]
350
- * @return {Void}
351
  */
352
  wdi_controller.makeInstagramUserRequest = function(user_input, ignoreConfirm) {
353
 
@@ -519,7 +519,7 @@ wdi_controller.stringifyUserData = function(feed_users) {
519
 
520
  /**
521
  * Binds 'click' and 'enter' event to add user button
522
- *
523
  */
524
  wdi_controller.bindAddNewUserOrHashtagEvent = function() {
525
  jQuery('#wdi_add_user_ajax').on('click', function() {
@@ -539,7 +539,7 @@ wdi_controller.bindAddNewUserOrHashtagEvent = function() {
539
  /**
540
  * Removes users from internal wdi_controller.feed_users array and also
541
  * updates GUI (by removing user elements)
542
- *
543
  * @param {Object} $this [jQuery object of remove user button]
544
  */
545
  wdi_controller.removeFeedUser = function($this) {
@@ -567,7 +567,7 @@ wdi_controller.removeFeedUser = function($this) {
567
  if( jQuery('.wdi_user').length == 0 ){
568
  jQuery('#wdi_add_user_ajax_input').removeAttr('disabled');
569
  jQuery('#wdi_add_user_ajax_input').attr('placeholder','');
570
- }
571
  }
572
 
573
  }
@@ -575,7 +575,7 @@ wdi_controller.removeFeedUser = function($this) {
575
 
576
  /**
577
  * Adds or removes users from featured image select
578
- *
579
  * @param {String} username [username of user we want to add/remove]
580
  * @param {String} action [valid options are 'add' and 'remove']
581
  * @param {String} selected [if is set 'selected' then user will be marked as selected in select element]
@@ -637,7 +637,7 @@ wdi_controller.bindSaveThemeEvent = function() {
637
  * it checks if user has typed any username in unsername input
638
  * but forgetted to add it then it creates an object called wdi_controller.waitingAjaxRequestEnd
639
  * which previous task
640
- *
641
  * @param {String} task [how to save element save/apply/reset]
642
  * @return {Boolean} [1 if user forgotted to save and 0 if input field was empty]
643
  */
@@ -679,7 +679,7 @@ wdi_controller.checkIfUserNotSaved = function(task) {
679
 
680
  /**
681
  * if user was clicked save before ajax request then trigger save after getting info
682
- *
683
  * @param {String} correctUserFlag [if set to false form wouldn't be submitted]
684
  */
685
  wdi_controller.saveFeedAfterAjaxWait = function(correctUserFlag) {
@@ -710,7 +710,7 @@ wdi_controller.getCookie = function(name) {
710
  * Checks if response has meta code other then 200 or if it has not any data in it
711
  * then returns false
712
  * @param {Object} response [Instagram API response]
713
- * @return {Boolean}
714
  */
715
  wdi_controller.isValidResponse = function(response) {
716
 
@@ -759,10 +759,10 @@ wdi_controller.thumbUser = function(user) {
759
  /**
760
  * finds user by username in instagram api request object
761
  * if user is found then returns user object otherwise returns false
762
- *
763
  * @param {String} username [username we are searching for]
764
  * @param {Object} response [instagram API response]
765
- * @return {Boolenan || Object}
766
  */
767
  wdi_controller.findUser = function(username, response) {
768
  var data = [];
@@ -781,12 +781,12 @@ wdi_controller.findUser = function(username, response) {
781
  /**
782
  * Sanitizes hashtag and if it's ok then add it to internal wdi_controller.feed_users array
783
  * besodes that it also updates GUI
784
- *
785
  * @param {String} tagname [name of hashtag to add without '#']
786
  * @param {Object} response [instagram API response]
787
  */
788
  wdi_controller.addHashtag = function(tagname, response) {
789
- //if tagname doesn't contain invalid characters
790
  if (tagname.match(/[~!@$%&*#^()<>?]/) == null) {
791
  if (this.checkForDuplicateUser('#' + tagname) == false) {
792
  var newHashtag = jQuery('<div class="wdi_user"><a target="_blank" href="https://instagram.com/explore/tags/' + tagname + '">' + '<img class="wdi_profile_pic" src="' + wdi_url.plugin_url + '/images/hashtag.png"><span class="wdi_hashtag">' + tagname + '</span><i style="display:table-cell;width:25px;"></i></a><img class="wdi_remove_user" onclick="wdi_controller.removeFeedUser(jQuery(this))" src="' + wdi_url.plugin_url + '/images/delete_user.png"></div>');
@@ -825,7 +825,7 @@ wdi_controller.addHashtag = function(tagname, response) {
825
 
826
  /**
827
  * Adds given user to internal array wdi_controller.feed_users and also updates GUI
828
- *
829
  * @param {Object} user [Object conatining user information such as id, username and profile picture]
830
  */
831
  wdi_controller.addUser = function(user) {
@@ -858,8 +858,8 @@ wdi_controller.addUser = function(user) {
858
  /**
859
  * Scans internal wdi_controller.feed_users array and return profile picture url of given user
860
  * if there is no profile picture then returns blank string
861
- *
862
- * @param {String} username
863
  * @return {String} ['profile picture url of user']
864
  */
865
  wdi_controller.getUserProfilePic = function(username) {
@@ -904,10 +904,10 @@ wdi_controller.conditionalFiltersTabInit = function() {
904
  }
905
  });
906
 
907
-
908
-
909
-
910
-
911
  conditional_filters_toggler();
912
  jQuery('#WDI_wrap_conditional_filter_enable input').on('change',function(){
913
  conditional_filters_toggler();
@@ -934,7 +934,7 @@ wdi_controller.conditionalFiltersTabInit = function() {
934
 
935
  jQuery('#WDI_conditional_filter_type').on('change',function(){
936
  if(jQuery(this).val() == 'none'){
937
-
938
  }else{
939
  jQuery('#WDI_conditional_filters').css('display','block');
940
  }
@@ -971,7 +971,7 @@ wdi_controller.conditionalFiltersTabInit = function() {
971
  jQuery('#WDI_conditional_filters').css('display','block');
972
  jQuery(this).parent().find('label').html(wdi_messages.nor_descr);
973
  break;
974
- }
975
  }
976
 
977
  wdi_controller.updateFiltersUi();
@@ -1059,17 +1059,17 @@ wdi_controller.filterExists = function(filter) {
1059
 
1060
 
1061
  /**
1062
- * Updates #wdi_filters_ui div to the latest version of filters according wdi_controller.conditionalFilters
1063
  */
1064
  wdi_controller.updateFiltersUi = function(){
1065
  var uiElement = jQuery('#wdi_filters_ui').html('');
1066
  for( var i = 0; i < this.conditionalFilters.length; i++ ){
1067
-
1068
  if( i == 0 ){
1069
  if( this.conditionalFilters.length != 1 ){
1070
  switch( jQuery('#WDI_conditional_filter_type').val() ){
1071
  case 'AND':{
1072
-
1073
  break;
1074
  }
1075
  case 'OR':{
@@ -1095,7 +1095,7 @@ wdi_controller.updateFiltersUi = function(){
1095
  }
1096
  }
1097
  }
1098
-
1099
  }
1100
 
1101
  var glue;
@@ -1236,14 +1236,14 @@ wdi_controller.updateFilterSource = function(){
1236
  username = jQuery( this ).find( '.wdi_username' ).text();
1237
  }else{
1238
  username = jQuery( this ).find( '.wdi_hashtag' ).text();
1239
- }
1240
  userThumb = jQuery( this ).find( 'img' ).attr('src');
1241
  users.push( {
1242
  'username' : username,
1243
  'image' : userThumb
1244
  } )
1245
  });
1246
-
1247
  var sourceDiv = jQuery('#wdi_filter_source').html('');
1248
  for ( var i = 0; i < users.length; i++ ){
1249
  var singleUserHtml = "<div class='wdi_source_user'><span class='wdi_source_img'><img src='" + users[i].image + "'></span><span class='wdi_source_username'>"+users[i].username+"</span></div>";
33
  }
34
 
35
  /**
36
+ * Was tirggerd when redirected from api page
37
  * Sets access token from query string to input
38
  */
39
  wdi_controller.apiRedirected = function() {
60
  /**
61
  * Used in Settings page for finding access token owners username
62
  * and and for filling it in username input field
63
+ *
64
  * @param {String} access_token [Instagram API access token]
65
  */
66
  wdi_controller.getUserInfo = function(access_token) {
100
  //showing only requested display_type tab elements
101
  jQuery('.display_type[tab="' + tabname + '"]').css('display', 'block');
102
 
103
+ //swap active tab class
104
  jQuery('.wdi_feed_tabs').filter('.wdi_feed_tab_active').each(function() {
105
  jQuery(this).removeClass('wdi_feed_tab_active');
106
  });
199
  wdi_controller.switchThemeTabs = function(tabname, section) {
200
 
201
 
202
+ //swap active tab class
203
  jQuery('.wdi_feed_tabs').filter('.wdi_feed_tab_active').each(function() {
204
  jQuery(this).removeClass('wdi_feed_tab_active');
205
  });
344
  * instagram request for getting meta info such as username and user id
345
  * stores getted data in wdi_controller.feed_users array and updates some admin elements which
346
  * depend on users
347
+ *
348
  * @param {String} user_input [username or hashtag, Note. hashtags should start with #]
349
  * @param {String} backend [if is set to 'backend' all confirms will be ignored while making requests]
350
+ * @return {Void}
351
  */
352
  wdi_controller.makeInstagramUserRequest = function(user_input, ignoreConfirm) {
353
 
519
 
520
  /**
521
  * Binds 'click' and 'enter' event to add user button
522
+ *
523
  */
524
  wdi_controller.bindAddNewUserOrHashtagEvent = function() {
525
  jQuery('#wdi_add_user_ajax').on('click', function() {
539
  /**
540
  * Removes users from internal wdi_controller.feed_users array and also
541
  * updates GUI (by removing user elements)
542
+ *
543
  * @param {Object} $this [jQuery object of remove user button]
544
  */
545
  wdi_controller.removeFeedUser = function($this) {
567
  if( jQuery('.wdi_user').length == 0 ){
568
  jQuery('#wdi_add_user_ajax_input').removeAttr('disabled');
569
  jQuery('#wdi_add_user_ajax_input').attr('placeholder','');
570
+ }
571
  }
572
 
573
  }
575
 
576
  /**
577
  * Adds or removes users from featured image select
578
+ *
579
  * @param {String} username [username of user we want to add/remove]
580
  * @param {String} action [valid options are 'add' and 'remove']
581
  * @param {String} selected [if is set 'selected' then user will be marked as selected in select element]
637
  * it checks if user has typed any username in unsername input
638
  * but forgetted to add it then it creates an object called wdi_controller.waitingAjaxRequestEnd
639
  * which previous task
640
+ *
641
  * @param {String} task [how to save element save/apply/reset]
642
  * @return {Boolean} [1 if user forgotted to save and 0 if input field was empty]
643
  */
679
 
680
  /**
681
  * if user was clicked save before ajax request then trigger save after getting info
682
+ *
683
  * @param {String} correctUserFlag [if set to false form wouldn't be submitted]
684
  */
685
  wdi_controller.saveFeedAfterAjaxWait = function(correctUserFlag) {
710
  * Checks if response has meta code other then 200 or if it has not any data in it
711
  * then returns false
712
  * @param {Object} response [Instagram API response]
713
+ * @return {Boolean}
714
  */
715
  wdi_controller.isValidResponse = function(response) {
716
 
759
  /**
760
  * finds user by username in instagram api request object
761
  * if user is found then returns user object otherwise returns false
762
+ *
763
  * @param {String} username [username we are searching for]
764
  * @param {Object} response [instagram API response]
765
+ * @return {Boolenan || Object}
766
  */
767
  wdi_controller.findUser = function(username, response) {
768
  var data = [];
781
  /**
782
  * Sanitizes hashtag and if it's ok then add it to internal wdi_controller.feed_users array
783
  * besodes that it also updates GUI
784
+ *
785
  * @param {String} tagname [name of hashtag to add without '#']
786
  * @param {Object} response [instagram API response]
787
  */
788
  wdi_controller.addHashtag = function(tagname, response) {
789
+ //if tagname doesn't contain invalid characters
790
  if (tagname.match(/[~!@$%&*#^()<>?]/) == null) {
791
  if (this.checkForDuplicateUser('#' + tagname) == false) {
792
  var newHashtag = jQuery('<div class="wdi_user"><a target="_blank" href="https://instagram.com/explore/tags/' + tagname + '">' + '<img class="wdi_profile_pic" src="' + wdi_url.plugin_url + '/images/hashtag.png"><span class="wdi_hashtag">' + tagname + '</span><i style="display:table-cell;width:25px;"></i></a><img class="wdi_remove_user" onclick="wdi_controller.removeFeedUser(jQuery(this))" src="' + wdi_url.plugin_url + '/images/delete_user.png"></div>');
825
 
826
  /**
827
  * Adds given user to internal array wdi_controller.feed_users and also updates GUI
828
+ *
829
  * @param {Object} user [Object conatining user information such as id, username and profile picture]
830
  */
831
  wdi_controller.addUser = function(user) {
858
  /**
859
  * Scans internal wdi_controller.feed_users array and return profile picture url of given user
860
  * if there is no profile picture then returns blank string
861
+ *
862
+ * @param {String} username
863
  * @return {String} ['profile picture url of user']
864
  */
865
  wdi_controller.getUserProfilePic = function(username) {
904
  }
905
  });
906
 
907
+
908
+
909
+
910
+
911
  conditional_filters_toggler();
912
  jQuery('#WDI_wrap_conditional_filter_enable input').on('change',function(){
913
  conditional_filters_toggler();
934
 
935
  jQuery('#WDI_conditional_filter_type').on('change',function(){
936
  if(jQuery(this).val() == 'none'){
937
+
938
  }else{
939
  jQuery('#WDI_conditional_filters').css('display','block');
940
  }
971
  jQuery('#WDI_conditional_filters').css('display','block');
972
  jQuery(this).parent().find('label').html(wdi_messages.nor_descr);
973
  break;
974
+ }
975
  }
976
 
977
  wdi_controller.updateFiltersUi();
1059
 
1060
 
1061
  /**
1062
+ * Updates #wdi_filters_ui div to the latest version of filters according wdi_controller.conditionalFilters
1063
  */
1064
  wdi_controller.updateFiltersUi = function(){
1065
  var uiElement = jQuery('#wdi_filters_ui').html('');
1066
  for( var i = 0; i < this.conditionalFilters.length; i++ ){
1067
+
1068
  if( i == 0 ){
1069
  if( this.conditionalFilters.length != 1 ){
1070
  switch( jQuery('#WDI_conditional_filter_type').val() ){
1071
  case 'AND':{
1072
+
1073
  break;
1074
  }
1075
  case 'OR':{
1095
  }
1096
  }
1097
  }
1098
+
1099
  }
1100
 
1101
  var glue;
1236
  username = jQuery( this ).find( '.wdi_username' ).text();
1237
  }else{
1238
  username = jQuery( this ).find( '.wdi_hashtag' ).text();
1239
+ }
1240
  userThumb = jQuery( this ).find( 'img' ).attr('src');
1241
  users.push( {
1242
  'username' : username,
1243
  'image' : userThumb
1244
  } )
1245
  });
1246
+
1247
  var sourceDiv = jQuery('#wdi_filter_source').html('');
1248
  for ( var i = 0; i < users.length; i++ ){
1249
  var singleUserHtml = "<div class='wdi_source_user'><span class='wdi_source_img'><img src='" + users[i].image + "'></span><span class='wdi_source_username'>"+users[i].username+"</span></div>";
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://web-dorado.com/products/wordpress-instagram-feed-wd.html
4
  Tags: : custom instagram feed, feed, instagram, hashtag, Instagram feed, instagram gallery, instagram posts, Instagram images, Instagram photos, Instagram wall, lightbox, photos
5
  Requires at least: 3.9
6
  Tested up to: 4.7
7
- Stable tag: 1.1.23
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -107,6 +107,10 @@ After downloading the ZIP file of the Instagram Feed WD plugin,
107
 
108
  == Changelog ==
109
 
 
 
 
 
110
  = 1.1.23 =
111
  Fixed: cropping of "landscape" images in thumbnails layout
112
 
4
  Tags: : custom instagram feed, feed, instagram, hashtag, Instagram feed, instagram gallery, instagram posts, Instagram images, Instagram photos, Instagram wall, lightbox, photos
5
  Requires at least: 3.9
6
  Tested up to: 4.7
7
+ Stable tag: 1.1.24
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
107
 
108
  == Changelog ==
109
 
110
+ = 1.1.24 =
111
+ Added: Overview page
112
+ Changed: Deactivation
113
+
114
  = 1.1.23 =
115
  Fixed: cropping of "landscape" images in thumbnails layout
116
 
wd-instagram-feed.php CHANGED
@@ -1,9 +1,9 @@
1
- <?php
2
  /*
3
  Plugin Name: Instagram Feed WD
4
  Plugin URI: https://web-dorado.com/products/wordpress-instagram-feed-wd.html
5
  Description: WD Instagram Feed is a user-friendly tool for displaying user or hashtag-based feeds on your website. You can create feeds with one of the available layouts. It allows displaying image metadata, open up images in lightbox, download them and even share in social networking websites.
6
- Version: 1.1.23
7
  Author: WebDorado
8
  Author URI: https://web-dorado.com
9
  License: GPLv2 or later
@@ -30,7 +30,7 @@ function wdi_use_home_url() {
30
  $pos = strpos($home_url, "/");
31
  if ($pos) {
32
  $home_url = substr($home_url, 0, $pos);
33
- }
34
  $site_url = str_replace("http://", "", WDI_URL);
35
  $site_url = str_replace("https://", "", $site_url);
36
  $pos = strpos($site_url, "/");
@@ -53,6 +53,7 @@ else {
53
 
54
  add_action('wp_ajax_WDIGalleryBox', 'wdi_ajax_frontend');
55
  add_action('wp_ajax_nopriv_WDIGalleryBox', 'wdi_ajax_frontend');
 
56
  function wdi_ajax_frontend() {
57
 
58
  /* reset from user to site locale*/
@@ -103,12 +104,21 @@ function wdi_instagram_activate($networkwide) {
103
  return;
104
  }
105
  }
106
- // wdi_activate();
 
107
  wdi_install();
108
  }
 
 
 
 
 
 
 
 
 
109
 
110
 
111
-
112
 
113
 
114
 
@@ -129,61 +139,70 @@ function wdi_register_settings(){
129
  //adding settings fileds form getted settings
130
  foreach($settings as $setting_name => $setting){
131
  if(isset($setting['field_or_not'])==true && $setting['field_or_not']!='no_field'){
132
- add_settings_field(
133
  $setting_name,
134
  $setting['title'],
135
  'wdi_field_callback',
136
  'settings_wdi',
137
  $setting['section'],
138
  array($setting)
139
- );
140
  }
141
  }
142
 
143
  //registering all settings
144
  register_setting( 'wdi_all_settings', 'wdi_instagram_options','wdi_sanitize_options');
145
 
146
- wdi_get_options();
147
  }
148
 
149
 
150
  //adding menues
151
- add_action('admin_menu', 'WDI_instagram_menu');
152
  add_action('admin_head-toplevel_page_wdi_feeds', 'wdi_check_necessary_params');
153
  function WDI_instagram_menu() {
154
- $menu_icon = WDI_URL .'/images/menu_icon.png';
155
- global $wdi_options;
156
- $min_feeds_capability = isset($wdi_options['wdi_feeds_min_capability']) ? $wdi_options['wdi_feeds_min_capability'] : "manage_options";
157
- $min_feeds_capability = $min_feeds_capability == 'publish_posts' ? 'publish_posts' : "manage_options";
158
-
159
- $settings_page = add_menu_page(__('Instagram Feed WD',"wdi"), __('Instagram Feed WD',"wdi"),$min_feeds_capability,'wdi_feeds','WDI_instagram_feeds_page',$menu_icon);
160
- add_submenu_page('wdi_feeds',__('Feeds',"wdi"),__('Feeds',"wdi"),$min_feeds_capability,'wdi_feeds','WDI_instagram_feeds_page');
161
- add_submenu_page('wdi_feeds',__('Themes',"wdi"),__('Themes',"wdi"),$min_feeds_capability,'wdi_themes','WDI_instagram_themes_page');
162
- add_submenu_page('wdi_feeds',__('Settings',"wdi"),__('Settings',"wdi"),'manage_options','wdi_settings','WDI_instagram_settings_page');
163
- add_submenu_page('wdi_feeds',__('Featured Themes',"wdi"),__('Featured Themes',"wdi"),$min_feeds_capability,'wdi_featured_themes','wdi_featured_themes');
164
- add_submenu_page('wdi_feeds',__('Featured Plugins',"wdi"),__('Featured Plugins',"wdi"),$min_feeds_capability,'wdi_featured_plugins','wdi_featured_plugins');
165
- add_submenu_page('wdi_feeds',__('Upgrade to Pro',"wdi"),__('Upgrade to Pro',"wdi"),$min_feeds_capability,'wdi_licensing','WDI_instagram_licensing_page');
 
 
 
 
166
 
167
  }
168
 
169
 
170
  add_action('admin_menu', 'WDI_add_uninstall',26);
171
  function WDI_add_uninstall(){
172
- add_submenu_page('wdi_feeds',__('Uninstall',"wdi"),__('Uninstall',"wdi"),'manage_options','wdi_uninstall','WDI_instagram_uninstall_page');
 
 
 
 
 
173
  }
174
 
175
  //Settings page callback
176
  function WDI_instagram_settings_page(){
177
 
178
-
179
  //check if user has already unistalled plugin from settings
180
  wdi_check_uninstalled();
181
  require_once(WDI_DIR . '/framework/WDILibrary.php');
182
- $controller_class = "WDIControllerSettings_wdi";
183
  require_once(WDI_DIR . '/admin/controllers/' . $controller_class . '.php');
184
  $controller = new $controller_class();
185
  $controller->execute();
186
-
187
  }
188
  function WDI_instagram_feeds_page(){
189
  //check if user has already unistalled plugin from settings
@@ -210,17 +229,7 @@ function WDI_instagram_licensing_page(){
210
  $controller->execute();
211
  }
212
 
213
- function wdi_featured_themes(){
214
- require_once(WDI_DIR . '/featured/WDIFeaturedThemes.php');
215
- $controller = new WDIFeaturedThemes();
216
- $controller->display();
217
- }
218
 
219
- function wdi_featured_plugins(){
220
- require_once(WDI_DIR . '/featured/WDIFeaturedPlugins.php');
221
- $controller = new WDIFeaturedPlugins();
222
- $controller->display();
223
- }
224
 
225
  function WDI_instagram_uninstall_page(){
226
 
@@ -234,7 +243,8 @@ function WDI_instagram_uninstall_page(){
234
  //loading admin scripts
235
  add_action('admin_enqueue_scripts','wdi_load_scripts');
236
 
237
- function wdi_load_scripts(){
 
238
  require_once(WDI_DIR . '/framework/WDILibrary.php');
239
  global $wdi_options;
240
  $page = WDILibrary::get('page');
@@ -245,45 +255,57 @@ function wdi_load_scripts(){
245
  wp_enqueue_script('wdi_admin',plugins_url('js/wdi_admin.js', __FILE__),array("jquery",'wdi_instagram'), WDI_VERSION );
246
 
247
  $uninstall_url = wp_nonce_url( admin_url( 'admin-ajax.php' ), 'wdiUninstallPlugin', 'uninstall_nonce' );
248
-
249
  wp_enqueue_script('wdi_instagram',plugins_url('js/wdi_instagram.js', __FILE__),array("jquery"), WDI_VERSION );
250
 
251
 
252
- wp_localize_script("wdi_admin", 'wdi_ajax',array( 'ajax_url' => admin_url( 'admin-ajax.php' ),
253
- 'uninstall_url' => $uninstall_url,
254
- 'is_pro' => WDI_IS_PRO
255
- ));
256
  wp_localize_script("wdi_admin", 'wdi_version',array('is_pro'=>WDI_IS_PRO));
257
 
258
- wp_localize_script("wdi_admin", 'wdi_messages',array(
259
- 'uninstall_confirm' => __( "All the data will be removed from the database. Continue?", "wdi" ),
260
- 'instagram_server_error' => __('Some error with instagram servers, try agian later :(', "wdi" ),
261
- 'invalid_user' => __('Invalid user:', "wdi" ),
262
- 'already_added' => __('already added!', "wdi"),
263
- 'user_not_exist' => __('User does not exist.', "wdi"),
264
- 'network_error' => __("Network Error, please try again later. :(", "wdi"),
265
- 'invalid_hashtag' => __('Invalid hashtag', "wdi"),
266
- 'hashtag_no_data' => __('This hashtag currently has no posts. Are you sure you want to add it?','wdi'),
267
- 'only_one_user_or_hashtag'=> __('You can add only one username or hashtag in FREE Version', "wdi"),
268
- 'available_in_pro' => __('Available in PRO','wdi'),
269
- 'username_hashtag_multiple' => __('Combined Usernames/Hashtags are available only in PRO version'),
270
- 'theme_save_message_free' => __('Customizing Themes is available only in PRO version','wdi'),
271
- 'invalid_url' => __('URL is not valid','wdi'),
272
- 'selectConditionType' => __('Please Select Condition Type','wdi'),
273
- 'and_descr' => __('Show Posts Which Have All Of The Conditions','wdi'),
274
- 'or_descr' => __('Show Posts Which Have At Least One Of The Conditions','wdi'),
275
- 'nor_descr' => __('Hide Posts Which Have At Least One Of The Conditions','wdi'),
276
- 'either' => __('EITHER','wdi'),
277
- 'neither' => __('NEITHER','wdi'),
278
- 'not' => __('EXCEPT','wdi'),
279
- 'and' => __('AND','wdi'),
280
- 'or' => __('OR','wdi'),
281
- 'nor' => __('NOR','wdi')
282
- ));
283
  wp_localize_script("wdi_admin", 'wdi_url',array('plugin_url'=>plugin_dir_url(__FILE__)));
284
  wp_localize_script("wdi_admin", 'wdi_admin',array('admin_url' =>get_admin_url()));
285
  }
286
 
 
 
 
 
 
 
 
 
 
 
 
 
287
 
288
  }
289
 
@@ -296,12 +318,15 @@ function wdi_load_styles() {
296
  if($page === 'wdi_themes' || $page === 'wdi_feeds' || $page === 'wdi_settings' || $page==='wdi_uninstall'){
297
  wp_enqueue_style('wdi_backend', plugins_url('css/wdi_backend.css', __FILE__), array(), WDI_VERSION);
298
  wp_enqueue_style('wdi_tables', plugins_url('css/wdi_tables.css', __FILE__), array(), WDI_VERSION);
299
- wp_enqueue_style('wdi_admin_notices', plugins_url('css/notices.css', __FILE__), array(), WDI_VERSION);
300
  }
301
  if($page === 'wdi_licensing'){
302
  wp_enqueue_style('wdi_licensing', plugins_url('css/wdi_licensing.css', __FILE__), array(), WDI_VERSION);
303
  }
304
-
 
 
 
305
  }
306
 
307
 
@@ -354,8 +379,8 @@ function wdi_editor_button(){
354
  }
355
 
356
  /**
357
- * handle editor popup
358
- */
359
  add_action('admin_head', 'wdi_admin_ajax');
360
 
361
  function wdi_admin_ajax() {
@@ -406,8 +431,8 @@ add_action( 'init', 'wdi_load_textdomain' );
406
  *
407
  */
408
  function wdi_load_textdomain() {
409
- load_plugin_textdomain( "wdi", false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );
410
-
411
  }
412
 
413
  add_action('init', 'wdi_check_silent_update');
@@ -427,4 +452,135 @@ function wdi_check_silent_update(){
427
  wdi_install();
428
  }
429
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
430
 
1
+ <?php
2
  /*
3
  Plugin Name: Instagram Feed WD
4
  Plugin URI: https://web-dorado.com/products/wordpress-instagram-feed-wd.html
5
  Description: WD Instagram Feed is a user-friendly tool for displaying user or hashtag-based feeds on your website. You can create feeds with one of the available layouts. It allows displaying image metadata, open up images in lightbox, download them and even share in social networking websites.
6
+ Version: 1.1.24
7
  Author: WebDorado
8
  Author URI: https://web-dorado.com
9
  License: GPLv2 or later
30
  $pos = strpos($home_url, "/");
31
  if ($pos) {
32
  $home_url = substr($home_url, 0, $pos);
33
+ }
34
  $site_url = str_replace("http://", "", WDI_URL);
35
  $site_url = str_replace("https://", "", $site_url);
36
  $pos = strpos($site_url, "/");
53
 
54
  add_action('wp_ajax_WDIGalleryBox', 'wdi_ajax_frontend');
55
  add_action('wp_ajax_nopriv_WDIGalleryBox', 'wdi_ajax_frontend');
56
+ add_action('admin_init', 'setup_redirect');
57
  function wdi_ajax_frontend() {
58
 
59
  /* reset from user to site locale*/
104
  return;
105
  }
106
  }
107
+ add_option('wdi_do_activation_set_up_redirect', 1);
108
+ // wdi_activate();
109
  wdi_install();
110
  }
111
+ function setup_redirect() {
112
+ if (get_option('wdi_do_activation_set_up_redirect')) {
113
+ update_option('wdi_do_activation_set_up_redirect',0);
114
+ //wp_safe_redirect( admin_url( 'index.php?page=gmwd_setup' ) );
115
+ wp_safe_redirect( admin_url( 'admin.php?page=wdi_subscribe' ) );
116
+ exit;
117
+ }
118
+ }
119
+
120
 
121
 
 
122
 
123
 
124
 
139
  //adding settings fileds form getted settings
140
  foreach($settings as $setting_name => $setting){
141
  if(isset($setting['field_or_not'])==true && $setting['field_or_not']!='no_field'){
142
+ add_settings_field(
143
  $setting_name,
144
  $setting['title'],
145
  'wdi_field_callback',
146
  'settings_wdi',
147
  $setting['section'],
148
  array($setting)
149
+ );
150
  }
151
  }
152
 
153
  //registering all settings
154
  register_setting( 'wdi_all_settings', 'wdi_instagram_options','wdi_sanitize_options');
155
 
156
+ wdi_get_options();
157
  }
158
 
159
 
160
  //adding menues
161
+ add_action('admin_menu', 'WDI_instagram_menu', 9);
162
  add_action('admin_head-toplevel_page_wdi_feeds', 'wdi_check_necessary_params');
163
  function WDI_instagram_menu() {
164
+ $menu_icon = WDI_URL .'/images/menu_icon.png';
165
+ $min_feeds_capability = wdi_get_create_feeds_cap();
166
+
167
+
168
+
169
+ $parent_slug = null;
170
+ if( get_option( "wdi_subscribe_done" ) == 1 ){
171
+ $parent_slug = "wdi_feeds";
172
+ $settings_page = add_menu_page(__('Instagram Feed WD',"wdi"), __('Instagram Feed WD',"wdi"),$min_feeds_capability,'wdi_feeds','WDI_instagram_feeds_page',$menu_icon);
173
+ }
174
+ add_submenu_page($parent_slug,__('Feeds',"wdi"),__('Feeds',"wdi"),$min_feeds_capability,'wdi_feeds','WDI_instagram_feeds_page');
175
+ add_submenu_page($parent_slug,__('Themes',"wdi"),__('Themes',"wdi"),$min_feeds_capability,'wdi_themes','WDI_instagram_themes_page');
176
+ add_submenu_page($parent_slug,__('Settings',"wdi"),__('Settings',"wdi"),'manage_options','wdi_settings','WDI_instagram_settings_page');
177
+ //add_submenu_page('overview_wdi',__('Featured Themes',"wdi"),__('Featured Themes',"wdi"),$min_feeds_capability,'wdi_featured_themes','wdi_featured_themes');
178
+ //add_submenu_page('overview_wdi',__('Featured Plugins',"wdi"),__('Featured Plugins',"wdi"),$min_feeds_capability,'wdi_featured_plugins','wdi_featured_plugins');
179
+ add_submenu_page($parent_slug,__('Upgrade to Pro',"wdi"),__('Upgrade to Pro',"wdi"),$min_feeds_capability,'wdi_licensing','WDI_instagram_licensing_page');
180
 
181
  }
182
 
183
 
184
  add_action('admin_menu', 'WDI_add_uninstall',26);
185
  function WDI_add_uninstall(){
186
+ $parent_slug = null;
187
+ if( get_option( "wdi_subscribe_done" ) == 1 ){
188
+ $parent_slug = "wdi_feeds";
189
+ }
190
+
191
+ add_submenu_page($parent_slug,__('Uninstall',"wdi"),__('Uninstall',"wdi"),'manage_options','wdi_uninstall','WDI_instagram_uninstall_page');
192
  }
193
 
194
  //Settings page callback
195
  function WDI_instagram_settings_page(){
196
 
197
+
198
  //check if user has already unistalled plugin from settings
199
  wdi_check_uninstalled();
200
  require_once(WDI_DIR . '/framework/WDILibrary.php');
201
+ $controller_class = "WDIControllerSettings_wdi";
202
  require_once(WDI_DIR . '/admin/controllers/' . $controller_class . '.php');
203
  $controller = new $controller_class();
204
  $controller->execute();
205
+
206
  }
207
  function WDI_instagram_feeds_page(){
208
  //check if user has already unistalled plugin from settings
229
  $controller->execute();
230
  }
231
 
 
 
 
 
 
232
 
 
 
 
 
 
233
 
234
  function WDI_instagram_uninstall_page(){
235
 
243
  //loading admin scripts
244
  add_action('admin_enqueue_scripts','wdi_load_scripts');
245
 
246
+ function wdi_load_scripts($hook){
247
+
248
  require_once(WDI_DIR . '/framework/WDILibrary.php');
249
  global $wdi_options;
250
  $page = WDILibrary::get('page');
255
  wp_enqueue_script('wdi_admin',plugins_url('js/wdi_admin.js', __FILE__),array("jquery",'wdi_instagram'), WDI_VERSION );
256
 
257
  $uninstall_url = wp_nonce_url( admin_url( 'admin-ajax.php' ), 'wdiUninstallPlugin', 'uninstall_nonce' );
258
+
259
  wp_enqueue_script('wdi_instagram',plugins_url('js/wdi_instagram.js', __FILE__),array("jquery"), WDI_VERSION );
260
 
261
 
262
+ wp_localize_script("wdi_admin", 'wdi_ajax',array( 'ajax_url' => admin_url( 'admin-ajax.php' ),
263
+ 'uninstall_url' => $uninstall_url,
264
+ 'is_pro' => WDI_IS_PRO
265
+ ));
266
  wp_localize_script("wdi_admin", 'wdi_version',array('is_pro'=>WDI_IS_PRO));
267
 
268
+ wp_localize_script("wdi_admin", 'wdi_messages',array(
269
+ 'uninstall_confirm' => __( "All the data will be removed from the database. Continue?", "wdi" ),
270
+ 'instagram_server_error' => __('Some error with instagram servers, try agian later :(', "wdi" ),
271
+ 'invalid_user' => __('Invalid user:', "wdi" ),
272
+ 'already_added' => __('already added!', "wdi"),
273
+ 'user_not_exist' => __('User does not exist.', "wdi"),
274
+ 'network_error' => __("Network Error, please try again later. :(", "wdi"),
275
+ 'invalid_hashtag' => __('Invalid hashtag', "wdi"),
276
+ 'hashtag_no_data' => __('This hashtag currently has no posts. Are you sure you want to add it?','wdi'),
277
+ 'only_one_user_or_hashtag'=> __('You can add only one username or hashtag in FREE Version', "wdi"),
278
+ 'available_in_pro' => __('Available in PRO','wdi'),
279
+ 'username_hashtag_multiple' => __('Combined Usernames/Hashtags are available only in PRO version'),
280
+ 'theme_save_message_free' => __('Customizing Themes is available only in PRO version','wdi'),
281
+ 'invalid_url' => __('URL is not valid','wdi'),
282
+ 'selectConditionType' => __('Please Select Condition Type','wdi'),
283
+ 'and_descr' => __('Show Posts Which Have All Of The Conditions','wdi'),
284
+ 'or_descr' => __('Show Posts Which Have At Least One Of The Conditions','wdi'),
285
+ 'nor_descr' => __('Hide Posts Which Have At Least One Of The Conditions','wdi'),
286
+ 'either' => __('EITHER','wdi'),
287
+ 'neither' => __('NEITHER','wdi'),
288
+ 'not' => __('EXCEPT','wdi'),
289
+ 'and' => __('AND','wdi'),
290
+ 'or' => __('OR','wdi'),
291
+ 'nor' => __('NOR','wdi')
292
+ ));
293
  wp_localize_script("wdi_admin", 'wdi_url',array('plugin_url'=>plugin_dir_url(__FILE__)));
294
  wp_localize_script("wdi_admin", 'wdi_admin',array('admin_url' =>get_admin_url()));
295
  }
296
 
297
+ if($page == "wdi_uninstall") {
298
+ wp_enqueue_script('wdi-deactivate-popup', WDI_URL.'/wd/assets/js/deactivate_popup.js', array(), WDI_VERSION, true );
299
+ $admin_data = wp_get_current_user();
300
+
301
+ wp_localize_script( 'wdi-deactivate-popup', 'wdiWDDeactivateVars', array(
302
+ "prefix" => "wdi" ,
303
+ "deactivate_class" => 'wdi_deactivate_link',
304
+ "email" => $admin_data->data->user_email,
305
+ "plugin_wd_url" => "https://web-dorado.com/products/wordpress-instagram-feed-wd.html",
306
+ ));
307
+ }
308
+
309
 
310
  }
311
 
318
  if($page === 'wdi_themes' || $page === 'wdi_feeds' || $page === 'wdi_settings' || $page==='wdi_uninstall'){
319
  wp_enqueue_style('wdi_backend', plugins_url('css/wdi_backend.css', __FILE__), array(), WDI_VERSION);
320
  wp_enqueue_style('wdi_tables', plugins_url('css/wdi_tables.css', __FILE__), array(), WDI_VERSION);
321
+ //wp_enqueue_style('wdi_admin_notices', plugins_url('css/notices.css', __FILE__), array(), WDI_VERSION);
322
  }
323
  if($page === 'wdi_licensing'){
324
  wp_enqueue_style('wdi_licensing', plugins_url('css/wdi_licensing.css', __FILE__), array(), WDI_VERSION);
325
  }
326
+ if($page == "wdi_uninstall") {
327
+ wp_enqueue_style('wdi_deactivate-css', WDI_URL . '/wd/assets/css/deactivate_popup.css', array(), WDI_VERSION);
328
+ }
329
+
330
  }
331
 
332
 
379
  }
380
 
381
  /**
382
+ * handle editor popup
383
+ */
384
  add_action('admin_head', 'wdi_admin_ajax');
385
 
386
  function wdi_admin_ajax() {
431
  *
432
  */
433
  function wdi_load_textdomain() {
434
+ load_plugin_textdomain( "wdi", false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );
435
+
436
  }
437
 
438
  add_action('init', 'wdi_check_silent_update');
452
  wdi_install();
453
  }
454
  }
455
+ add_action('init', 'wdi_wd_lib_init');
456
+
457
+
458
+ function wdi_wd_lib_init(){
459
+ if(!isset($_REQUEST['ajax']) && is_admin()){
460
+
461
+ if( !class_exists("DoradoWeb") ){
462
+ require_once(WDI_DIR . '/wd/start.php');
463
+ }
464
+ global $wdi_wd_plugin_options;
465
+ $wdi_wd_plugin_options = array (
466
+ "prefix" => "wdi",
467
+ "wd_plugin_id" => 121,
468
+ "plugin_title" => "Instagram WD",
469
+ "plugin_wordpress_slug" => "wd-instagram-feed",
470
+ "plugin_dir" => WDI_DIR,
471
+ "plugin_main_file" => __FILE__,
472
+ "description" => __("The most advanced and user-friendly Instagram plugin. Instagram Feed WD plugin allows you to display image feeds from single or multiple Instagram accounts on a WordPress site.", 'wdi'),
473
+ // from web-dorado.com
474
+ "plugin_features" => array(
475
+ 0 => array(
476
+ "title" => __("Responsive", "wdi"),
477
+ "description" => __("Instagram feeds are not only elegantly designed to be displayed on your website, but also come fully responsive for better user experience when using mobile devices and tables.", "wdi"),
478
+ ),
479
+ 1 => array(
480
+ "title" => __("SEO Friendly", "wdi"),
481
+ "description" => __("Instagram Feed WD uses clean coding and latest SEO techniques necessary to keep your pages and posts SEO-optimized.", "wdi"),
482
+ ),
483
+ 2 => array(
484
+ "title" => __("4 Fully Customizable Layouts", "wdi"),
485
+ "description" => __("There are four layout options for Instagram feeds: Thumbnails, Image Browser, Blog Style and Masonry. Display a feed as a simply arranged thumbnails with captions. Use Masonry layout to create a beautiful combination of images and captions. Create a blog feed by simply sharing Instagram posts with captions using blog style layout. Image browser layout saves space, yet allows to display larger images. In addition users can choose the number of the displayed images, layout columns, image order and etc.", "wdi"),
486
+ ),
487
+ 3 => array(
488
+ "title" => __("Individual and Mixed Feeds", "wdi"),
489
+ "description" => __("Create mixed and single feeds of Instagram posts. Single feeds can be based on public Instagram accounts and single Instagram hashtag. Mixed feeds can contain multiple public Instagram accounts and multiple Instagram hashtags. A front end filter is available for mixed feeds. Click to filter only one feed based on a single hashtag or account.", "wdi"),
490
+ ),
491
+ 4 => array(
492
+ "title" => __("Advanced Lightbox", "wdi"),
493
+ "description" => __("Upon clicking on image thumbnails an elegant lightbox will be opened, where you will find control buttons for displaying images in larger view, read image comments, captions, view image metadata and easily navigate between images. Lightbox can serve as a slider with various stunning slide transition effects. If the feed contains video, the video will be played within the lightbox as an HTML5 video.", "wdi"),
494
+ )
495
+ ),
496
+ // user guide from web-dorado.com
497
+ "user_guide" => array(
498
+ 0 => array(
499
+ "main_title" => __("Installation and configuration", "wdi"),
500
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/installation-and-configuration/installation.html",
501
+ "titles" => array(
502
+ array(
503
+ "title" => __("Getting Instagram Access Token", "wdi"),
504
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/installation-and-configuration/getting-access-token.html"
505
+ )
506
+ )
507
+ ),
508
+ 1 => array(
509
+ "main_title" => __("Creating an Instagram Feed", "wdi"),
510
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/creating-feeds.html",
511
+ "titles" => array(
512
+ array(
513
+ "title" => __("Thumbnails and Masonry Layouts", "wdi"),
514
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/creating-feeds/thumbnails-and-masonry-layouts.html",
515
+ ),
516
+ array(
517
+ "title" => __("Blog Style Layout", "wdi"),
518
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/creating-feeds/blog-style-layout.html",
519
+ ),
520
+ array(
521
+ "title" => __("Image Browser", "wdi"),
522
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/creating-feeds/image-browser.html",
523
+ ),
524
+ array(
525
+ "title" => __("Lightbox Settings", "wdi"),
526
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/creating-feeds/lightbox-settings.html",
527
+ ),
528
+ array(
529
+ "title" => __("Conditional Filters", "wdi"),
530
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/creating-feeds/conditional-filters.html",
531
+ ),
532
+ )
533
+ ),
534
+ 2 => array(
535
+ "main_title" => __("Publishing Instagram Feed", "wdi"),
536
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/publishing-feed.html",
537
+ "titles" => array(
538
+ array(
539
+ "title" => __("Publishing in a Page/Post", "wdi"),
540
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/publishing-feed/page-post.html",
541
+ ),
542
+ array(
543
+ "title" => __("Publishing as a Widget", "wdi"),
544
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/publishing-feed/widget.html",
545
+ ),
546
+ array(
547
+ "title" => __("Publishing by PHP function", "wdi"),
548
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/publishing-feed/php-function.html",
549
+ ),
550
+ )
551
+ ),
552
+ 3 => array(
553
+ "main_title" => __("Styling with Themes", "wdi"),
554
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/editing-themes.html",
555
+ "titles" => array()
556
+ ),
557
+ 4 => array(
558
+ "main_title" => __("Advanced customizing options", "wdi"),
559
+ "url" => "https://web-dorado.com/wordpress-instagram-feed-wd/advanced-customizing-options.html",
560
+ "titles" => array()
561
+ ),
562
+ ),
563
+ "overview_welcome_image" => null,
564
+ "video_youtube_id" => "ijdrpkVAfEw", // e.g. https://www.youtube.com/watch?v=ijdrpkVAfEw youtube id is the ijdrpkVAfEw
565
+ "plugin_wd_url" => "https://web-dorado.com/products/wordpress-instagram-feed-wd.html",
566
+ "plugin_wd_demo_link" => "http://wpdemo.web-dorado.com/instagram-wd/?_ga=1.208438225.212018776.1470817467",
567
+ "plugin_wd_addons_link" => "",
568
+ "after_subscribe" => "admin.php?page=overview_wdi", // this can be plagin overview page or set up page
569
+ "plugin_wizard_link" => "",
570
+ "plugin_menu_title" => "Instagram Feed WD",
571
+ "plugin_menu_icon" => WDI_URL . '/images/menu_icon.png',
572
+ "deactivate" => true,
573
+ "subscribe" => true,
574
+ "custom_post" => 'wdi_feeds', // if true => edit.php?post_type=contact
575
+ "menu_capability" => wdi_get_create_feeds_cap()
576
+ );
577
+
578
+ dorado_web_init($wdi_wd_plugin_options);
579
+
580
+ }
581
+
582
+
583
+ }
584
+
585
+
586
 
wd/README.md ADDED
@@ -0,0 +1,129 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Version: 1.0.5
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
{css → wd/assets/css}/notices.css RENAMED
@@ -6,29 +6,13 @@
6
  padding: 10px 40px 10px 125px;
7
  position: relative;
8
  }
9
- .wd-admin-notice-promo {
10
- background: #fff;
11
- border-top: 4px;
12
- display: block;
13
- min-height: 68px;
14
- padding: 10px 40px 0px 10px;
15
- margin: 10px 0;
16
- position: relative;
17
- }
18
-
19
- .wd-admin-notice-promo:after{
20
- content: '';
21
- display: table;
22
- clear: both;
23
- }
24
  .wd-admin-notice a {
25
  color: #10738B;
26
  }
27
- .wdi-notice-logo {
28
  clear: both;
29
  content: "";
30
  display: block;
31
- background-image: url("../images/notice.png");
32
  background-size: 108px auto;
33
  background-repeat: no-repeat;
34
  background-position: 0 45%;
@@ -52,12 +36,6 @@
52
  font-weight: normal;
53
  margin: 5px 0;
54
  }
55
- .wd-close-promo{
56
- position: absolute;
57
- top: 5px;
58
- right: 5px;
59
- }
60
-
61
  .wd-notice-body:after {
62
  clear: both;
63
  content: "";
@@ -74,18 +52,37 @@
74
  color: #10738B;
75
  }
76
 
77
- .wd_hny{
78
- background: url("../images/hny.jpg") no-repeat;
79
- background-position: center;
80
- background-size: 800px 200px;
81
- height: 200px;
82
- max-width: 100%;
83
- }
84
- .wd_hny a{
85
- display: block;
86
- height: 100%;
87
- }
88
 
89
- .wdi_notice_red .wd-notice-title{
90
- color:#ec4136;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
91
  }
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%;
36
  font-weight: normal;
37
  margin: 5px 0;
38
  }
 
 
 
 
 
 
39
  .wd-notice-body:after {
40
  clear: both;
41
  content: "";
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/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,106 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
+
36
+ jQuery("." + prefix + "_additional_details_wrap").html("");
37
+ jQuery(".wd-" + prefix + "-deactivate-popup").removeClass("wd-popup-active1 wd-popup-active2");
38
+ if(jQuery(this).val() == "reason_plugin_is_hard_to_use_technical_problems"){
39
+
40
+ additionalInfo = '<div class="wd-additional-active"><div><strong>Please describe your issue.</strong></div><br>' +
41
+ '<textarea name="' + prefix + '_additional_details" rows = "4"></textarea><br>' +
42
+ '<div>Our support will contact <input type="text" name="' + prefix + '_email" value="' + window[prefix + "WDDeactivateVars"].email + '"> shortly.</div>'+
43
+ '<br><div><button class="button button-primary wd-' + prefix + '-deactivate" data-val="' + btnVal + '">Submit support ticket</button></div></div>';
44
+ jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
45
+ jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active1");
46
+
47
+ }
48
+ else if(jQuery(this).val() == "reason_free_version_limited"){
49
+ additionalInfo = '<div class="wd-additional-active">' +
50
+ '<div><strong>We believe our premium version will fit your needs.</strong></div>' +
51
+ '<div><a href="' + window[prefix + "WDDeactivateVars"].plugin_wd_url+ '" target="_blank">Try with 30 day money back guarantee.</a></div>';
52
+
53
+ jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
54
+ jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active2");
55
+ }
56
+ else if(jQuery(this).val() == "reason_premium_expensive"){
57
+ additionalInfo = '<div class="wd-additional-active">' +
58
+ '<div><strong>We have a special offer for you.</strong></div>' +
59
+ '<div>Submit this form to get the offer to <input type="text" name="' + prefix + '_email" value="' + window[prefix + "WDDeactivateVars"].email + '"></div>' +
60
+ '<br><div><button class="button button-primary wd-' + prefix + '-deactivate" data-val="' + btnVal + '">Submit</button></div></div>';
61
+
62
+ jQuery("." + prefix + "_additional_details_wrap").append(additionalInfo);
63
+ jQuery(".wd-" + prefix + "-deactivate-popup").addClass("wd-popup-active2");
64
+ }
65
+
66
+ jQuery("#wd-" + prefix + "-deactivate").hide();
67
+ jQuery("#wd-" + prefix + "-submit-and-deactivate").show();
68
+
69
+ });
70
+ jQuery(document).on("keyup", "[name=" + prefix + "_additional_details]", function(){
71
+ if(jQuery(this).val().trim() || jQuery("[name=" + prefix + "_reasons]:checked").length > 0){
72
+ jQuery("#wd-" + prefix + "-deactivate").hide();
73
+ jQuery("#wd-" + prefix + "-submit-and-deactivate").show();
74
+ }
75
+ else{
76
+ jQuery("#wd-" + prefix + "-deactivate").show();
77
+ jQuery("#wd-" + prefix + "-submit-and-deactivate").hide();
78
+ }
79
+
80
+ });
81
+ jQuery(document).on("click", ".wd-" + prefix + "-deactivate", function(){
82
+ jQuery(".wd-deactivate-popup-opacity-" + prefix).show();
83
+ if(jQuery(this).hasClass("wd-clicked") == false){
84
+ jQuery(this).addClass("wd-clicked");
85
+ jQuery("[name=" + prefix + "_submit_and_deactivate]").val(jQuery(this).attr("data-val"));
86
+ jQuery("#" + prefix + "_deactivate_form").submit();
87
+ }
88
+ return false;
89
+ });
90
+
91
+ jQuery(document).on("click", ".wd-" + prefix + "-cancel, .wd-opacity", function(){
92
+ jQuery(".wd-" + prefix + "-opacity").hide();
93
+ jQuery(".wd-" + prefix + "-deactivate-popup").hide();
94
+ return false;
95
+ });
96
+
97
+ }
98
+ ////////////////////////////////////////////////////////////////////////////////////////
99
+ // Getters & Setters //
100
+ ////////////////////////////////////////////////////////////////////////////////////////
101
+ ////////////////////////////////////////////////////////////////////////////////////////
102
+ // Private Methods //
103
+ ////////////////////////////////////////////////////////////////////////////////////////
104
+ ////////////////////////////////////////////////////////////////////////////////////////
105
+ // Listeners //
106
+ ////////////////////////////////////////////////////////////////////////////////////////
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_slug"] = $wd_options->plugin_wordpress_slug;
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 Deatils", $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
+