Free Tools to Automate Your Site Growth - Version 1.20

Version Description

Download this release

Release Info

Developer marnietave
Plugin Icon 128x128 Free Tools to Automate Your Site Growth
Version 1.20
Comparing to
See all releases

Code changes from version 1.19 to 1.20

Readme.txt CHANGED
@@ -2,8 +2,8 @@
2
  Contributors: SumoMe
3
  Tags: MailChimp, Aweber, Constant Contact, Campaign Monitor, GetResponse, ActiveCampaign, MyEmma, Mad Mimi, Infusionsoft, Feedblitz, HubSpot, MyNewsletterBuilder, Inbox First, Sailthru, Klaviyo, Vero, Pardot, Zapier, Ontraport, ExactTarget, Vertical Response, Drip, MailerLite, WhatCounts, ConvertKit, MailJet, Maropost, popup, exit intent, growth, subscribers, twitter, facebook share, social plugin, social sharing, subscription, email form, share, sharing, social , social media buttons , links, click to tweet , analytics , newsletter, widget,lightbox, analytics, newsletter, newsletter, Facebook, floating social buttons, google plus, Image sharing, pinterest plugin, pintrest, share image, sharebar, sharing, social bookmarking, social plugin, sms, tweet button, heat map, heatmaps, twitter share, contact form, scroll box, content analytics, inbound marketing, mailing list, share buttons, welcome mat, landing page
4
  Requires at least: 3.0.1
5
- Tested up to: 4.5.3
6
- Stable tag: 1.19
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -347,6 +347,9 @@ Why you should encourage Twitter sharing
347
  = 1.19 =
348
  * Fixes logout redirect, and updated WordPress tested version.
349
 
 
 
 
350
  == Upgrade Notice ==
351
 
352
  = 1.04 =
@@ -404,3 +407,6 @@ Why you should encourage Twitter sharing
404
 
405
  = 1.19 =
406
  * Fixes logout redirect, and updated WordPress tested version.
 
 
 
2
  Contributors: SumoMe
3
  Tags: MailChimp, Aweber, Constant Contact, Campaign Monitor, GetResponse, ActiveCampaign, MyEmma, Mad Mimi, Infusionsoft, Feedblitz, HubSpot, MyNewsletterBuilder, Inbox First, Sailthru, Klaviyo, Vero, Pardot, Zapier, Ontraport, ExactTarget, Vertical Response, Drip, MailerLite, WhatCounts, ConvertKit, MailJet, Maropost, popup, exit intent, growth, subscribers, twitter, facebook share, social plugin, social sharing, subscription, email form, share, sharing, social , social media buttons , links, click to tweet , analytics , newsletter, widget,lightbox, analytics, newsletter, newsletter, Facebook, floating social buttons, google plus, Image sharing, pinterest plugin, pintrest, share image, sharebar, sharing, social bookmarking, social plugin, sms, tweet button, heat map, heatmaps, twitter share, contact form, scroll box, content analytics, inbound marketing, mailing list, share buttons, welcome mat, landing page
4
  Requires at least: 3.0.1
5
+ Tested up to: 4.6.1
6
+ Stable tag: 1.20
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
347
  = 1.19 =
348
  * Fixes logout redirect, and updated WordPress tested version.
349
 
350
+ = 1.20 =
351
+ * Added social media. Fixed help link.
352
+
353
  == Upgrade Notice ==
354
 
355
  = 1.04 =
407
 
408
  = 1.19 =
409
  * Fixes logout redirect, and updated WordPress tested version.
410
+
411
+ = 1.20 =
412
+ * Added social media. Fixed help link.
classes/class_sumome.php CHANGED
@@ -50,11 +50,11 @@ class WP_Plugin_SumoMe {
50
 
51
  if (isset($_COOKIE['__smUser'])) {
52
  add_submenu_page('sumome', 'Dashboard', 'Dashboard', 'manage_options', 'sumome', array($this, 'sumome_render_dashboard_page') );
53
- add_submenu_page('sumome', 'Statistics', 'Statistics', 'manage_options', 'statistics', array($this, 'sumome_render_statistics_page'));
54
- add_submenu_page('sumome', 'About', 'About', 'manage_options', 'about', array($this, 'sumome_render_welcome_page'));
55
  }
56
 
57
- add_submenu_page(null, 'SiteID', 'SiteID', 'manage_options', 'siteID', array($this, 'sumome_render_siteID_page'));
58
  }
59
 
60
  public function sanitize_site_id($value) {
@@ -179,8 +179,13 @@ class WP_Plugin_SumoMe {
179
  <?php
180
  }
181
 
 
 
 
 
182
  public function ajax_sumome_main() {
183
  include(SUMOME__PLUGIN_DIR.'/views/main.php');
 
184
  exit;
185
  }
186
 
@@ -190,11 +195,11 @@ class WP_Plugin_SumoMe {
190
  }
191
 
192
  public function ajax_sumome_hide_dashboard_overlay() {
193
- update_option('sumome_hide_dashboard_overlay', true);
194
  }
195
 
196
  public function ajax_sumome_show_dashboard_overlay() {
197
- update_option('sumome_hide_dashboard_overlay', false);
198
  }
199
 
200
  public function dashboard_setup() {
@@ -203,9 +208,27 @@ class WP_Plugin_SumoMe {
203
 
204
  public function dashboard_widget() {
205
  $dashboardWidgetClass = '';
206
- if (isset($_COOKIE['__smUser']) || get_option('endurance_user')!=1 || get_option('sumome_hide_dashboard_overlay')==1) {
 
 
 
 
 
 
 
 
 
 
 
 
 
207
  $dashboardWidgetClass = 'minimized';
208
  }
 
 
 
 
 
209
  include_once(SUMOME__PLUGIN_DIR.'/js/general.php');
210
  echo '<div class="sumome-plugin-dashboard-widget '.$dashboardWidgetClass.'"></div>';
211
  ?>
50
 
51
  if (isset($_COOKIE['__smUser'])) {
52
  add_submenu_page('sumome', 'Dashboard', 'Dashboard', 'manage_options', 'sumome', array($this, 'sumome_render_dashboard_page') );
53
+ add_submenu_page('sumome', 'Statistics', 'Statistics', 'manage_options', 'sumome-statistics', array($this, 'sumome_render_statistics_page'));
54
+ add_submenu_page('sumome', 'About', 'About', 'manage_options', 'sumome-about', array($this, 'sumome_render_welcome_page'));
55
  }
56
 
57
+ add_submenu_page(null, 'SiteID', 'SiteID', 'manage_options', 'sumome-siteID', array($this, 'sumome_render_siteID_page'));
58
  }
59
 
60
  public function sanitize_site_id($value) {
179
  <?php
180
  }
181
 
182
+ public function sumome_plugin_footer() {
183
+ include(SUMOME__PLUGIN_DIR.'/views/footer.php');
184
+ }
185
+
186
  public function ajax_sumome_main() {
187
  include(SUMOME__PLUGIN_DIR.'/views/main.php');
188
+ $this->sumome_plugin_footer();
189
  exit;
190
  }
191
 
195
  }
196
 
197
  public function ajax_sumome_hide_dashboard_overlay() {
198
+ update_option('sumome_hide_dashboard_overlay', 1);
199
  }
200
 
201
  public function ajax_sumome_show_dashboard_overlay() {
202
+ update_option('sumome_hide_dashboard_overlay', 0);
203
  }
204
 
205
  public function dashboard_setup() {
208
 
209
  public function dashboard_widget() {
210
  $dashboardWidgetClass = '';
211
+
212
+ $enduranceUser=get_option('endurance_user');
213
+ $sumoMeInitialDashboardLoadTime=get_option('sumome_initial_wpdashboard_load_time');
214
+
215
+ $date = new DateTime($sumoMeInitialDashboardLoadTime);
216
+ $date->modify('+1 hour');
217
+ $sumoMeInitialDashboardLoadTimePlusHour=$date->format('YmdHis');
218
+
219
+ if (isset($_COOKIE['__smUser']) ||
220
+ $enduranceUser!=1 ||
221
+ get_option('sumome_hide_dashboard_overlay')==1 ||
222
+ !$sumoMeInitialDashboardLoadTime ||
223
+ ($enduranceUser==1 && date('YmdHis')<$sumoMeInitialDashboardLoadTimePlusHour)
224
+ ) {
225
  $dashboardWidgetClass = 'minimized';
226
  }
227
+
228
+ if (!$sumoMeInitialDashboardLoadTime) {
229
+ update_option('sumome_initial_wpdashboard_load_time',date('YmdHis'));
230
+ }
231
+
232
  include_once(SUMOME__PLUGIN_DIR.'/js/general.php');
233
  echo '<div class="sumome-plugin-dashboard-widget '.$dashboardWidgetClass.'"></div>';
234
  ?>
images/appsumo-logo.png ADDED
Binary file
images/facebook.png ADDED
Binary file
images/instagram.png ADDED
Binary file
images/twitter.png ADDED
Binary file
js/general.php CHANGED
@@ -87,7 +87,7 @@ jQuery(document).ready(function() {
87
  }
88
 
89
  if (dataName=="sumome-control-advanced-settings") {
90
- document.location.href='<?php print admin_url('admin.php?page=siteID')?>';
91
  } else if (jQuery(this).hasClass('sumome-popup-iframe')) {
92
  var popupHref=jQuery(this).data('href');
93
  if (jQuery(this).attr('href')) popupHref=jQuery(this).attr('href');
@@ -105,7 +105,7 @@ jQuery(document).ready(function() {
105
  } else if (dataName=="sumome-control-account-settings") {
106
  window.open('https://sumome.com/account');
107
  } else if (dataName=="sumome-control-statistics") {
108
- document.location.href='<?php print admin_url('admin.php?page=statistics')?>';
109
  } else {
110
  jQuery('.'+dataName).click();
111
  }
@@ -136,41 +136,15 @@ jQuery(document).ready(function() {
136
 
137
  });
138
 
139
- function getLoadInformation() {
140
- if (getCookie('__smUser')) {
141
- var data = {
142
- href: window.location.href || null,
143
- ref: document.referrer || null
144
- };
145
- data.site_id='<?php echo get_option('sumome_site_id')?>';
146
- jQuery.ajax({
147
- url: 'https://sumome.com/api/load',
148
- type: 'POST',
149
- dataType: 'json',
150
- beforeSend: function (req) {
151
- var token = getCookie('__smToken');
152
- if (token) {
153
- req.setRequestHeader('X-Sumo-Auth', token);
154
- }
155
-
156
- },
157
- xhrFields: {
158
- withCredentials: false
159
- },
160
- crossDomain: true,
161
- data: data,
162
- success: function(data) {
163
- if (data.login==false) {
164
- sumo_logout();
165
- } else {
166
- jQuery('.notification-count').remove();
167
- if (data.unreadNotificationCount>0) {
168
- jQuery('.sumo-notifications .item-tile-title').append('<div class="notification-count">'+data.unreadNotificationCount+'</div>');
169
- }
170
- }
171
- }
172
- });
173
  }
 
174
  }
175
 
176
  jQuery(window).load(function() {
87
  }
88
 
89
  if (dataName=="sumome-control-advanced-settings") {
90
+ document.location.href='<?php print admin_url('admin.php?page=sumome-siteID')?>';
91
  } else if (jQuery(this).hasClass('sumome-popup-iframe')) {
92
  var popupHref=jQuery(this).data('href');
93
  if (jQuery(this).attr('href')) popupHref=jQuery(this).attr('href');
105
  } else if (dataName=="sumome-control-account-settings") {
106
  window.open('https://sumome.com/account');
107
  } else if (dataName=="sumome-control-statistics") {
108
+ document.location.href='<?php print admin_url('admin.php?page=sumome-statistics')?>';
109
  } else {
110
  jQuery('.'+dataName).click();
111
  }
136
 
137
  });
138
 
139
+ function getLoadInformation(specificRequest) {
140
+ data=jQuery(document).triggerHandler('getSandbox');
141
+
142
+ //notifications
143
+ jQuery('.notification-count').remove();
144
+ if (data.unreadNotificationCount!=null && data.unreadNotificationCount>0) {
145
+ jQuery('.sumo-notifications .item-tile-title').append('<div class="notification-count">'+data.unreadNotificationCount+'</div>');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
146
  }
147
+
148
  }
149
 
150
  jQuery(window).load(function() {
js/preload.php CHANGED
@@ -6,6 +6,8 @@ function __smReady(sumome) {
6
  jQuery('.sumome-wp-dash-logged-in').addClass('status-logged-in');
7
  jQuery('.sumome-wp-dash-logged-out').removeClass('status-logged-out');
8
  jQuery('.sumome-wp-dash-logged-out').addClass('status-logged-in');
 
 
9
  });
10
 
11
  //auto populate form when clicking badge to login
@@ -64,6 +66,16 @@ function __smReady(sumome) {
64
  });
65
  }
66
 
 
 
 
 
 
 
 
 
 
 
67
  jQuery(document).on('click', '.sumo-notifications',function () {
68
  sumome.core.emit('startApp', 'ee27a0af-9947-40c9-8eab-0ab6a4f7a9c1');
69
  });
6
  jQuery('.sumome-wp-dash-logged-in').addClass('status-logged-in');
7
  jQuery('.sumome-wp-dash-logged-out').removeClass('status-logged-out');
8
  jQuery('.sumome-wp-dash-logged-out').addClass('status-logged-in');
9
+
10
+ getLoadInformation();
11
  });
12
 
13
  //auto populate form when clicking badge to login
66
  });
67
  }
68
 
69
+ function get_sumome_sandbox() {
70
+ window.sumome = sumome;
71
+ var sandbox = new sumome.core.Sandbox(sumome.core, 'wordpress', {}, 'wordpress');
72
+ return sandbox.properties;
73
+ }
74
+
75
+ jQuery(document).on('getSandbox',function () {
76
+ return get_sumome_sandbox();
77
+ });
78
+
79
  jQuery(document).on('click', '.sumo-notifications',function () {
80
  sumome.core.emit('startApp', 'ee27a0af-9947-40c9-8eab-0ab6a4f7a9c1');
81
  });
styles/styles.css CHANGED
@@ -244,6 +244,11 @@
244
  cursor:pointer;
245
  text-decoration:underline;
246
  }
 
 
 
 
 
247
  .sumome-plugin-main .sumome-help {
248
  width:50%;
249
  margin:0px auto;
@@ -775,6 +780,9 @@
775
  .sumome-plugin-center {
776
  text-align: center;
777
  }
 
 
 
778
 
779
  .sumome-plugin-left div {
780
  padding-left:80px;
244
  cursor:pointer;
245
  text-decoration:underline;
246
  }
247
+ .sumome-plugin-main .footer .appsumo-logo {
248
+ width:100%;
249
+ max-width:232px;
250
+ margin-top:75px;
251
+ }
252
  .sumome-plugin-main .sumome-help {
253
  width:50%;
254
  margin:0px auto;
780
  .sumome-plugin-center {
781
  text-align: center;
782
  }
783
+ .sumome-plugin-center.social-media a {
784
+ padding:7px;
785
+ }
786
 
787
  .sumome-plugin-left div {
788
  padding-left:80px;
sumome.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: SumoMe
4
  Plugin URI: http://sumome.com
5
  Description: Free Tools to grow your email list from SumoMe.com
6
- Version: 1.19
7
  Author: SumoMe
8
  Author URI: http://www.SumoMe.com
9
  */
3
  Plugin Name: SumoMe
4
  Plugin URI: http://sumome.com
5
  Description: Free Tools to grow your email list from SumoMe.com
6
+ Version: 1.20
7
  Author: SumoMe
8
  Author URI: http://www.SumoMe.com
9
  */
views/footer.php ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!--footer-->
2
+ <div class="row">
3
+ <div class="large-12 columns footer">
4
+ <div class="sumome-plugin-center social-media">
5
+ <h4 class="list-number-title">Show Us Love and Give Us a Follow</h4>
6
+ <div>
7
+ <a href="https://twitter.com/SumoMe" target="_blank"><img class="appsumo-twitter" src="<?php print plugins_url('images/twitter.png', dirname(__FILE__))?>"></a>
8
+ <a href="https://www.facebook.com/sumome/" target="_blank"><img class="appsumo-facebook" src="<?php print plugins_url('images/facebook.png', dirname(__FILE__))?>"></a>
9
+ <a href="https://www.instagram.com/sumome/" target="_blank"><img class="appsumo-instagram" src="<?php print plugins_url('images/instagram.png', dirname(__FILE__))?>"></a>
10
+ </div>
11
+ </div>
12
+
13
+ <div class="sumome-plugin-center">
14
+ <img class="appsumo-logo" src="<?php print plugins_url('images/appsumo-logo.png', dirname(__FILE__))?>">
15
+ </div>
16
+
17
+ <div class="sumome-plugin-center">Need to restore an existing account?
18
+ <div class="sumome-plugin-linkalike sumome-link-button sumome-tile-advanced-settings item-tile sumome-popup-no-dim" data-name="sumome-control-advanced-settings" data-title="">Click here</div>
19
+ </div>
20
+
21
+ </div>
22
+ </div>
views/main.php CHANGED
@@ -79,19 +79,12 @@ $itemArray['SumoMe Settings']['columns']=1;
79
  <h4 class="list-number-title">Need Help?</h4>
80
  <div class="sumome-help">
81
  <span>Take a look at our <a target="_blank" href="https://help.sumome.com/">help page</a> to see our frequently answered</span>
82
- <span>questions or <a target="_blank" href="https://help.sumome.com/customer/portal/emails/new">send us a message</a> and we will get back to you asap.</span>
83
  </div>
84
  </div>
85
  </div>
86
 
87
- <!-- Site ID -->
88
- <div class="row">
89
- <div class="large-12 columns footer footer">
90
- <div class="sumome-plugin-center">Need to restore an existing account?
91
- <div class="sumome-plugin-linkalike sumome-link-button sumome-tile-advanced-settings item-tile sumome-popup-no-dim" data-name="sumome-control-advanced-settings" data-title="">Click here</div>
92
- </div>
93
- </div>
94
- </div>
95
 
96
  </div>
97
  </div>
@@ -100,10 +93,5 @@ $itemArray['SumoMe Settings']['columns']=1;
100
  <?php
101
  include_once "popup.php";
102
  ?>
103
- <script>
104
- jQuery(document).ready(function() {
105
- getLoadInformation();
106
- })
107
 
108
- </script>
109
 
79
  <h4 class="list-number-title">Need Help?</h4>
80
  <div class="sumome-help">
81
  <span>Take a look at our <a target="_blank" href="https://help.sumome.com/">help page</a> to see our frequently answered</span>
82
+ <span>questions or <a target="_blank" href="https://help.sumome.com/hc/en-us/requests/new">send us a message</a> and we will get back to you asap.</span>
83
  </div>
84
  </div>
85
  </div>
86
 
87
+
 
 
 
 
 
 
 
88
 
89
  </div>
90
  </div>
93
  <?php
94
  include_once "popup.php";
95
  ?>
 
 
 
 
96
 
 
97
 
views/wordpress-dashboard-welcome-page.php CHANGED
@@ -161,7 +161,7 @@ if (!isset($noClose)) print '<div class="sumome-plugin-dashboard-widget-close-bu
161
  <?php
162
  if (substr_count($_SERVER['REQUEST_URI'], 'dashboard')>0) {
163
  ?>
164
- <a href="<?php print admin_url('admin.php?page=siteID')?>">Click here</a>
165
  <?php
166
  } else {
167
  ?>
161
  <?php
162
  if (substr_count($_SERVER['REQUEST_URI'], 'dashboard')>0) {
163
  ?>
164
+ <a href="<?php print admin_url('admin.php?page=sumome-siteID')?>">Click here</a>
165
  <?php
166
  } else {
167
  ?>