Version Description
- Fixed some CSS issues
Download this release
Release Info
Developer | MyThemeShop |
Plugin | WP Subscribe |
Version | 1.2.3 |
Comparing to | |
See all releases |
Code changes from version 1.2.1 to 1.2.3
- assets/css/wp-subscribe-form.css +1 -1
- assets/css/wp-subscribe-options.css +0 -0
- assets/js/jquery.cookie.js +0 -0
- assets/js/jquery.exitIntent.js +0 -0
- assets/js/magnificpopup.js +0 -0
- assets/js/wp-subscribe-admin.js +5 -3
- assets/js/wp-subscribe-form.js +2 -2
- assets/js/wp-subscribe-options.js +0 -0
- includes/class-wps-base.php +0 -0
- includes/subscription/class-wps-aweber.php +51 -25
- includes/subscription/class-wps-base.php +1 -1
- includes/subscription/class-wps-feedburner.php +0 -0
- includes/subscription/class-wps-mailchimp.php +4 -1
- includes/subscription/libs/aweber_api/aweber.php +0 -0
- includes/subscription/libs/aweber_api/aweber_api.php +0 -0
- includes/subscription/libs/aweber_api/aweber_collection.php +0 -0
- includes/subscription/libs/aweber_api/aweber_entry.php +0 -0
- includes/subscription/libs/aweber_api/aweber_entry_data_array.php +0 -0
- includes/subscription/libs/aweber_api/aweber_response.php +0 -0
- includes/subscription/libs/aweber_api/curl_object.php +0 -0
- includes/subscription/libs/aweber_api/curl_response.php +0 -0
- includes/subscription/libs/aweber_api/exceptions.php +0 -0
- includes/subscription/libs/aweber_api/oauth_adapter.php +0 -0
- includes/subscription/libs/aweber_api/oauth_application.php +0 -0
- includes/subscription/libs/mailchimp.php +0 -0
- includes/wps-functions-options.php +0 -0
- includes/wps-helpers.php +1 -31
- includes/wps-widget.php +6 -1
- languages/wp-subscribe.mo +0 -0
- languages/wp-subscribe.po +0 -0
- package.json +0 -19
- readme.txt +12 -2
- wp-subscribe.php +3 -3
assets/css/wp-subscribe-form.css
CHANGED
@@ -2,4 +2,4 @@
|
|
2 |
* Plugin: WP Subscribe Pro
|
3 |
* Name: wp-subscribe-form.css
|
4 |
* Written by: MyThemeShop
|
5 |
-
*/.wp-subscribe-wrap{padding:20px;text-align:center;background:#f47555}.wp-subscribe-wrap h4.title{font-size:22px;line-height:1;margin-bottom:0;text-transform:uppercase;color:#fff}.wp-subscribe-wrap h4.title span{font-size:38px;font-weight:bold;display:inline-block;margin-top:15px}#wp_subscribe_popup .wp-subscribe-wrap h4.title{margin-top:0}.wp-subscribe-wrap p{margin:0;color:#fff}.wp-subscribe-wrap p.text{margin:15px 0;opacity:.8}.wp-subscribe-wrap p.footer-text{font-size:12px;margin-top:10px}.wp-subscribe-wrap input{box-sizing:border-box;width:100%;height:45px;margin:0;padding:10px 0;text-align:center;text-indent:10px;border:none;border-radius:0;box-shadow:none}.wp-subscribe-wrap input::-webkit-input-placeholder{opacity:.8;color:inherit}.wp-subscribe-wrap input:-moz-placeholder{opacity:.8;color:inherit}.wp-subscribe-wrap input::-moz-placeholder{opacity:.8;color:inherit}.wp-subscribe-wrap input:-ms-input-placeholder{opacity:.8;color:inherit}.wp-subscribe-wrap input:focus::-webkit-input-placeholder{color:transparent !important}.wp-subscribe-wrap input:focus:-moz-placeholder{color:transparent !important}.wp-subscribe-wrap input:focus::-moz-placeholder{color:transparent !important}.wp-subscribe-wrap input:focus:-ms-input-placeholder{color:transparent !important}.wp-subscribe-wrap .email-field{margin-top:10px}.wp-subscribe-wrap input.email-field,.wp-subscribe-wrap input.name-field{color:#fff;background:#d56144}.wp-subscribe-wrap input.submit{font-size:18px;font-weight:500;margin-top:20px;cursor:pointer;text-transform:uppercase;color:#f47555;background:#fff;box-shadow:0 1px 2px 0 rgba(0,0,0,0.05)}.wp-subscribe-single .wp-subscribe-wrap{clear:both;margin:10px 0;text-align:left}.wp-subscribe-single .wp-subscribe-wrap input{text-align:left}.wp-subscribe-wrap .error,.wp-subscribe-wrap .thanks{margin-top:10px}.wp-subscribe-wrap .wp-subscribe-loader{display:none;padding:1em;text-align:center;vertical-align:top}.wp-subscribe-wrap.loading .wp-subscribe-form{display:none}.wp-subscribe-wrap.loading .wp-subscribe-loader{display:block}
|
2 |
* Plugin: WP Subscribe Pro
|
3 |
* Name: wp-subscribe-form.css
|
4 |
* Written by: MyThemeShop
|
5 |
+
*/.wp-subscribe-wrap{padding:20px;text-align:center;background:#f47555}.wp-subscribe-wrap h4.title{font-size:22px;line-height:1;margin-bottom:0;text-transform:uppercase;color:#fff}.wp-subscribe-wrap h4.title span{font-size:38px;font-weight:bold;display:inline-block;margin-top:15px}#wp_subscribe_popup .wp-subscribe-wrap h4.title{margin-top:0}.wp-subscribe-wrap p{margin:0;color:#fff}.wp-subscribe-wrap p.text{margin:15px 0;opacity:.8}.wp-subscribe-wrap p.footer-text{font-size:12px;margin-top:10px}.wp-subscribe-wrap input{box-sizing:border-box;width:100%;height:45px;margin:0;padding:10px 0;text-align:center;text-indent:10px;border:none;border-radius:0;box-shadow:none}.wp-subscribe-wrap input::-webkit-input-placeholder{opacity:.8;color:inherit}.wp-subscribe-wrap input:-moz-placeholder{opacity:.8;color:inherit}.wp-subscribe-wrap input::-moz-placeholder{opacity:.8;color:inherit}.wp-subscribe-wrap input:-ms-input-placeholder{opacity:.8;color:inherit}.wp-subscribe-wrap input:focus::-webkit-input-placeholder{color:transparent !important}.wp-subscribe-wrap input:focus:-moz-placeholder{color:transparent !important}.wp-subscribe-wrap input:focus::-moz-placeholder{color:transparent !important}.wp-subscribe-wrap input:focus:-ms-input-placeholder{color:transparent !important}.wp-subscribe-wrap .email-field{margin-top:10px}.wp-subscribe-wrap input.email-field,.wp-subscribe-wrap input.name-field{color:#fff;background:#d56144}.wp-subscribe-wrap input.submit{font-size:18px;font-weight:500;margin-top:20px;cursor:pointer;text-transform:uppercase;color:#f47555;background:#fff;box-shadow:0 1px 2px 0 rgba(0,0,0,0.05)}.wp-subscribe-single .wp-subscribe-wrap{clear:both;margin:10px 0;text-align:left}.wp-subscribe-single .wp-subscribe-wrap input{text-align:left}.wp-subscribe-wrap .error,.wp-subscribe-wrap .thanks{margin-top:10px}.wp-subscribe-wrap .wp-subscribe-loader{display:none;padding:1em;text-align:center;vertical-align:top}.wp-subscribe-wrap.loading .wp-subscribe-form,.thanks,.error{display:none}.wp-subscribe-wrap.loading .wp-subscribe-loader{display:block}
|
assets/css/wp-subscribe-options.css
CHANGED
File without changes
|
assets/js/jquery.cookie.js
CHANGED
File without changes
|
assets/js/jquery.exitIntent.js
CHANGED
File without changes
|
assets/js/magnificpopup.js
CHANGED
File without changes
|
assets/js/wp-subscribe-admin.js
CHANGED
@@ -68,7 +68,7 @@ Author URI: http://mythemeshop.com/
|
|
68 |
} );
|
69 |
|
70 |
// Get List Code
|
71 |
-
$(document).on( 'click', '.wps-get-list', function( event ) {
|
72 |
event.preventDefault();
|
73 |
|
74 |
var button = $(this),
|
@@ -79,10 +79,12 @@ Author URI: http://mythemeshop.com/
|
|
79 |
|
80 |
var args = {};
|
81 |
fields.each(function(){
|
82 |
-
var f = $(this)
|
83 |
-
key = f.data('id').replace(service+'_', '').replace(service, '');
|
84 |
|
|
|
|
|
85 |
args[key] = f.val();
|
|
|
86 |
});
|
87 |
|
88 |
$.ajax({
|
68 |
} );
|
69 |
|
70 |
// Get List Code
|
71 |
+
$( document ).on( 'click', '.wps-get-list', function( event ) {
|
72 |
event.preventDefault();
|
73 |
|
74 |
var button = $(this),
|
79 |
|
80 |
var args = {};
|
81 |
fields.each(function(){
|
82 |
+
var f = $(this);
|
|
|
83 |
|
84 |
+
if ( f.data( 'id' ) && f.data( 'id' ).length > 0 ) {
|
85 |
+
var key = f.data( 'id' ).replace(service+'_', '').replace(service, '');
|
86 |
args[key] = f.val();
|
87 |
+
}
|
88 |
});
|
89 |
|
90 |
$.ajax({
|
assets/js/wp-subscribe-form.js
CHANGED
@@ -47,7 +47,7 @@ jQuery(document).ready(function($) {
|
|
47 |
$widget.find('.thanks').show();
|
48 |
|
49 |
var thanks_page_url = $widget.data('thanks_page_url');
|
50 |
-
if ( $widget.data('thanks_page') ===
|
51 |
window.location.href = thanks_page_url;
|
52 |
}
|
53 |
}
|
@@ -87,7 +87,7 @@ jQuery(document).ready(function($) {
|
|
87 |
$widget.find('.thanks').show();
|
88 |
|
89 |
var thanks_page_url = $widget.data('thanks_page_url');
|
90 |
-
if ( $widget.data('thanks_page') ===
|
91 |
window.location.href = thanks_page_url;
|
92 |
}
|
93 |
}
|
47 |
$widget.find('.thanks').show();
|
48 |
|
49 |
var thanks_page_url = $widget.data('thanks_page_url');
|
50 |
+
if ( parseInt($widget.data('thanks_page'), 10) === 1 && thanks_page_url !== '') {
|
51 |
window.location.href = thanks_page_url;
|
52 |
}
|
53 |
}
|
87 |
$widget.find('.thanks').show();
|
88 |
|
89 |
var thanks_page_url = $widget.data('thanks_page_url');
|
90 |
+
if ( parseInt($widget.data('thanks_page'), 10) === 1 && thanks_page_url !== '') {
|
91 |
window.location.href = thanks_page_url;
|
92 |
}
|
93 |
}
|
assets/js/wp-subscribe-options.js
CHANGED
File without changes
|
includes/class-wps-base.php
CHANGED
File without changes
|
includes/subscription/class-wps-aweber.php
CHANGED
@@ -16,6 +16,12 @@ class WPS_Subscription_Aweber extends WPS_Subscription_Base {
|
|
16 |
*/
|
17 |
public $api_key;
|
18 |
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
public function init() {
|
20 |
|
21 |
if( !class_exists( 'AWeberAPI' ) ) {
|
@@ -45,6 +51,10 @@ class WPS_Subscription_Aweber extends WPS_Subscription_Base {
|
|
45 |
|
46 |
$credentials = array_filter( $credentials );
|
47 |
|
|
|
|
|
|
|
|
|
48 |
$this->credentials = empty( $credentials ) ? null : $credentials;
|
49 |
|
50 |
return $this->credentials;
|
@@ -70,13 +80,17 @@ class WPS_Subscription_Aweber extends WPS_Subscription_Base {
|
|
70 |
$aweber = new AWeberAPI( $consumer_key, $consumer_secret );
|
71 |
$account = $aweber->getAccount( $access_key, $access_secret );
|
72 |
|
73 |
-
|
74 |
'consumer_key' => $consumer_key,
|
75 |
'consumer_secret' => $consumer_secret,
|
76 |
'access_key' => $access_key,
|
77 |
'access_secret' => $access_secret,
|
78 |
'account_id' => $account->id
|
79 |
);
|
|
|
|
|
|
|
|
|
80 |
}
|
81 |
|
82 |
public function get_account() {
|
@@ -107,9 +121,10 @@ class WPS_Subscription_Aweber extends WPS_Subscription_Base {
|
|
107 |
public function subscribe( $identity, $options ) {
|
108 |
|
109 |
try {
|
|
|
110 |
$account = $this->get_account();
|
111 |
-
|
112 |
-
$list_url = "/accounts/{$account->id}/lists/{$options['
|
113 |
$list = $account->loadFromUrl($list_url);
|
114 |
|
115 |
$name = $this->get_fullname( $identity );
|
@@ -120,7 +135,7 @@ class WPS_Subscription_Aweber extends WPS_Subscription_Base {
|
|
120 |
'ad_tracking' => 'mythemeshop'
|
121 |
);
|
122 |
|
123 |
-
$list->create($params);
|
124 |
|
125 |
return array(
|
126 |
'status' => 'subscribed'
|
@@ -146,29 +161,15 @@ class WPS_Subscription_Aweber extends WPS_Subscription_Base {
|
|
146 |
|
147 |
public function get_fields() {
|
148 |
|
149 |
-
$
|
150 |
-
|
151 |
-
<div class="aweber_authorization_area mb30<?php echo ! empty( $instance['aweber_access_key'] ) ? ' hidden' : '' ?>">
|
152 |
-
<strong><?php esc_html_e( 'To connect your Aweber account:', 'content-locker' ) ?></strong>
|
153 |
-
<br />
|
154 |
-
<ul>
|
155 |
-
<li><?php printf( wp_kses_post( __( '<span>1.</span> <a href="%s" target="_blank">Click here</a> <span>to open the authorization page and log in.</span>', 'content-locker' ) ), 'https://auth.aweber.com/1.0/oauth/authorize_app/1afc783e' ) ?></li>
|
156 |
-
<li><?php echo wp_kses_post( __( '<span>2.</span> Copy and paste the authorization code in the field below.', 'content-locker' ) ) ?></li>
|
157 |
-
</ul>
|
158 |
|
159 |
-
|
160 |
-
|
161 |
-
|
162 |
-
|
163 |
-
|
164 |
-
|
165 |
-
<strong><?php _e( 'Your Aweber Account is connected.', 'content-locker' ) ?></strong>
|
166 |
-
<?php echo wp_kses_post( __( '<a href="#" class="aweber_disconnect">Click here</a> <span>to disconnect.</span>', 'content-locker' ) ) ?>
|
167 |
-
</p>
|
168 |
-
</div>
|
169 |
-
<?php
|
170 |
|
171 |
-
$fields = array(
|
172 |
'aweber_consumer_key' => array(
|
173 |
'id' => 'aweber_consumer_key',
|
174 |
'name' => 'aweber_consumer_key',
|
@@ -207,4 +208,29 @@ class WPS_Subscription_Aweber extends WPS_Subscription_Base {
|
|
207 |
|
208 |
return $fields;
|
209 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
210 |
}
|
16 |
*/
|
17 |
public $api_key;
|
18 |
|
19 |
+
/**
|
20 |
+
* Credential option key
|
21 |
+
* @return string
|
22 |
+
*/
|
23 |
+
private $key = 'mts_wps_awerber_credentials';
|
24 |
+
|
25 |
public function init() {
|
26 |
|
27 |
if( !class_exists( 'AWeberAPI' ) ) {
|
51 |
|
52 |
$credentials = array_filter( $credentials );
|
53 |
|
54 |
+
if ( empty( $credentials ) ) {
|
55 |
+
$credentials = get_option( $this->key );
|
56 |
+
}
|
57 |
+
|
58 |
$this->credentials = empty( $credentials ) ? null : $credentials;
|
59 |
|
60 |
return $this->credentials;
|
80 |
$aweber = new AWeberAPI( $consumer_key, $consumer_secret );
|
81 |
$account = $aweber->getAccount( $access_key, $access_secret );
|
82 |
|
83 |
+
$credentials = array(
|
84 |
'consumer_key' => $consumer_key,
|
85 |
'consumer_secret' => $consumer_secret,
|
86 |
'access_key' => $access_key,
|
87 |
'access_secret' => $access_secret,
|
88 |
'account_id' => $account->id
|
89 |
);
|
90 |
+
|
91 |
+
update_option( $this->key, $credentials );
|
92 |
+
|
93 |
+
return $credentials;
|
94 |
}
|
95 |
|
96 |
public function get_account() {
|
121 |
public function subscribe( $identity, $options ) {
|
122 |
|
123 |
try {
|
124 |
+
$this->credentials = $options;
|
125 |
$account = $this->get_account();
|
126 |
+
|
127 |
+
$list_url = "/accounts/{$account->id}/lists/{$options['list_id']}/subscribers";
|
128 |
$list = $account->loadFromUrl($list_url);
|
129 |
|
130 |
$name = $this->get_fullname( $identity );
|
135 |
'ad_tracking' => 'mythemeshop'
|
136 |
);
|
137 |
|
138 |
+
$list->create( $params );
|
139 |
|
140 |
return array(
|
141 |
'status' => 'subscribed'
|
161 |
|
162 |
public function get_fields() {
|
163 |
|
164 |
+
$fields = array(
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
165 |
|
166 |
+
'aweber_raw' => array(
|
167 |
+
'id' => 'aweber_raw',
|
168 |
+
'name' => 'aweber_raw',
|
169 |
+
'type' => 'raw',
|
170 |
+
'content' => array( $this, 'raw_content' )
|
171 |
+
),
|
|
|
|
|
|
|
|
|
|
|
172 |
|
|
|
173 |
'aweber_consumer_key' => array(
|
174 |
'id' => 'aweber_consumer_key',
|
175 |
'name' => 'aweber_consumer_key',
|
208 |
|
209 |
return $fields;
|
210 |
}
|
211 |
+
|
212 |
+
public function raw_content() {
|
213 |
+
$instance = $this->instance;
|
214 |
+
|
215 |
+
?>
|
216 |
+
<div class="aweber_authorization_area mb30<?php echo ! empty( $instance['aweber_access_key'] ) ? ' hidden' : '' ?>">
|
217 |
+
<strong><?php esc_html_e( 'To connect your Aweber account:', 'content-locker' ) ?></strong>
|
218 |
+
<br />
|
219 |
+
<ul>
|
220 |
+
<li><?php printf( wp_kses_post( __( '<span>1.</span> <a href="%s" target="_blank">Click here</a> <span>to open the authorization page and log in.</span>', 'content-locker' ) ), 'https://auth.aweber.com/1.0/oauth/authorize_app/1afc783e' ) ?></li>
|
221 |
+
<li><?php echo wp_kses_post( __( '<span>2.</span> Copy and paste the authorization code in the field below.', 'content-locker' ) ) ?></li>
|
222 |
+
</ul>
|
223 |
+
|
224 |
+
<textarea rows="4" cols="80"></textarea>
|
225 |
+
<br />
|
226 |
+
<button type="button" class="button-primary aweber_authorization">Authorize</button>
|
227 |
+
</div>
|
228 |
+
<div class="alert alert-hint mb30 <?php echo empty( $instance['aweber_access_key'] ) ? ' hidden' : '' ?>">
|
229 |
+
<p>
|
230 |
+
<strong><?php _e( 'Your Aweber Account is connected.', 'content-locker' ) ?></strong>
|
231 |
+
<?php echo wp_kses_post( __( '<a href="#" class="aweber_disconnect">Click here</a> <span>to disconnect.</span>', 'content-locker' ) ) ?>
|
232 |
+
</p>
|
233 |
+
</div>
|
234 |
+
<?php
|
235 |
+
}
|
236 |
}
|
includes/subscription/class-wps-base.php
CHANGED
@@ -103,11 +103,11 @@ abstract class WPS_Subscription_Base {
|
|
103 |
$instance = array_shift($args);
|
104 |
$widget = array_shift($args);
|
105 |
$fields = $this->get_fields( $instance );
|
|
|
106 |
|
107 |
foreach( $fields as $id => $field ) {
|
108 |
$func = is_null( $widget ) ? 'wps_field_' . $field['type'] : 'field_' . $field['type'];
|
109 |
$field['value'] = isset( $instance[$id] ) ? $instance[$id] : '';
|
110 |
-
//$field['service'] = $service;
|
111 |
|
112 |
if( is_null( $widget ) && function_exists( $func ) ) {
|
113 |
$arguments = array_merge( array( $field ), $args );
|
103 |
$instance = array_shift($args);
|
104 |
$widget = array_shift($args);
|
105 |
$fields = $this->get_fields( $instance );
|
106 |
+
$this->instance = $instance;
|
107 |
|
108 |
foreach( $fields as $id => $field ) {
|
109 |
$func = is_null( $widget ) ? 'wps_field_' . $field['type'] : 'field_' . $field['type'];
|
110 |
$field['value'] = isset( $instance[$id] ) ? $instance[$id] : '';
|
|
|
111 |
|
112 |
if( is_null( $widget ) && function_exists( $func ) ) {
|
113 |
$arguments = array_merge( array( $field ), $args );
|
includes/subscription/class-wps-feedburner.php
CHANGED
File without changes
|
includes/subscription/class-wps-mailchimp.php
CHANGED
@@ -31,7 +31,10 @@ class WPS_Subscription_MailChimp extends WPS_Subscription_Base {
|
|
31 |
public function subscribe( $identity, $options ) {
|
32 |
|
33 |
$vars = array();
|
34 |
-
if (
|
|
|
|
|
|
|
35 |
|
36 |
$mailchimp = $this->init( $options['api_key'] );
|
37 |
$subscriber_hash = $mailchimp->subscriberHash($identity['email']);
|
31 |
public function subscribe( $identity, $options ) {
|
32 |
|
33 |
$vars = array();
|
34 |
+
if ( !empty( $identity['name'] ) ) {
|
35 |
+
$vars['FNAME'] = $identity['name'];
|
36 |
+
$vars['MERGE1'] = $identity['name'];
|
37 |
+
}
|
38 |
|
39 |
$mailchimp = $this->init( $options['api_key'] );
|
40 |
$subscriber_hash = $mailchimp->subscriberHash($identity['email']);
|
includes/subscription/libs/aweber_api/aweber.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/aweber_api.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/aweber_collection.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/aweber_entry.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/aweber_entry_data_array.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/aweber_response.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/curl_object.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/curl_response.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/exceptions.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/oauth_adapter.php
CHANGED
File without changes
|
includes/subscription/libs/aweber_api/oauth_application.php
CHANGED
File without changes
|
includes/subscription/libs/mailchimp.php
CHANGED
File without changes
|
includes/wps-functions-options.php
CHANGED
File without changes
|
includes/wps-helpers.php
CHANGED
@@ -35,8 +35,6 @@ function wps_the_form( $options = null ) {
|
|
35 |
<div class="wp-subscribe-popup-form-wrapper">
|
36 |
<?php endif; ?>
|
37 |
|
38 |
-
<?php wps_the_form_css( $wp_subscribe_forms, $options ) ?>
|
39 |
-
|
40 |
<div id="wp-subscribe" class="wp-subscribe-wrap wp-subscribe wp-subscribe-<?php echo $wp_subscribe_forms ?>" data-thanks_page="<?php echo absint( $options['thanks_page'] ) ?>" data-thanks_page_url="<?php echo esc_url( $options['thanks_page_url'] ) ?>" data-thanks_page_new_window="0">
|
41 |
|
42 |
<h4 class="title"><?php echo wp_kses_post( $options['title'] )?></h4>
|
@@ -98,34 +96,6 @@ function wps_the_form( $options = null ) {
|
|
98 |
<?php
|
99 |
}
|
100 |
|
101 |
-
/**
|
102 |
-
* [wps_the_form_css description]
|
103 |
-
* @param [type] $id [description]
|
104 |
-
* @param [type] $options [description]
|
105 |
-
* @return [type] [description]
|
106 |
-
*/
|
107 |
-
function wps_the_form_css( $id, $options, $type = 'subscribe_form' ) {
|
108 |
-
|
109 |
-
$css = array();
|
110 |
-
$id = "\n#wp-subscribe.wp-subscribe-{$id} ";
|
111 |
-
|
112 |
-
if ( 'subscribe_form' == $type ) {
|
113 |
-
$css[] = sprintf( '{background: %s}', $options['background_color'] );
|
114 |
-
$css[] = sprintf( 'h4 {color: %s}', $options['title_color'] );
|
115 |
-
$css[] = sprintf( 'p {color: %s}', $options['text_color'] );
|
116 |
-
$css[] = sprintf( '.regular-text {background: %s; color: %s }', $options['field_background_color'], $options['field_text_color'] );
|
117 |
-
$css[] = sprintf( '.submit {background: %s; color: %s }', $options['button_background_color'], $options['button_text_color'] );
|
118 |
-
$css[] = sprintf( '.thanks {color: %s; display: none}', $options['text_color'] );
|
119 |
-
$css[] = sprintf( '.error {color: %s; display: none}', $options['text_color'] );
|
120 |
-
$css[] = sprintf( '.footer-text {color: %s }', $options['footer_text_color'] );
|
121 |
-
}
|
122 |
-
?>
|
123 |
-
<style>
|
124 |
-
<?php echo $id . join( $id, $css ) ?>
|
125 |
-
</style>
|
126 |
-
<?php
|
127 |
-
}
|
128 |
-
|
129 |
/**
|
130 |
* Get widget setting by id
|
131 |
* @param int $widget_id
|
@@ -367,7 +337,7 @@ function wps_get_service_list( $name = '' ) {
|
|
367 |
return;
|
368 |
}
|
369 |
|
370 |
-
$list =
|
371 |
|
372 |
return empty( $list ) ? array() : $list;
|
373 |
}
|
35 |
<div class="wp-subscribe-popup-form-wrapper">
|
36 |
<?php endif; ?>
|
37 |
|
|
|
|
|
38 |
<div id="wp-subscribe" class="wp-subscribe-wrap wp-subscribe wp-subscribe-<?php echo $wp_subscribe_forms ?>" data-thanks_page="<?php echo absint( $options['thanks_page'] ) ?>" data-thanks_page_url="<?php echo esc_url( $options['thanks_page_url'] ) ?>" data-thanks_page_new_window="0">
|
39 |
|
40 |
<h4 class="title"><?php echo wp_kses_post( $options['title'] )?></h4>
|
96 |
<?php
|
97 |
}
|
98 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
99 |
/**
|
100 |
* Get widget setting by id
|
101 |
* @param int $widget_id
|
337 |
return;
|
338 |
}
|
339 |
|
340 |
+
$list = get_option( 'mts_wps_'. $name . '_lists' );
|
341 |
|
342 |
return empty( $list ) ? array() : $list;
|
343 |
}
|
includes/wps-widget.php
CHANGED
@@ -308,7 +308,12 @@ class wp_subscribe extends WP_Widget {
|
|
308 |
));
|
309 |
}
|
310 |
|
311 |
-
function
|
|
|
|
|
|
|
|
|
|
|
312 |
|
313 |
extract( $args );
|
314 |
?>
|
308 |
));
|
309 |
}
|
310 |
|
311 |
+
public function field_raw( $args = array() ) {
|
312 |
+
|
313 |
+
call_user_func_array( $args['content'], array( $args['value'] ) );
|
314 |
+
}
|
315 |
+
|
316 |
+
public function field_checkbox( $args = array() ) {
|
317 |
|
318 |
extract( $args );
|
319 |
?>
|
languages/wp-subscribe.mo
CHANGED
File without changes
|
languages/wp-subscribe.po
CHANGED
File without changes
|
package.json
DELETED
@@ -1,19 +0,0 @@
|
|
1 |
-
{
|
2 |
-
"name": "WP-Subscribe-Pro",
|
3 |
-
"version": "0.0.1",
|
4 |
-
"description": "The subscriber plugin",
|
5 |
-
"main": "index.js",
|
6 |
-
"scripts": {
|
7 |
-
"test": "echo \"Error: no test specified\" && exit 1"
|
8 |
-
},
|
9 |
-
"keywords": [
|
10 |
-
"mythemeshop"
|
11 |
-
],
|
12 |
-
"author": "MyThemeShop",
|
13 |
-
"license": "ISC",
|
14 |
-
"devDependencies": {
|
15 |
-
"grunt": "^1.0.1",
|
16 |
-
"grunt-checktextdomain": "^1.0.1",
|
17 |
-
"grunt-wp-i18n": "^0.5.4"
|
18 |
-
}
|
19 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: mythemeshop
|
|
3 |
Creator's website link: http://mythemeshop.com/plugins/wp-subscribe/
|
4 |
Tags: subscribe, subscription, subscription box, newsletter, subscribe widget, mailchimp, aweber, feedburner,
|
5 |
Requires at least: 4.0
|
6 |
-
Tested up to: 4.
|
7 |
-
Stable tag: 1.2.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -82,6 +82,16 @@ Please disable all plugins and check if plugin is working properly. Then you can
|
|
82 |
|
83 |
== Changelog ==
|
84 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
85 |
= 1.2.1 =
|
86 |
* Provided backward compatibility for CSS
|
87 |
* Provided backward compatibility for Scoped CSS
|
3 |
Creator's website link: http://mythemeshop.com/plugins/wp-subscribe/
|
4 |
Tags: subscribe, subscription, subscription box, newsletter, subscribe widget, mailchimp, aweber, feedburner,
|
5 |
Requires at least: 4.0
|
6 |
+
Tested up to: 4.7.3
|
7 |
+
Stable tag: 1.2.3
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
82 |
|
83 |
== Changelog ==
|
84 |
|
85 |
+
= 1.2.3 =
|
86 |
+
* Fixed some CSS issues
|
87 |
+
|
88 |
+
= 1.2.2 =
|
89 |
+
* Fixed some javascript issues
|
90 |
+
* Fixed some credentials in Aweber
|
91 |
+
* Improve Mailchimp class
|
92 |
+
* Remove notices and warnings on some places
|
93 |
+
* Change the behavior of saving mailing service lists
|
94 |
+
|
95 |
= 1.2.1 =
|
96 |
* Provided backward compatibility for CSS
|
97 |
* Provided backward compatibility for Scoped CSS
|
wp-subscribe.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: WP Subscribe
|
4 |
* Plugin URI: http://mythemeshop.com/plugins/wp-subscribe/
|
5 |
* Description: WP Subscribe is a simple but powerful subscription plugin which supports MailChimp, Aweber and Feedburner.
|
6 |
-
* Version: 1.2.
|
7 |
* Author: MyThemeShop
|
8 |
* Author URI: http://mythemeshop.com/
|
9 |
* Text Domain: wp-subscribe
|
@@ -27,7 +27,7 @@ if( ! class_exists('MTS_WP_Subscribe') ) :
|
|
27 |
* Plugin Version
|
28 |
* @var string
|
29 |
*/
|
30 |
-
private $version = '1.2.
|
31 |
|
32 |
/**
|
33 |
* Hold an instance of MTS_WP_Subscribe class
|
@@ -250,7 +250,7 @@ if( ! class_exists('MTS_WP_Subscribe') ) :
|
|
250 |
}
|
251 |
|
252 |
// Save for letter use
|
253 |
-
|
254 |
|
255 |
wp_send_json(array(
|
256 |
'success' => true,
|
3 |
* Plugin Name: WP Subscribe
|
4 |
* Plugin URI: http://mythemeshop.com/plugins/wp-subscribe/
|
5 |
* Description: WP Subscribe is a simple but powerful subscription plugin which supports MailChimp, Aweber and Feedburner.
|
6 |
+
* Version: 1.2.3
|
7 |
* Author: MyThemeShop
|
8 |
* Author URI: http://mythemeshop.com/
|
9 |
* Text Domain: wp-subscribe
|
27 |
* Plugin Version
|
28 |
* @var string
|
29 |
*/
|
30 |
+
private $version = '1.2.3';
|
31 |
|
32 |
/**
|
33 |
* Hold an instance of MTS_WP_Subscribe class
|
250 |
}
|
251 |
|
252 |
// Save for letter use
|
253 |
+
update_option( 'mts_wps_'. $name . '_lists', $lists );
|
254 |
|
255 |
wp_send_json(array(
|
256 |
'success' => true,
|