Version Description
Download this release
Release Info
Developer | joaoromao |
Plugin | Social Media Share Buttons |
Version | 2.9.1 |
Comparing to | |
See all releases |
Code changes from version 2.9 to 2.9.1
- img/apps/ga_integration.png +0 -0
- img/modals/copy_paste.png +0 -0
- img/modals/ga_integration.png +0 -0
- img/modals/mailchimp.png +0 -0
- init.php +93 -4
- js/plugin.js +56 -20
- readme.txt +7 -2
- tmpl/apps.php +65 -50
- tmpl/apps_config.php +12 -1
- wp-share-buttons-analytics-getsocial.php +1 -1
img/apps/ga_integration.png
ADDED
Binary file
|
img/modals/copy_paste.png
ADDED
Binary file
|
img/modals/ga_integration.png
ADDED
Binary file
|
img/modals/mailchimp.png
ADDED
Binary file
|
init.php
CHANGED
@@ -38,15 +38,18 @@
|
|
38 |
<form id="api-key-form" method="post" class="api-key gs-form gs-small hidden" action="options.php">
|
39 |
<?php settings_fields( 'getsocial-gs-settings' ); ?>
|
40 |
<?php do_settings_sections( 'getsocial-gs-settings' ); ?>
|
41 |
-
|
42 |
<div class="form-content">
|
43 |
<div class="field-clean">
|
44 |
<div class="field-input">
|
45 |
-
<p>Please go to your Getsocial Account and get your API KEY in the site options page.</p>
|
46 |
-
<input id="gs-api-key" type="text" name="gs-api-key" size="60" value="" />
|
|
|
|
|
|
|
47 |
</div>
|
48 |
</div>
|
49 |
</div>
|
|
|
50 |
<div class="form-button-group">
|
51 |
<input type="submit" class="gs-button gs-success" value="Save Changes" />
|
52 |
<span class="loading-create gs-button gs-success trans border gs-big hide">
|
@@ -78,7 +81,7 @@
|
|
78 |
|
79 |
</div>
|
80 |
</main>
|
81 |
-
|
82 |
<div id="settings-modal" class="modal-wrapper hide">
|
83 |
<div class="gs-modal">
|
84 |
<div class="modal-title">
|
@@ -156,6 +159,85 @@
|
|
156 |
</div>
|
157 |
<div class="modal-cover modal-close"></div>
|
158 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
159 |
</div>
|
160 |
|
161 |
<script>
|
@@ -178,6 +260,13 @@ UserVoice.push(['identify', {
|
|
178 |
// Add default trigger to the bottom-right corner of the window:
|
179 |
UserVoice.push(['addTrigger', '#help', { mode: 'contact' }]);
|
180 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
181 |
// Autoprompt for Satisfaction and SmartVote (only displayed under certain conditions)
|
182 |
// UserVoice.push(['autoprompt', {}]);
|
183 |
</script>
|
38 |
<form id="api-key-form" method="post" class="api-key gs-form gs-small hidden" action="options.php">
|
39 |
<?php settings_fields( 'getsocial-gs-settings' ); ?>
|
40 |
<?php do_settings_sections( 'getsocial-gs-settings' ); ?>
|
|
|
41 |
<div class="form-content">
|
42 |
<div class="field-clean">
|
43 |
<div class="field-input">
|
44 |
+
<p>Please go to your <a href="http://getsocial.io/customers/sign-in" target="_blank">Getsocial Account</a> and get your API KEY in the site options page.</p>
|
45 |
+
<input id="gs-api-key" type="text" name="gs-api-key" size="60" value="" maxlength="20"/>
|
46 |
+
<p>Need help?
|
47 |
+
<a href="#" id="contact_us">Contact us</a>
|
48 |
+
</p>
|
49 |
</div>
|
50 |
</div>
|
51 |
</div>
|
52 |
+
<span id="check-key-href" style="display: none;"><?php echo $GS->gs_account() ?>/api/v1/sites/verify_key?url=<?php echo get_option('siteurl'); ?></span>
|
53 |
<div class="form-button-group">
|
54 |
<input type="submit" class="gs-button gs-success" value="Save Changes" />
|
55 |
<span class="loading-create gs-button gs-success trans border gs-big hide">
|
81 |
|
82 |
</div>
|
83 |
</main>
|
84 |
+
<!-- Settings Modal -->
|
85 |
<div id="settings-modal" class="modal-wrapper hide">
|
86 |
<div class="gs-modal">
|
87 |
<div class="modal-title">
|
159 |
</div>
|
160 |
<div class="modal-cover modal-close"></div>
|
161 |
</div>
|
162 |
+
<!-- Install Google Analytics Modal -->
|
163 |
+
<div id="install-ga-analytics-modal" class="modal-wrapper hide">
|
164 |
+
<div class="gs-modal small text-center">
|
165 |
+
<div class="text-block">
|
166 |
+
<div class="modal-title">
|
167 |
+
<p class="title-obj">Google Analytics Integration</p>
|
168 |
+
</div>
|
169 |
+
<p class="text-center">
|
170 |
+
Track all social interactions made on your website without any code. Social sharing analytics, directly on Google Analytics.
|
171 |
+
</p>
|
172 |
+
<div class="clearfix text-center" style="margin-top: 30px">
|
173 |
+
<div class="col-16">
|
174 |
+
<p style="margin-bottom: 0"><strong>Our Blog's example</strong></p>
|
175 |
+
<img src="<?php echo plugins_url( '/img/modals/ga_integration.png', __FILE__ ) ?>" alt="">
|
176 |
+
</div>
|
177 |
+
</div>
|
178 |
+
</div>
|
179 |
+
<div class="form-button-group">
|
180 |
+
<a href="<?php echo $GS->gs_account() ?>/sites/gs-wordpress/billing/select_tier?api_key=<?php echo $GS->api_key ?>&source=wordpress<?php echo $GS->utms('pro_header') ?>" target="_blank" class="gs-button gs-success plan-two">
|
181 |
+
Upgrade to Starter
|
182 |
+
</a>
|
183 |
+
<a href="javascript:void(0)" class="gs-button gs-error trans modal-close">Cancel</a>
|
184 |
+
</div>
|
185 |
+
|
186 |
+
</div>
|
187 |
+
<div class="modal-cover modal-close"></div>
|
188 |
+
</div>
|
189 |
+
<!-- Install Copy and Share Modal -->
|
190 |
+
<div id="install-copy-and-share-modal" class="modal-wrapper hide">
|
191 |
+
<div class="gs-modal small text-center">
|
192 |
+
<div class="text-block">
|
193 |
+
<div class="modal-title">
|
194 |
+
<p class="title-obj">Copy Paste Share Tracking</p>
|
195 |
+
</div>
|
196 |
+
<p class="text-center">
|
197 |
+
Half of shares made on our blog are made via dark social channels, such as copy & paste, SMS and chat applications. What about yours?
|
198 |
+
</p>
|
199 |
+
<div class="clearfix text-center" style="margin-top: 30px">
|
200 |
+
<div class="col-16">
|
201 |
+
<p style="margin-bottom: 0"><strong>Out Blog's example</strong></p>
|
202 |
+
<img src="<?php echo plugins_url( '/img/modals/ga_integration.png', __FILE__ ) ?>" alt="">
|
203 |
+
</div>
|
204 |
+
</div>
|
205 |
+
</div>
|
206 |
+
<div class="form-button-group">
|
207 |
+
<a href="<?php echo $GS->gs_account() ?>/sites/gs-wordpress/billing/select_tier?api_key=<?php echo $GS->api_key ?>&source=wordpress<?php echo $GS->utms('pro_header') ?>" target="_blank" class="gs-button gs-success plan-two">
|
208 |
+
Upgrade to Starter
|
209 |
+
</a>
|
210 |
+
<a href="javascript:void(0)" class="gs-button gs-error trans modal-close">Cancel</a>
|
211 |
+
</div>
|
212 |
+
</div>
|
213 |
+
<div class="modal-cover modal-close"></div>
|
214 |
+
</div>
|
215 |
+
<!-- Install Mailchimp Modal -->
|
216 |
+
<div id="install-mailchimp-modal" class="modal-wrapper hide">
|
217 |
+
<div class="gs-modal small text-center">
|
218 |
+
<div class="text-block">
|
219 |
+
<div class="modal-title">
|
220 |
+
<p class="title">MailChimp Integration</p>
|
221 |
+
</div>
|
222 |
+
<p class="text-center">
|
223 |
+
Real-time integration with MailChimp. Connect our Subscriber Bar & Price Alert features to the world’s #1 e-mail marketing tool.
|
224 |
+
</p>
|
225 |
+
<div class="clearfix text-center" style="margin-top: 30px">
|
226 |
+
<div class="col-16">
|
227 |
+
<img src="<?php echo plugins_url( '/img/modals/mailchimp.png', __FILE__ ) ?>" alt="">
|
228 |
+
</div>
|
229 |
+
</div>
|
230 |
+
</div>
|
231 |
+
<div class="form-button-group">
|
232 |
+
<a href="<?php echo $GS->gs_account() ?>/sites/gs-wordpress/billing/select_tier?api_key=<?php echo $GS->api_key ?>&source=wordpress<?php echo $GS->utms('pro_header') ?>" target="_blank" class="gs-button gs-success plan-two">
|
233 |
+
Upgrade to Starter
|
234 |
+
</a>
|
235 |
+
<a href="javascript:void(0)" class="gs-button gs-error trans modal-close">Cancel</a>
|
236 |
+
</div>
|
237 |
+
|
238 |
+
</div>
|
239 |
+
<div class="modal-cover modal-close"></div>
|
240 |
+
</div>
|
241 |
</div>
|
242 |
|
243 |
<script>
|
260 |
// Add default trigger to the bottom-right corner of the window:
|
261 |
UserVoice.push(['addTrigger', '#help', { mode: 'contact' }]);
|
262 |
|
263 |
+
if (document.getElementById('contact_us')) {
|
264 |
+
UserVoice.push(['addTrigger', '#contact_us', { mode: 'contact' }]);
|
265 |
+
}
|
266 |
+
|
267 |
+
|
268 |
+
//UserVoice.push(['addTrigger', '#help2', { mode: 'contact' }]);
|
269 |
+
|
270 |
// Autoprompt for Satisfaction and SmartVote (only displayed under certain conditions)
|
271 |
// UserVoice.push(['autoprompt', {}]);
|
272 |
</script>
|
js/plugin.js
CHANGED
@@ -12,6 +12,7 @@ function forceUpdate(event){
|
|
12 |
}
|
13 |
|
14 |
function forceUpdateWithValues(){
|
|
|
15 |
jQuery.get(jQuery('main').attr('data-href'), {}, function(response){
|
16 |
var data = {
|
17 |
'action': 'gs_update_with_values',
|
@@ -20,7 +21,7 @@ function forceUpdateWithValues(){
|
|
20 |
|
21 |
// since 2.8 ajaxurl is always defined in the admin header and points to admin-ajax.php
|
22 |
jQuery.post(ajaxurl, data , function(response) {
|
23 |
-
console.log('getsocial.io updated');
|
24 |
});
|
25 |
});
|
26 |
}
|
@@ -38,9 +39,6 @@ jQuery('.getsocial-tab').on('click', function(e){
|
|
38 |
if(!$this.hasClass('only-activate')){
|
39 |
getsocial_window = window.open($this.attr('href'));
|
40 |
}
|
41 |
-
|
42 |
-
// setInterval('checkForUpdate()', 10000);
|
43 |
-
setInterval('forceUpdateWithValues()', 5000);
|
44 |
})
|
45 |
|
46 |
function handleMessage(event){
|
@@ -56,24 +54,50 @@ function handleMessage(event){
|
|
56 |
}
|
57 |
|
58 |
jQuery(function($){
|
|
|
|
|
|
|
|
|
|
|
59 |
jQuery('#api-key-form').submit(function(){
|
60 |
-
var
|
61 |
jQuery('.notification-bar').hide();
|
62 |
|
63 |
-
if(jQuery(this).find('#gs-api-key').val() != 0){
|
64 |
-
jQuery(this).find('input').prop('disabled', true);
|
65 |
-
jQuery(this).find('.loading-create').addClass('active');
|
66 |
-
jQuery(this).find('input[type="submit"]').hide();
|
67 |
-
|
68 |
-
jQuery.post( 'options.php', data).success( function(response){
|
69 |
-
jQuery('.loading-create').removeClass('active');
|
70 |
-
jQuery('.notification-bar.starting').show();
|
71 |
|
72 |
-
|
73 |
-
});
|
74 |
-
} else {
|
75 |
jQuery('.notification-bar').hide();
|
76 |
-
jQuery('.notification-bar.gs-error').show().find('p').html('API KEY
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
77 |
}
|
78 |
|
79 |
return false;
|
@@ -357,8 +381,9 @@ jQuery(function($){
|
|
357 |
|
358 |
var detectIE = document.addEventListener && !window.requestAnimationFrame;
|
359 |
|
360 |
-
function modal(trigger){
|
361 |
-
jQuery(trigger).on('click', function(){
|
|
|
362 |
var modal_link = jQuery(this).attr('id'),
|
363 |
modal_id = jQuery('#' + modal_link + '-modal');
|
364 |
|
@@ -375,6 +400,12 @@ jQuery(function($){
|
|
375 |
}
|
376 |
modal('#settings');
|
377 |
|
|
|
|
|
|
|
|
|
|
|
|
|
378 |
jQuery('.modal-close').on('click', function(){
|
379 |
jQuery('.modal-wrapper.active').stop().removeClass('active').addClass('rewind').delay(detectIE ? 0 : 700).queue(function(){
|
380 |
jQuery(this).removeClass('rewind').addClass('hide');
|
@@ -388,5 +419,10 @@ jQuery(function($){
|
|
388 |
});
|
389 |
});
|
390 |
|
391 |
-
forceUpdateWithValues();
|
|
|
|
|
|
|
|
|
|
|
392 |
});
|
12 |
}
|
13 |
|
14 |
function forceUpdateWithValues(){
|
15 |
+
|
16 |
jQuery.get(jQuery('main').attr('data-href'), {}, function(response){
|
17 |
var data = {
|
18 |
'action': 'gs_update_with_values',
|
21 |
|
22 |
// since 2.8 ajaxurl is always defined in the admin header and points to admin-ajax.php
|
23 |
jQuery.post(ajaxurl, data , function(response) {
|
24 |
+
console.log('getsocial.io updated w/values');
|
25 |
});
|
26 |
});
|
27 |
}
|
39 |
if(!$this.hasClass('only-activate')){
|
40 |
getsocial_window = window.open($this.attr('href'));
|
41 |
}
|
|
|
|
|
|
|
42 |
})
|
43 |
|
44 |
function handleMessage(event){
|
54 |
}
|
55 |
|
56 |
jQuery(function($){
|
57 |
+
|
58 |
+
jQuery('#contact_us').on('click', function(e){
|
59 |
+
e.stopPropagation();
|
60 |
+
});
|
61 |
+
|
62 |
jQuery('#api-key-form').submit(function(){
|
63 |
+
var wp_data = jQuery(this).serialize();
|
64 |
jQuery('.notification-bar').hide();
|
65 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
|
67 |
+
if (validateEmail(jQuery(this).find('#gs-api-key').val())) {
|
|
|
|
|
68 |
jQuery('.notification-bar').hide();
|
69 |
+
jQuery('.notification-bar.gs-error').show().find('p').html('API KEY is not an e-mail.');
|
70 |
+
} else {
|
71 |
+
if(jQuery(this).find('#gs-api-key').val() == 0) {
|
72 |
+
jQuery('.notification-bar').hide();
|
73 |
+
jQuery('.notification-bar.gs-error').show().find('p').html('API KEY cannot be blank.');
|
74 |
+
} else {
|
75 |
+
if(jQuery(this).find('#gs-api-key').val().length != 20) {
|
76 |
+
jQuery('.notification-bar').hide();
|
77 |
+
jQuery('.notification-bar.gs-error').show().find('p').html('API KEY must have 20 digits.');
|
78 |
+
} else {
|
79 |
+
jQuery(this).find('input').prop('disabled', true);
|
80 |
+
jQuery(this).find('.loading-create').addClass('active');
|
81 |
+
jQuery(this).find('input[type="submit"]').hide();
|
82 |
+
|
83 |
+
jQuery.post(document.getElementById('check-key-href').innerHTML, { api_key: jQuery(this).find('#gs-api-key').val() }, function(data){
|
84 |
+
if (data.success) {
|
85 |
+
jQuery.post( 'options.php', wp_data).success( function(response){
|
86 |
+
jQuery('.loading-create').removeClass('active');
|
87 |
+
jQuery('.notification-bar.starting').show();
|
88 |
+
|
89 |
+
setTimeout('window.location.reload();', 3000);
|
90 |
+
});
|
91 |
+
} else {
|
92 |
+
jQuery('.loading-create').removeClass('active');
|
93 |
+
jQuery('#api-key-form').find('input[type="submit"]').show();
|
94 |
+
jQuery('#api-key-form').find('input').prop('disabled', false);
|
95 |
+
jQuery('.notification-bar').hide();
|
96 |
+
jQuery('.notification-bar.gs-error').show().find('p').html('API KEY is invalid.');
|
97 |
+
}
|
98 |
+
});
|
99 |
+
}
|
100 |
+
}
|
101 |
}
|
102 |
|
103 |
return false;
|
381 |
|
382 |
var detectIE = document.addEventListener && !window.requestAnimationFrame;
|
383 |
|
384 |
+
function modal(trigger) {
|
385 |
+
jQuery(trigger).on('click', function(event){
|
386 |
+
event.stopPropagation()
|
387 |
var modal_link = jQuery(this).attr('id'),
|
388 |
modal_id = jQuery('#' + modal_link + '-modal');
|
389 |
|
400 |
}
|
401 |
modal('#settings');
|
402 |
|
403 |
+
modal('#install-ga-analytics');
|
404 |
+
|
405 |
+
modal('#install-copy-and-share');
|
406 |
+
|
407 |
+
modal('#install-mailchimp');
|
408 |
+
|
409 |
jQuery('.modal-close').on('click', function(){
|
410 |
jQuery('.modal-wrapper.active').stop().removeClass('active').addClass('rewind').delay(detectIE ? 0 : 700).queue(function(){
|
411 |
jQuery(this).removeClass('rewind').addClass('hide');
|
419 |
});
|
420 |
});
|
421 |
|
422 |
+
setInterval('forceUpdateWithValues()', 5000);
|
423 |
+
|
424 |
+
function validateEmail(email) {
|
425 |
+
var re = /^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i;
|
426 |
+
return re.test(email);
|
427 |
+
}
|
428 |
});
|
readme.txt
CHANGED
@@ -5,7 +5,7 @@ Tags: addthis, addtoany, analytics, button, facebook share, facebook button, lik
|
|
5 |
|
6 |
Requires at least: 3.0
|
7 |
Tested up to: 4.3
|
8 |
-
Stable tag: 2.9
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
@@ -279,7 +279,7 @@ Absolutely not! There are no contracts. Pay monthly, cancel anytime. There are n
|
|
279 |
GetSocial services or applications subscriptions, advertising or any other kind of service are non-refundable and GetSocial is not obligated to provide the User a refund at any time. We may, at our discretion, provide credits toward future services or applications subscription, advertising, or any other kind of service charges on a case-by-case basis.
|
280 |
|
281 |
**Is there someone I can talk about GetSocial?**
|
282 |
-
|
283 |
Sure, we’re always here to help. You can contact us at support@getsocial.io or use the help widget on the bottom-right corner of the plugin page.
|
284 |
|
285 |
== Screenshots ==
|
@@ -296,6 +296,11 @@ Sure, we’re always here to help. You can contact us at support@getsocial.io or
|
|
296 |
|
297 |
== Changelog ==
|
298 |
|
|
|
|
|
|
|
|
|
|
|
299 |
**2.9**
|
300 |
|
301 |
- Added MailChimp Integration
|
5 |
|
6 |
Requires at least: 3.0
|
7 |
Tested up to: 4.3
|
8 |
+
Stable tag: 2.9.1
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
279 |
GetSocial services or applications subscriptions, advertising or any other kind of service are non-refundable and GetSocial is not obligated to provide the User a refund at any time. We may, at our discretion, provide credits toward future services or applications subscription, advertising, or any other kind of service charges on a case-by-case basis.
|
280 |
|
281 |
**Is there someone I can talk about GetSocial?**
|
282 |
+
|
283 |
Sure, we’re always here to help. You can contact us at support@getsocial.io or use the help widget on the bottom-right corner of the plugin page.
|
284 |
|
285 |
== Screenshots ==
|
296 |
|
297 |
== Changelog ==
|
298 |
|
299 |
+
**2.9.1**
|
300 |
+
|
301 |
+
- Added Google Analitycs App
|
302 |
+
- API Key validation on library reinslations
|
303 |
+
|
304 |
**2.9**
|
305 |
|
306 |
- Added MailChimp Integration
|
tmpl/apps.php
CHANGED
@@ -11,85 +11,100 @@
|
|
11 |
<a class="app-group-toggle" href="javascript:void(0)">
|
12 |
<i class="fa fa-minus-square"></i><span>Open</span>
|
13 |
</a>
|
14 |
-
</div>
|
15 |
<div class="app-group-body gs-clearfix">
|
16 |
<?php foreach($apps as $app => $settings): ?>
|
17 |
-
<?php if($settings['
|
18 |
-
<?php
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
<div class="app-badge nocode">No Code</div>
|
28 |
<?php endif; ?>
|
|
|
|
|
|
|
|
|
|
|
|
|
29 |
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
<div class="app-image">
|
42 |
-
<?php if($settings['active']): ?>
|
43 |
-
<div class="installed">
|
44 |
-
<span>
|
45 |
-
<i class="fa fa-check-circle"></i>
|
46 |
-
Installed
|
47 |
-
</span>
|
48 |
-
</div>
|
49 |
-
<?php endif; ?>
|
50 |
-
<img src="<?php echo plugins_url( '../img/apps/'.$settings['file'].'.png', __FILE__ ) ?>" alt="">
|
51 |
-
</div>
|
52 |
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
|
|
|
|
|
|
60 |
|
|
|
|
|
|
|
|
|
|
|
61 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
62 |
<?php
|
|
|
63 |
$prevent_install = "";
|
64 |
|
65 |
if($app == 'MailChimp' && !$apps['Price Alert']['active'] && !$apps['Subscriber Bar']['active']):
|
66 |
$prevent_install = 'prevent="true"';
|
67 |
endif; ?>
|
68 |
-
|
69 |
<a href="<?php echo $settings['href'] ?>" target="<?php echo ($settings['only_activate'] && $app != 'MailChimp' ? '' : '_blank') ?>" class="gs-button gs-primary trans border getsocial-tab <?php echo ($settings['only_activate'] ? 'only-activate' : ''); ?>" <?php echo $prevent_install; ?>>
|
70 |
|
71 |
<?php echo ($settings['active']) ? 'Edit App' : 'Install App' ?>
|
72 |
|
|
|
73 |
<?php if($app == 'Price Alert' && !$settings['active']): ?>
|
74 |
<span class="gs-tooltip">
|
75 |
<img src="<?php echo plugins_url('../img/woocommerce.png', __FILE__ ) ?>" alt="WooCommerce">
|
76 |
<div>Requires WooCommerce Plugin</div>
|
77 |
</span>
|
78 |
-
<?php endif; ?>
|
79 |
-
|
80 |
</a>
|
81 |
<?php endif; ?>
|
|
|
82 |
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
</div>
|
89 |
</div>
|
90 |
</div>
|
91 |
</div>
|
92 |
-
|
93 |
<?php endif; ?>
|
94 |
<?php endforeach; ?>
|
95 |
</div>
|
11 |
<a class="app-group-toggle" href="javascript:void(0)">
|
12 |
<i class="fa fa-minus-square"></i><span>Open</span>
|
13 |
</a>
|
14 |
+
</div>
|
15 |
<div class="app-group-body gs-clearfix">
|
16 |
<?php foreach($apps as $app => $settings): ?>
|
17 |
+
<?php if($settings['category'] == $cat): ?>
|
18 |
+
<div class="app-link-wrapper <?php if($settings['nocode']){ echo 'filter-nocode'; } ?> filter-<?php echo plan_class($settings['plan']); ?> filter-<?php echo $settings['category']; ?>">
|
19 |
+
<div class="app-link">
|
20 |
+
<?php if($settings['nocode']): ?>
|
21 |
+
<div class="app-badge nocode">No Code</div>
|
22 |
+
<?php endif; ?>
|
23 |
|
24 |
+
<div class="app-badge-group">
|
25 |
+
<?php if($settings['new']): ?>
|
26 |
+
<div class="app-badge new">New</div>
|
|
|
27 |
<?php endif; ?>
|
28 |
+
<?php if($plan_current == 'one' && $settings['plan'] > 1): ?>
|
29 |
+
<div class="app-badge plan-<?php echo plan_class($settings['plan']); ?>">
|
30 |
+
<?php echo plan_name($settings['plan']); ?>
|
31 |
+
</div>
|
32 |
+
<?php endif; ?>
|
33 |
+
</div>
|
34 |
|
35 |
+
<div class="app-image">
|
36 |
+
<?php if($settings['active']): ?>
|
37 |
+
<div class="installed">
|
38 |
+
<span>
|
39 |
+
<i class="fa fa-check-circle"></i>
|
40 |
+
Installed
|
41 |
+
</span>
|
42 |
+
</div>
|
43 |
+
<?php endif; ?>
|
44 |
+
<img src="<?php echo plugins_url( '../img/apps/'.$settings['file'].'.png', __FILE__ ) ?>" alt="">
|
45 |
+
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
46 |
|
47 |
+
<div class="app-link-info">
|
48 |
+
<p class="app-title"><span><?php echo $app ?></span></p>
|
49 |
+
<p><?php echo $settings['desc'] ?></p>
|
50 |
+
</div>
|
51 |
+
<div class="app-link-buttons">
|
52 |
+
<div>
|
53 |
+
<?php if(!$settings['only_activate'] || ( isset($settings['only_activate']) && !$settings['active'] )): ?>
|
54 |
+
|
55 |
+
<?php // Show modals when user is free and apps are activate only ?>
|
56 |
+
<?php if (!$GS->is_pro() && $settings['only_activate']): ?>
|
57 |
|
58 |
+
<?php if($app == 'Copy Paste Share Tracking'): ?>
|
59 |
+
<a id="install-copy-and-share" href="#" class="gs-button gs-primary trans border getsocial-tab only-activate">
|
60 |
+
Install App
|
61 |
+
</a>
|
62 |
+
<?php endif; ?>
|
63 |
|
64 |
+
<?php if($app == 'Google Analytics'): ?>
|
65 |
+
<a id="install-ga-analytics" href="#" class="gs-button gs-primary trans border getsocial-tab only-activate">
|
66 |
+
Install App
|
67 |
+
</a>
|
68 |
+
<?php endif; ?>
|
69 |
+
|
70 |
+
<?php if($app == 'MailChimp'): ?>
|
71 |
+
<a id="install-mailchimp" href="#" class="gs-button gs-primary trans border getsocial-tab only-activate">
|
72 |
+
Install App
|
73 |
+
</a>
|
74 |
+
<?php endif; ?>
|
75 |
+
<?php // Non Free users can install everything ?>
|
76 |
+
<?php else: ?>
|
77 |
<?php
|
78 |
+
// Prevent instalation of mailchimp app without Price Alert or Subscriber Bar
|
79 |
$prevent_install = "";
|
80 |
|
81 |
if($app == 'MailChimp' && !$apps['Price Alert']['active'] && !$apps['Subscriber Bar']['active']):
|
82 |
$prevent_install = 'prevent="true"';
|
83 |
endif; ?>
|
|
|
84 |
<a href="<?php echo $settings['href'] ?>" target="<?php echo ($settings['only_activate'] && $app != 'MailChimp' ? '' : '_blank') ?>" class="gs-button gs-primary trans border getsocial-tab <?php echo ($settings['only_activate'] ? 'only-activate' : ''); ?>" <?php echo $prevent_install; ?>>
|
85 |
|
86 |
<?php echo ($settings['active']) ? 'Edit App' : 'Install App' ?>
|
87 |
|
88 |
+
<?php // show woocommerce toogle in price alert ?>
|
89 |
<?php if($app == 'Price Alert' && !$settings['active']): ?>
|
90 |
<span class="gs-tooltip">
|
91 |
<img src="<?php echo plugins_url('../img/woocommerce.png', __FILE__ ) ?>" alt="WooCommerce">
|
92 |
<div>Requires WooCommerce Plugin</div>
|
93 |
</span>
|
94 |
+
<?php endif; ?>
|
|
|
95 |
</a>
|
96 |
<?php endif; ?>
|
97 |
+
<?php endif; ?>
|
98 |
|
99 |
+
<?php if($settings['active']): ?>
|
100 |
+
<a href="javascript:void(0)" class="gs-button disable trans border stop deactivate" data-disable-app="<?php echo $GS->api_url('sites/disable/'.get_option('gs-api-key').'/'.$settings['file']) ?>">
|
101 |
+
Deactivate
|
102 |
+
</a>
|
103 |
+
<?php endif; ?>
|
|
|
104 |
</div>
|
105 |
</div>
|
106 |
</div>
|
107 |
+
</div>
|
108 |
<?php endif; ?>
|
109 |
<?php endforeach; ?>
|
110 |
</div>
|
tmpl/apps_config.php
CHANGED
@@ -179,12 +179,23 @@
|
|
179 |
'href' => $GS->gs_account().'/sites/gs-wordpress/price_alerts/new?api_key='.$GS->api_key.'&source=wordpress'.$GS->utms('price-alert'),
|
180 |
'desc' => "Allow your visitors to get notified when a price drop occurs on a product they want to purchase. Increase sales and fight cart abandonment."
|
181 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
182 |
'MailChimp' => array(
|
183 |
'file' => 'mailchimp',
|
184 |
'category' => 'ecommerce_integrations',
|
185 |
'nocode' => true,
|
186 |
'new' => true,
|
187 |
-
'plan' =>
|
188 |
'active' => $GS->is_active('mailchimp'),
|
189 |
'only_activate' => true,
|
190 |
'href' => $GS->gs_account() . 'auth/mailchimp',
|
179 |
'href' => $GS->gs_account().'/sites/gs-wordpress/price_alerts/new?api_key='.$GS->api_key.'&source=wordpress'.$GS->utms('price-alert'),
|
180 |
'desc' => "Allow your visitors to get notified when a price drop occurs on a product they want to purchase. Increase sales and fight cart abandonment."
|
181 |
),
|
182 |
+
'Google Analytics' => array(
|
183 |
+
'file' => 'ga_integration',
|
184 |
+
'category' => 'ecommerce_integrations',
|
185 |
+
'nocode' => true,
|
186 |
+
'new' => false,
|
187 |
+
'plan' => 2,
|
188 |
+
'active' => $GS->is_active('ga_integration'),
|
189 |
+
'only_activate' => true,
|
190 |
+
'href' => $GS->api_url('sites/activate/'.get_option('gs-api-key').'/ga_integration'),
|
191 |
+
'desc' => "Integrate your GetSocial sharing activity with Google Analytics and have all of your analytics in one place. No code required"
|
192 |
+
),
|
193 |
'MailChimp' => array(
|
194 |
'file' => 'mailchimp',
|
195 |
'category' => 'ecommerce_integrations',
|
196 |
'nocode' => true,
|
197 |
'new' => true,
|
198 |
+
'plan' => 2,
|
199 |
'active' => $GS->is_active('mailchimp'),
|
200 |
'only_activate' => true,
|
201 |
'href' => $GS->gs_account() . 'auth/mailchimp',
|
wp-share-buttons-analytics-getsocial.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Share Buttons & tools to grow traffic by GetSocial.io
|
4 |
* Plugin URI: http://getsocial.io
|
5 |
* Description: Share Buttons by GetSocial.io is a freemium WordPress plugin that enables you to track social shares on Wordpress. Provide beautiful wordpress sharing buttons, track how many shares were made in each post and see how much traffic, conversions and shares each post generated. Optimize your SEO and increase social shares with GetSocial.io.
|
6 |
-
* Version: 2.9
|
7 |
* Author: Getsocial, S.A.
|
8 |
* Author URI: http://getsocial.io
|
9 |
* License: GPL2
|
3 |
* Plugin Name: Share Buttons & tools to grow traffic by GetSocial.io
|
4 |
* Plugin URI: http://getsocial.io
|
5 |
* Description: Share Buttons by GetSocial.io is a freemium WordPress plugin that enables you to track social shares on Wordpress. Provide beautiful wordpress sharing buttons, track how many shares were made in each post and see how much traffic, conversions and shares each post generated. Optimize your SEO and increase social shares with GetSocial.io.
|
6 |
+
* Version: 2.9.1
|
7 |
* Author: Getsocial, S.A.
|
8 |
* Author URI: http://getsocial.io
|
9 |
* License: GPL2
|