Version Description
Change the welcome announcement bar frequency
Download this release
Release Info
Developer | galdub |
Plugin | myStickymenu |
Version | 2.3.7 |
Comparing to | |
See all releases |
Code changes from version 2.3.6 to 2.3.7
- css/mystickymenu-admin.css +24 -23
- js/mystickymenu-admin.js +35 -0
- mystickymenu.php +2 -2
- readme.txt +4 -1
- welcome-bar.php +64 -14
css/mystickymenu-admin.css
CHANGED
@@ -7,9 +7,6 @@
|
|
7 |
|
8 |
}
|
9 |
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
@font-face {
|
14 |
font-family: 'poppinsbold';
|
15 |
src: url('../fonts/poppins-bold-webfont.woff2') format('woff2'),
|
@@ -19,9 +16,6 @@
|
|
19 |
|
20 |
}
|
21 |
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
@font-face {
|
26 |
font-family: 'poppins_lightregular';
|
27 |
src: url('../fonts/poppins-light-webfont.woff2') format('woff2'),
|
@@ -120,7 +114,7 @@
|
|
120 |
height: 42px;
|
121 |
padding: 0 10px 0 12px;
|
122 |
margin: 0;
|
123 |
-
width:
|
124 |
box-shadow: none;
|
125 |
}
|
126 |
|
@@ -130,6 +124,12 @@
|
|
130 |
margin-top: 7px;
|
131 |
}
|
132 |
|
|
|
|
|
|
|
|
|
|
|
|
|
133 |
.mystickymenu-content-section .mysticky-number:focus {
|
134 |
outline: 0;
|
135 |
}
|
@@ -321,19 +321,19 @@ span.input-px {
|
|
321 |
}
|
322 |
|
323 |
.myStickymenu-upgrade a {
|
324 |
-
|
325 |
-
|
326 |
-
|
327 |
-
|
328 |
-
|
329 |
-
|
330 |
-
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
}
|
338 |
.myStickymenu-upgrade {
|
339 |
float: right;
|
@@ -1531,7 +1531,7 @@ p.udner-title {
|
|
1531 |
}
|
1532 |
.mysticky-welcomebar-setting-content {
|
1533 |
display: flex;
|
1534 |
-
align-items: center
|
1535 |
padding-bottom: 20px;
|
1536 |
}
|
1537 |
.mysticky-welcomebar-setting-content.show-on-apper {
|
@@ -1542,6 +1542,7 @@ p.udner-title {
|
|
1542 |
line-height: 1.2;
|
1543 |
color: #4F4F4F;
|
1544 |
font-weight: 500;
|
|
|
1545 |
width: 210px;
|
1546 |
padding-right: 10px;
|
1547 |
}
|
@@ -1586,7 +1587,7 @@ p.udner-title {
|
|
1586 |
.mysticky-welcomebar-setting-content-right select ,
|
1587 |
.mysticky-welcomebar-setting-content-right input[type="text"] ,
|
1588 |
.mysticky-welcomebar-setting-content-right textarea {
|
1589 |
-
width:
|
1590 |
height: 42px;
|
1591 |
border-radius: 20px;
|
1592 |
color: #32373c;
|
@@ -1599,7 +1600,7 @@ p.udner-title {
|
|
1599 |
font-weight: 400;
|
1600 |
}
|
1601 |
.mysticky-welcomebar-setting-content-right select {
|
1602 |
-
padding-right:
|
1603 |
}
|
1604 |
.mysticky-welcomebar-setting-content-right textarea {
|
1605 |
height: 100px;
|
7 |
|
8 |
}
|
9 |
|
|
|
|
|
|
|
10 |
@font-face {
|
11 |
font-family: 'poppinsbold';
|
12 |
src: url('../fonts/poppins-bold-webfont.woff2') format('woff2'),
|
16 |
|
17 |
}
|
18 |
|
|
|
|
|
|
|
19 |
@font-face {
|
20 |
font-family: 'poppins_lightregular';
|
21 |
src: url('../fonts/poppins-light-webfont.woff2') format('woff2'),
|
114 |
height: 42px;
|
115 |
padding: 0 10px 0 12px;
|
116 |
margin: 0;
|
117 |
+
width: 310px;
|
118 |
box-shadow: none;
|
119 |
}
|
120 |
|
124 |
margin-top: 7px;
|
125 |
}
|
126 |
|
127 |
+
.mysticky-welcomebar-setting-content-right input[type="text"]:disabled {
|
128 |
+
color: #a0a5aa;
|
129 |
+
border-color: #ddd;
|
130 |
+
background-color: #f7f7f7;
|
131 |
+
}
|
132 |
+
|
133 |
.mystickymenu-content-section .mysticky-number:focus {
|
134 |
outline: 0;
|
135 |
}
|
321 |
}
|
322 |
|
323 |
.myStickymenu-upgrade a {
|
324 |
+
background: #E1DAF6;
|
325 |
+
border-radius: 20px;
|
326 |
+
color: #7559C0;
|
327 |
+
padding-top: 2px;
|
328 |
+
padding-bottom: 6px;
|
329 |
+
padding-left: 10px;
|
330 |
+
padding-right: 10px;
|
331 |
+
font-weight: bold;
|
332 |
+
text-transform: uppercase;
|
333 |
+
font-size: 12px;
|
334 |
+
display: inline-block;
|
335 |
+
vertical-align: top;
|
336 |
+
line-height: 1;
|
337 |
}
|
338 |
.myStickymenu-upgrade {
|
339 |
float: right;
|
1531 |
}
|
1532 |
.mysticky-welcomebar-setting-content {
|
1533 |
display: flex;
|
1534 |
+
/*align-items: center;*/
|
1535 |
padding-bottom: 20px;
|
1536 |
}
|
1537 |
.mysticky-welcomebar-setting-content.show-on-apper {
|
1542 |
line-height: 1.2;
|
1543 |
color: #4F4F4F;
|
1544 |
font-weight: 500;
|
1545 |
+
margin-top: 10px;
|
1546 |
width: 210px;
|
1547 |
padding-right: 10px;
|
1548 |
}
|
1587 |
.mysticky-welcomebar-setting-content-right select ,
|
1588 |
.mysticky-welcomebar-setting-content-right input[type="text"] ,
|
1589 |
.mysticky-welcomebar-setting-content-right textarea {
|
1590 |
+
width: 310px;
|
1591 |
height: 42px;
|
1592 |
border-radius: 20px;
|
1593 |
color: #32373c;
|
1600 |
font-weight: 400;
|
1601 |
}
|
1602 |
.mysticky-welcomebar-setting-content-right select {
|
1603 |
+
padding-right: 22px;
|
1604 |
}
|
1605 |
.mysticky-welcomebar-setting-content-right textarea {
|
1606 |
height: 100px;
|
js/mystickymenu-admin.js
CHANGED
@@ -221,6 +221,18 @@
|
|
221 |
} else {
|
222 |
$( '.mysticky-welcomebar-fixed' ).removeClass( 'mysticky-welcomebar-btn-desktop' );
|
223 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
224 |
} );
|
225 |
$( 'input[name="mysticky_option_welcomebar[mysticky_welcomebar_btn_mobile]"]' ).on( 'change', function(){
|
226 |
if( $( this ).prop( "checked" ) == true ) {
|
@@ -228,7 +240,30 @@
|
|
228 |
} else {
|
229 |
$( '.mysticky-welcomebar-fixed' ).removeClass( 'mysticky-welcomebar-btn-mobile' );
|
230 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
231 |
} );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
232 |
|
233 |
$( 'select[name="mysticky_option_welcomebar[mysticky_welcomebar_font]"]' ).on( 'change', function(){
|
234 |
var myfixed_font_val = $( this ).val();
|
221 |
} else {
|
222 |
$( '.mysticky-welcomebar-fixed' ).removeClass( 'mysticky-welcomebar-btn-desktop' );
|
223 |
}
|
224 |
+
|
225 |
+
if( $( this ).prop( "checked" ) == false && $( 'input[name="mysticky_option_welcomebar[mysticky_welcomebar_btn_mobile]"]' ).prop( "checked" ) == false ) {
|
226 |
+
$( ".mysticky_welcomebar_disable, .mysticky_welcomebar_btn_color button.wp-color-result" ).css({
|
227 |
+
'pointer-events': 'none',
|
228 |
+
'opacity': '0.5'
|
229 |
+
});
|
230 |
+
} else {
|
231 |
+
$( ".mysticky_welcomebar_disable, .mysticky_welcomebar_btn_color button.wp-color-result" ).css({
|
232 |
+
'pointer-events': '',
|
233 |
+
'opacity': ''
|
234 |
+
});
|
235 |
+
}
|
236 |
} );
|
237 |
$( 'input[name="mysticky_option_welcomebar[mysticky_welcomebar_btn_mobile]"]' ).on( 'change', function(){
|
238 |
if( $( this ).prop( "checked" ) == true ) {
|
240 |
} else {
|
241 |
$( '.mysticky-welcomebar-fixed' ).removeClass( 'mysticky-welcomebar-btn-mobile' );
|
242 |
}
|
243 |
+
|
244 |
+
if( $( this ).prop( "checked" ) == false && $( 'input[name="mysticky_option_welcomebar[mysticky_welcomebar_btn_desktop]"]' ).prop( "checked" ) == false ) {
|
245 |
+
$( ".mysticky_welcomebar_disable, .mysticky_welcomebar_btn_color button.wp-color-result" ).css({
|
246 |
+
'pointer-events': 'none',
|
247 |
+
'opacity': '0.5'
|
248 |
+
});
|
249 |
+
} else {
|
250 |
+
$( ".mysticky_welcomebar_disable, .mysticky_welcomebar_btn_color button.wp-color-result" ).css({
|
251 |
+
'pointer-events': '',
|
252 |
+
'opacity': ''
|
253 |
+
});
|
254 |
+
}
|
255 |
} );
|
256 |
+
if( $( 'input[name="mysticky_option_welcomebar[mysticky_welcomebar_btn_desktop]"]' ).prop( "checked" ) == false && $( 'input[name="mysticky_option_welcomebar[mysticky_welcomebar_btn_mobile]"]' ).prop( "checked" ) == false ) {
|
257 |
+
$( ".mysticky_welcomebar_disable, .mysticky_welcomebar_btn_color button.wp-color-result" ).css({
|
258 |
+
'pointer-events': 'none',
|
259 |
+
'opacity': '0.5'
|
260 |
+
});
|
261 |
+
} else {
|
262 |
+
$( ".mysticky_welcomebar_disable, .mysticky_welcomebar_btn_color button.wp-color-result" ).css({
|
263 |
+
'pointer-events': '',
|
264 |
+
'opacity': ''
|
265 |
+
});
|
266 |
+
}
|
267 |
|
268 |
$( 'select[name="mysticky_option_welcomebar[mysticky_welcomebar_font]"]' ).on( 'change', function(){
|
269 |
var myfixed_font_val = $( this ).val();
|
mystickymenu.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: myStickymenu
|
4 |
Plugin URI: https://premio.io/
|
5 |
Description: Simple sticky (fixed on top) menu implementation for navigation menu and Welcome bar for announcements and promotion. After install go to Settings / myStickymenu and change Sticky Class to .your_navbar_class or #your_navbar_id.
|
6 |
-
Version: 2.3.
|
7 |
Author: Premio
|
8 |
Author URI: https://premio.io/downloads/mystickymenu/
|
9 |
Text Domain: mystickymenu
|
@@ -12,7 +12,7 @@ License: GPLv2 or later
|
|
12 |
*/
|
13 |
|
14 |
defined('ABSPATH') or die("Cannot access pages directly.");
|
15 |
-
define( 'MYSTICKY_VERSION', '2.3.
|
16 |
require_once("mystickymenu-fonts.php");
|
17 |
require_once("welcome-bar.php");
|
18 |
|
3 |
Plugin Name: myStickymenu
|
4 |
Plugin URI: https://premio.io/
|
5 |
Description: Simple sticky (fixed on top) menu implementation for navigation menu and Welcome bar for announcements and promotion. After install go to Settings / myStickymenu and change Sticky Class to .your_navbar_class or #your_navbar_id.
|
6 |
+
Version: 2.3.7
|
7 |
Author: Premio
|
8 |
Author URI: https://premio.io/downloads/mystickymenu/
|
9 |
Text Domain: mystickymenu
|
12 |
*/
|
13 |
|
14 |
defined('ABSPATH') or die("Cannot access pages directly.");
|
15 |
+
define( 'MYSTICKY_VERSION', '2.3.7' );
|
16 |
require_once("mystickymenu-fonts.php");
|
17 |
require_once("welcome-bar.php");
|
18 |
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: tomeraharon, galdub, premio
|
|
3 |
Tags:menu, header, sticky menu, sticky header, floating menu, floating navigation menu, navigation menu, navigation, sticky navigation menu, welcome bar, hello bar, top bar, sticky bar, floating bar, notification bar
|
4 |
Requires at least: 3.5.1
|
5 |
Tested up to: 5.4
|
6 |
-
Stable tag: 2.3.
|
7 |
License: GPLv2 or later
|
8 |
|
9 |
This sticky menu plugin will make your menu or header stick to the top of page, when scrolled down and up. Also create a beautiful Welcome bar with it.
|
@@ -42,6 +42,7 @@ My Sticky Menu is tested and compatible with Elementor website builder, Divi, WP
|
|
42 |
= WITH WELCOME BAR FEATURE YOU CAN: =
|
43 |
* Display your floating bar at top position
|
44 |
* Change the background and button colors for your hello bar
|
|
|
45 |
* Add an attention effect to your button and increase conversion and CTR
|
46 |
* Change font size and font family
|
47 |
* Set your own text and call-to-action button text
|
@@ -259,6 +260,8 @@ After installing the plugin, you’ll have the option to turn on the welcome bar
|
|
259 |
|
260 |
|
261 |
== Changelog ==
|
|
|
|
|
262 |
= 2.3.6 =
|
263 |
WP 5.4 compatibility, and welcome announcement bar fixed
|
264 |
= 2.3.5 =
|
3 |
Tags:menu, header, sticky menu, sticky header, floating menu, floating navigation menu, navigation menu, navigation, sticky navigation menu, welcome bar, hello bar, top bar, sticky bar, floating bar, notification bar
|
4 |
Requires at least: 3.5.1
|
5 |
Tested up to: 5.4
|
6 |
+
Stable tag: 2.3.7
|
7 |
License: GPLv2 or later
|
8 |
|
9 |
This sticky menu plugin will make your menu or header stick to the top of page, when scrolled down and up. Also create a beautiful Welcome bar with it.
|
42 |
= WITH WELCOME BAR FEATURE YOU CAN: =
|
43 |
* Display your floating bar at top position
|
44 |
* Change the background and button colors for your hello bar
|
45 |
+
* Change display frequency after submission - show the announcement bar on every page, once a visit, or don't show the announcement bar after it's submitted
|
46 |
* Add an attention effect to your button and increase conversion and CTR
|
47 |
* Change font size and font family
|
48 |
* Set your own text and call-to-action button text
|
260 |
|
261 |
|
262 |
== Changelog ==
|
263 |
+
= 2.3.7 =
|
264 |
+
Change the welcome announcement bar frequency
|
265 |
= 2.3.6 =
|
266 |
WP 5.4 compatibility, and welcome announcement bar fixed
|
267 |
= 2.3.5 =
|
welcome-bar.php
CHANGED
@@ -142,20 +142,20 @@ function mysticky_welcome_bar_backend() {
|
|
142 |
</div>
|
143 |
<div class="mysticky-welcomebar-setting-content">
|
144 |
<label><?php _e('Button Color', 'myStickymenu'); ?></label>
|
145 |
-
<div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-colorpicker">
|
146 |
<input type="text" id="mysticky_welcomebar_btncolor" name="mysticky_option_welcomebar[mysticky_welcomebar_btncolor]" class="my-color-field" data-alpha="true" value="<?php echo esc_attr($welcomebar['mysticky_welcomebar_btncolor']);?>" />
|
147 |
</div>
|
148 |
</div>
|
149 |
<div class="mysticky-welcomebar-setting-content">
|
150 |
<label><?php _e('Button Text Color', 'myStickymenu'); ?></label>
|
151 |
-
<div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-colorpicker">
|
152 |
<input type="text" id="mysticky_welcomebar_btntxtcolor" name="mysticky_option_welcomebar[mysticky_welcomebar_btntxtcolor]" class="my-color-field" data-alpha="true" value="<?php echo $welcomebar['mysticky_welcomebar_btntxtcolor'];?>" />
|
153 |
</div>
|
154 |
</div>
|
155 |
<div class="mysticky-welcomebar-setting-content">
|
156 |
<label><?php _e('Button Text', 'myStickymenu'); ?></label>
|
157 |
<div class="mysticky-welcomebar-setting-content-right">
|
158 |
-
<input type="text" id="mysticky_welcomebar_btn_text" class="mystickyinput" name="mysticky_option_welcomebar[mysticky_welcomebar_btn_text]" value="<?php echo $welcomebar['mysticky_welcomebar_btn_text'];?>" />
|
159 |
</div>
|
160 |
</div>
|
161 |
<!-- -->
|
@@ -163,7 +163,7 @@ function mysticky_welcome_bar_backend() {
|
|
163 |
<label><?php _e('Attention Effect', 'myStickymenu'); ?></label>
|
164 |
<div class="mysticky-welcomebar-setting-content-right">
|
165 |
<div class="mysticky-welcomebar-setting-attention">
|
166 |
-
<select name="mysticky_option_welcomebar[mysticky_welcomebar_attentionselect]" class="mysticky-welcomebar-attention">
|
167 |
<option value="default" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], ' ' ); ?>><?php _e( 'None', 'myStickymenu' );?></option>
|
168 |
<option value="flash" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'flash' ); ?>><?php _e( 'Flash', 'myStickymenu' );?></option>
|
169 |
<option value="shake" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'shake' ); ?>><?php _e( 'Shake', 'myStickymenu' );?></option>
|
@@ -180,14 +180,14 @@ function mysticky_welcome_bar_backend() {
|
|
180 |
<label><?php _e('Button Submission', 'myStickymenu'); ?></label>
|
181 |
<div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-setting-redirect-wrap">
|
182 |
<div class="mysticky-welcomebar-setting-action">
|
183 |
-
<select name="mysticky_option_welcomebar[mysticky_welcomebar_actionselect]" class="mysticky-welcomebar-action">
|
184 |
<option value="redirect_to_url" <?php selected( @$welcomebar['mysticky_welcomebar_actionselect'], 'redirect_to_url' ); ?>><?php _e( 'Redirect to URL', 'myStickymenu' );?></option>
|
185 |
<option value="close_bar" <?php selected( @$welcomebar['mysticky_welcomebar_actionselect'], 'close_bar' ); ?>><?php _e( 'Close bar', 'myStickymenu' );?></option>
|
186 |
<option value="thankyou_screen" data-href="<?php echo esc_url($upgarde_url); ?>"><?php _e( 'Thank you screen (Upgrade Now)', 'myStickymenu' );?></option>
|
187 |
</select>
|
188 |
</div>
|
189 |
<div class="mysticky-welcomebar-setting-action mysticky-welcomebar-redirect" <?php if ( $welcomebar['mysticky_welcomebar_actionselect'] == 'close_bar' ) : ?> style="display:none;" <?php endif;?> >
|
190 |
-
<input type="text" id="mysticky_welcomebar_redirect" class="mystickyinput" name="mysticky_option_welcomebar[mysticky_welcomebar_redirect]" value="<?php echo esc_url($welcomebar['mysticky_welcomebar_redirect']);?>" placeholder="<?php echo esc_url("https://www.yourdomain.com"); ?>" />
|
191 |
</div>
|
192 |
<div class="mysticky-welcomebar-setting-newtab mysticky-welcomebar-redirect" <?php if ( $welcomebar['mysticky_welcomebar_actionselect'] == 'close_bar' ) : ?> style="display:none;" <?php endif;?> >
|
193 |
<label>
|
@@ -198,6 +198,19 @@ function mysticky_welcome_bar_backend() {
|
|
198 |
</div>
|
199 |
</div>
|
200 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
201 |
|
202 |
<div class="mysticky-welcomebar-setting-content mysticky-welcomebar-setting-remove-getbar">
|
203 |
<label><?php _e('Remove myStickymenu Credit', 'myStickymenu'); ?></label>
|
@@ -477,7 +490,7 @@ function mysticky_welcome_bar_backend() {
|
|
477 |
|
478 |
/* Animated Buttons */
|
479 |
.mysticky-welcomebar-btn a {
|
480 |
-
-webkit-animation: 1s;
|
481 |
animation-duration: 1s;
|
482 |
}
|
483 |
@-webkit-keyframes flash {
|
@@ -834,6 +847,7 @@ function mysticky_welcomebar_pro_widget_default_fields() {
|
|
834 |
'mysticky_welcomebar_btntxtcolor' => '#ffffff',
|
835 |
'mysticky_welcomebar_btn_text' => 'Got it!',
|
836 |
'mysticky_welcomebar_actionselect' => 'close_bar',
|
|
|
837 |
'mysticky_welcomebar_redirect' => 'https://www.yourdomain.com',
|
838 |
'mysticky_welcomebar_redirect_newtab' => '',
|
839 |
'mysticky_welcomebar_device_desktop' => 'desktop',
|
@@ -888,7 +902,7 @@ function mysticky_welcome_bar_frontend(){
|
|
888 |
}
|
889 |
|
890 |
?>
|
891 |
-
<div class="mysticky-welcomebar-fixed <?php echo $display_main_class; ?>" style="<?php echo $welcomebar_enable_block; ?>" data-after-triger="after_a_few_seconds" data-triger-sec="0" data-position="<?php echo esc_attr($welcomebar['mysticky_welcomebar_position']);?>" data-height="<?php echo esc_attr($welcomebar['mysticky_welcomebar_height']);?>" data-rediect="<?php echo esc_attr($welcomebar['mysticky_welcomebar_actionselect']);?>">
|
892 |
<div class="mysticky-welcomebar-content">
|
893 |
<?php echo wpautop( isset($welcomebar['mysticky_welcomebar_bar_text'])? stripslashes($welcomebar['mysticky_welcomebar_bar_text']) :"Get 30% off your first purchase" );?>
|
894 |
</div>
|
@@ -907,7 +921,17 @@ function mysticky_welcome_bar_frontend(){
|
|
907 |
} else {
|
908 |
jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '-' + mysticky_welcomebar_height + 'px' );
|
909 |
}
|
910 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
911 |
|
912 |
var after_trigger = jQuery( '.mysticky-welcomebar-fixed' ).data('after-triger');
|
913 |
|
@@ -963,7 +987,16 @@ function mysticky_welcome_bar_frontend(){
|
|
963 |
mystickyelements_present();
|
964 |
}
|
965 |
$( window ).resize( function(){
|
966 |
-
if
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
967 |
var after_trigger = jQuery( '.mysticky-welcomebar-fixed' ).data('after-triger');
|
968 |
if ( after_trigger == 'after_a_few_seconds' ) {
|
969 |
var trigger_sec = jQuery( '.mysticky-welcomebar-fixed' ).data('triger-sec') * 1000;
|
@@ -1012,7 +1045,16 @@ function mysticky_welcome_bar_frontend(){
|
|
1012 |
} );
|
1013 |
|
1014 |
jQuery(window).scroll(function(){
|
1015 |
-
if
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1016 |
var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
|
1017 |
var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
|
1018 |
if ( welcombar_position == 'top' ) {
|
@@ -1064,9 +1106,17 @@ function mysticky_welcome_bar_frontend(){
|
|
1064 |
}
|
1065 |
|
1066 |
});
|
|
|
1067 |
jQuery( '.mysticky-welcomebar-close, .mysticky-welcomebar-btn a' ).on( 'click', function(){
|
1068 |
-
|
1069 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1070 |
var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
|
1071 |
var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
|
1072 |
jQuery( '.mysticky-welcomebar-fixed' ).slideUp( 'slow' );
|
@@ -1271,8 +1321,8 @@ function mysticky_welcome_bar_frontend(){
|
|
1271 |
}
|
1272 |
/* Animated Buttons */
|
1273 |
.mysticky-welcomebar-btn a {
|
1274 |
-
animation-duration: 1s;
|
1275 |
-webkit-animation-duration: 1s;
|
|
|
1276 |
}
|
1277 |
@-webkit-keyframes flash {
|
1278 |
from,
|
142 |
</div>
|
143 |
<div class="mysticky-welcomebar-setting-content">
|
144 |
<label><?php _e('Button Color', 'myStickymenu'); ?></label>
|
145 |
+
<div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-colorpicker mysticky_welcomebar_btn_color">
|
146 |
<input type="text" id="mysticky_welcomebar_btncolor" name="mysticky_option_welcomebar[mysticky_welcomebar_btncolor]" class="my-color-field" data-alpha="true" value="<?php echo esc_attr($welcomebar['mysticky_welcomebar_btncolor']);?>" />
|
147 |
</div>
|
148 |
</div>
|
149 |
<div class="mysticky-welcomebar-setting-content">
|
150 |
<label><?php _e('Button Text Color', 'myStickymenu'); ?></label>
|
151 |
+
<div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-colorpicker mysticky_welcomebar_btn_color">
|
152 |
<input type="text" id="mysticky_welcomebar_btntxtcolor" name="mysticky_option_welcomebar[mysticky_welcomebar_btntxtcolor]" class="my-color-field" data-alpha="true" value="<?php echo $welcomebar['mysticky_welcomebar_btntxtcolor'];?>" />
|
153 |
</div>
|
154 |
</div>
|
155 |
<div class="mysticky-welcomebar-setting-content">
|
156 |
<label><?php _e('Button Text', 'myStickymenu'); ?></label>
|
157 |
<div class="mysticky-welcomebar-setting-content-right">
|
158 |
+
<input type="text" id="mysticky_welcomebar_btn_text" class="mystickyinput mysticky_welcomebar_disable" name="mysticky_option_welcomebar[mysticky_welcomebar_btn_text]" value="<?php echo $welcomebar['mysticky_welcomebar_btn_text'];?>" />
|
159 |
</div>
|
160 |
</div>
|
161 |
<!-- -->
|
163 |
<label><?php _e('Attention Effect', 'myStickymenu'); ?></label>
|
164 |
<div class="mysticky-welcomebar-setting-content-right">
|
165 |
<div class="mysticky-welcomebar-setting-attention">
|
166 |
+
<select name="mysticky_option_welcomebar[mysticky_welcomebar_attentionselect]" class="mysticky-welcomebar-attention mysticky_welcomebar_disable">
|
167 |
<option value="default" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], ' ' ); ?>><?php _e( 'None', 'myStickymenu' );?></option>
|
168 |
<option value="flash" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'flash' ); ?>><?php _e( 'Flash', 'myStickymenu' );?></option>
|
169 |
<option value="shake" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'shake' ); ?>><?php _e( 'Shake', 'myStickymenu' );?></option>
|
180 |
<label><?php _e('Button Submission', 'myStickymenu'); ?></label>
|
181 |
<div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-setting-redirect-wrap">
|
182 |
<div class="mysticky-welcomebar-setting-action">
|
183 |
+
<select name="mysticky_option_welcomebar[mysticky_welcomebar_actionselect]" class="mysticky-welcomebar-action mysticky_welcomebar_disable">
|
184 |
<option value="redirect_to_url" <?php selected( @$welcomebar['mysticky_welcomebar_actionselect'], 'redirect_to_url' ); ?>><?php _e( 'Redirect to URL', 'myStickymenu' );?></option>
|
185 |
<option value="close_bar" <?php selected( @$welcomebar['mysticky_welcomebar_actionselect'], 'close_bar' ); ?>><?php _e( 'Close bar', 'myStickymenu' );?></option>
|
186 |
<option value="thankyou_screen" data-href="<?php echo esc_url($upgarde_url); ?>"><?php _e( 'Thank you screen (Upgrade Now)', 'myStickymenu' );?></option>
|
187 |
</select>
|
188 |
</div>
|
189 |
<div class="mysticky-welcomebar-setting-action mysticky-welcomebar-redirect" <?php if ( $welcomebar['mysticky_welcomebar_actionselect'] == 'close_bar' ) : ?> style="display:none;" <?php endif;?> >
|
190 |
+
<input type="text" id="mysticky_welcomebar_redirect" class="mystickyinput mysticky_welcomebar_disable" name="mysticky_option_welcomebar[mysticky_welcomebar_redirect]" value="<?php echo esc_url($welcomebar['mysticky_welcomebar_redirect']);?>" placeholder="<?php echo esc_url("https://www.yourdomain.com"); ?>" />
|
191 |
</div>
|
192 |
<div class="mysticky-welcomebar-setting-newtab mysticky-welcomebar-redirect" <?php if ( $welcomebar['mysticky_welcomebar_actionselect'] == 'close_bar' ) : ?> style="display:none;" <?php endif;?> >
|
193 |
<label>
|
198 |
</div>
|
199 |
</div>
|
200 |
</div>
|
201 |
+
<!-- -->
|
202 |
+
<div class="mysticky-welcomebar-setting-content">
|
203 |
+
<label><?php _e('After Submission', 'myStickymenu'); ?></label>
|
204 |
+
<div class="mysticky-welcomebar-setting-content-right">
|
205 |
+
<div class="mysticky-welcomebar-setting-action">
|
206 |
+
<select name="mysticky_option_welcomebar[mysticky_welcomebar_aftersubmission]" class="mysticky-welcomebar-aftersubmission mysticky_welcomebar_disable">
|
207 |
+
<option value="dont_show_welcomebar" <?php selected( @$welcomebar['mysticky_welcomebar_aftersubmission'], 'dont_show_welcomebar' ); ?>><?php _e( "Don't show the Welcome Bar", 'myStickymenu' );?></option>
|
208 |
+
<option value="show_welcomebar_next_visit" <?php selected( @$welcomebar['mysticky_welcomebar_aftersubmission'], 'show_welcomebar_next_visit' ); ?>><?php _e( 'Show the Welcome Bar in the next visit', 'myStickymenu' );?></option>
|
209 |
+
<option value="show_welcomebar_every_page" <?php selected( @$welcomebar['mysticky_welcomebar_aftersubmission'], 'show_welcomebar_every_page' ); ?> ><?php _e( 'Show the Welcome Bar on every page', 'myStickymenu' );?></option>
|
210 |
+
</select>
|
211 |
+
</div>
|
212 |
+
</div>
|
213 |
+
</div>
|
214 |
|
215 |
<div class="mysticky-welcomebar-setting-content mysticky-welcomebar-setting-remove-getbar">
|
216 |
<label><?php _e('Remove myStickymenu Credit', 'myStickymenu'); ?></label>
|
490 |
|
491 |
/* Animated Buttons */
|
492 |
.mysticky-welcomebar-btn a {
|
493 |
+
-webkit-animation-duration: 1s;
|
494 |
animation-duration: 1s;
|
495 |
}
|
496 |
@-webkit-keyframes flash {
|
847 |
'mysticky_welcomebar_btntxtcolor' => '#ffffff',
|
848 |
'mysticky_welcomebar_btn_text' => 'Got it!',
|
849 |
'mysticky_welcomebar_actionselect' => 'close_bar',
|
850 |
+
'mysticky_welcomebar_aftersubmission' => 'dont_show_welcomebar',
|
851 |
'mysticky_welcomebar_redirect' => 'https://www.yourdomain.com',
|
852 |
'mysticky_welcomebar_redirect_newtab' => '',
|
853 |
'mysticky_welcomebar_device_desktop' => 'desktop',
|
902 |
}
|
903 |
|
904 |
?>
|
905 |
+
<div class="mysticky-welcomebar-fixed <?php echo $display_main_class; ?>" style="<?php echo $welcomebar_enable_block; ?>" data-after-triger="after_a_few_seconds" data-triger-sec="0" data-position="<?php echo esc_attr($welcomebar['mysticky_welcomebar_position']);?>" data-height="<?php echo esc_attr($welcomebar['mysticky_welcomebar_height']);?>" data-rediect="<?php echo esc_attr($welcomebar['mysticky_welcomebar_actionselect']);?>" data-aftersubmission="<?php echo esc_attr($welcomebar['mysticky_welcomebar_aftersubmission']);?>">
|
906 |
<div class="mysticky-welcomebar-content">
|
907 |
<?php echo wpautop( isset($welcomebar['mysticky_welcomebar_bar_text'])? stripslashes($welcomebar['mysticky_welcomebar_bar_text']) :"Get 30% off your first purchase" );?>
|
908 |
</div>
|
921 |
} else {
|
922 |
jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '-' + mysticky_welcomebar_height + 'px' );
|
923 |
}
|
924 |
+
var welcombar_aftersubmission = $( '.mysticky-welcomebar-fixed' ).data('aftersubmission');
|
925 |
+
if( welcombar_aftersubmission == 'dont_show_welcomebar' ){
|
926 |
+
var welcomebar_storage = localStorage.getItem("welcomebar_close");
|
927 |
+
} else if( welcombar_aftersubmission == 'show_welcomebar_next_visit' ) {
|
928 |
+
var welcomebar_storage = sessionStorage.getItem("welcomebar_close");
|
929 |
+
} else {
|
930 |
+
sessionStorage.removeItem('welcomebar_close');
|
931 |
+
localStorage.removeItem('welcomebar_close');
|
932 |
+
var welcomebar_storage = null;
|
933 |
+
}
|
934 |
+
if ( welcomebar_storage === null ){
|
935 |
|
936 |
var after_trigger = jQuery( '.mysticky-welcomebar-fixed' ).data('after-triger');
|
937 |
|
987 |
mystickyelements_present();
|
988 |
}
|
989 |
$( window ).resize( function(){
|
990 |
+
if( welcombar_aftersubmission == 'dont_show_welcomebar' ){
|
991 |
+
var welcomebar_storage = localStorage.getItem("welcomebar_close");
|
992 |
+
} else if( welcombar_aftersubmission == 'show_welcomebar_next_visit' ) {
|
993 |
+
var welcomebar_storage = sessionStorage.getItem("welcomebar_close");
|
994 |
+
} else {
|
995 |
+
sessionStorage.removeItem('welcomebar_close');
|
996 |
+
localStorage.removeItem('welcomebar_close');
|
997 |
+
var welcomebar_storage = null;
|
998 |
+
}
|
999 |
+
if ( welcomebar_storage === null ){
|
1000 |
var after_trigger = jQuery( '.mysticky-welcomebar-fixed' ).data('after-triger');
|
1001 |
if ( after_trigger == 'after_a_few_seconds' ) {
|
1002 |
var trigger_sec = jQuery( '.mysticky-welcomebar-fixed' ).data('triger-sec') * 1000;
|
1045 |
} );
|
1046 |
|
1047 |
jQuery(window).scroll(function(){
|
1048 |
+
if( welcombar_aftersubmission == 'dont_show_welcomebar' ){
|
1049 |
+
var welcomebar_storage = localStorage.getItem("welcomebar_close");
|
1050 |
+
} else if( welcombar_aftersubmission == 'show_welcomebar_next_visit' ) {
|
1051 |
+
var welcomebar_storage = sessionStorage.getItem("welcomebar_close");
|
1052 |
+
} else {
|
1053 |
+
sessionStorage.removeItem('welcomebar_close');
|
1054 |
+
localStorage.removeItem('welcomebar_close');
|
1055 |
+
var welcomebar_storage = null;
|
1056 |
+
}
|
1057 |
+
if ( welcomebar_storage === null ){
|
1058 |
var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
|
1059 |
var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
|
1060 |
if ( welcombar_position == 'top' ) {
|
1106 |
}
|
1107 |
|
1108 |
});
|
1109 |
+
|
1110 |
jQuery( '.mysticky-welcomebar-close, .mysticky-welcomebar-btn a' ).on( 'click', function(){
|
1111 |
+
if( welcombar_aftersubmission != 'show_welcomebar_every_page' ){
|
1112 |
+
if( welcombar_aftersubmission == 'dont_show_welcomebar' ){
|
1113 |
+
sessionStorage.removeItem('welcomebar_close');
|
1114 |
+
localStorage.setItem('welcomebar_close', 'close');
|
1115 |
+
} else if( welcombar_aftersubmission == 'show_welcomebar_next_visit' ) {
|
1116 |
+
localStorage.removeItem('welcomebar_close');
|
1117 |
+
sessionStorage.setItem('welcomebar_close', 'close');
|
1118 |
+
}
|
1119 |
+
}
|
1120 |
var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
|
1121 |
var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
|
1122 |
jQuery( '.mysticky-welcomebar-fixed' ).slideUp( 'slow' );
|
1321 |
}
|
1322 |
/* Animated Buttons */
|
1323 |
.mysticky-welcomebar-btn a {
|
|
|
1324 |
-webkit-animation-duration: 1s;
|
1325 |
+
animation-duration: 1s;
|
1326 |
}
|
1327 |
@-webkit-keyframes flash {
|
1328 |
from,
|