bar-preview.php
7 months ago
bar-settings.php
1 year ago
customize-bar.php
7 months ago
display-rules.php
7 months ago
email-signup.php
7 months ago
help.php
9 months ago
poptin-plugin.php
7 months ago
poptin-popup.php
7 months ago
stickymenu-dashboard.php
9 months ago
email-signup.php
552 lines
| 1 | <?php if (!defined('ABSPATH')) { exit; } |
| 2 | $email = (isset($_SERVER['HTTP_HOST']) && $_SERVER['HTTP_HOST'] == "playground.wordpress.net")?"":get_option('admin_email'); |
| 3 | $popup_data = MYSTICKYMENU_UPDATE_POPUP_CONTENT; // get Data from update class, |
| 4 | |
| 5 | ?> |
| 6 | <style> |
| 7 | |
| 8 | @import url('https://fonts.googleapis.com/css2?family=Poppins:wght@700&display=swap'); |
| 9 | |
| 10 | @font-face { |
| 11 | font-family: 'Lato'; |
| 12 | src: url('<?php echo esc_url($popup_data['font_url']); ?>'); |
| 13 | } |
| 14 | |
| 15 | #wpwrap { |
| 16 | background-color: #fff; |
| 17 | background-position: bottom center; |
| 18 | background-size: cover; |
| 19 | background-image: url('<?php echo esc_url($popup_data['background_image']);?>'); |
| 20 | position: relative; |
| 21 | } |
| 22 | div#wpcontent{ |
| 23 | background-color: transparent !important; |
| 24 | } |
| 25 | #wpbody-content { |
| 26 | padding-bottom: 100px; |
| 27 | } |
| 28 | #wpbody { |
| 29 | height: 100%; |
| 30 | position: unset; |
| 31 | } |
| 32 | .premio-update-popup-wrap { |
| 33 | display: flex; |
| 34 | height: 100%; |
| 35 | width: 100%; |
| 36 | align-items: center; |
| 37 | justify-content: center; |
| 38 | box-sizing: border-box; |
| 39 | } |
| 40 | .premio-update-popup-wrap * { |
| 41 | box-sizing: border-box; |
| 42 | } |
| 43 | |
| 44 | .premio-update-popup-content { |
| 45 | margin-top: 100px; |
| 46 | width: 626px; |
| 47 | box-shadow: 0px 15.511px 46.534px 0px rgba(0, 0, 0, 0.16); |
| 48 | border-radius: 16px; |
| 49 | padding: 36px; |
| 50 | background-color: #FFF; |
| 51 | position: relative; |
| 52 | z-index: 999; |
| 53 | overflow: hidden; |
| 54 | display: flex; |
| 55 | flex-wrap: wrap; |
| 56 | gap: 48px; |
| 57 | margin-left: 20px; |
| 58 | margin-right: 20px; |
| 59 | } |
| 60 | |
| 61 | .premio-update-heading { |
| 62 | color: #092030; |
| 63 | font-family: "Poppins", sans-serif; |
| 64 | font-size: 24px; |
| 65 | font-style: normal; |
| 66 | font-weight: 700; |
| 67 | line-height: normal; |
| 68 | letter-spacing: 0.24px; |
| 69 | margin: 0; |
| 70 | } |
| 71 | |
| 72 | .premio-update-user-trust { |
| 73 | display: flex; |
| 74 | padding: 6px 12px; |
| 75 | align-items: center; |
| 76 | gap: 10px; |
| 77 | border-radius: 100px; |
| 78 | background: rgba(101, 88, 245, 0.10); |
| 79 | width: fit-content; |
| 80 | } |
| 81 | .premio-update-user-trust img { |
| 82 | height: 24px; |
| 83 | } |
| 84 | |
| 85 | .premio-update-user-trust span { |
| 86 | color: #092030; |
| 87 | font-family: Lato, sans-serif; |
| 88 | font-size: 14px; |
| 89 | font-style: normal; |
| 90 | font-weight: 700; |
| 91 | line-height: normal; |
| 92 | } |
| 93 | |
| 94 | .remio-update-popup-content h1 { |
| 95 | color: #092030; |
| 96 | font-family: Lato, sans-serif; |
| 97 | font-size: 32px; |
| 98 | font-style: normal; |
| 99 | font-weight: 800; |
| 100 | line-height: normal; |
| 101 | } |
| 102 | |
| 103 | .premio-content-list { |
| 104 | display: flex; |
| 105 | flex-direction: column; |
| 106 | gap: 8px; |
| 107 | } |
| 108 | |
| 109 | .premio-content-list .premio-content-list-items { |
| 110 | display: flex; |
| 111 | gap: 8px; |
| 112 | align-items: center; |
| 113 | color: #092030; |
| 114 | font-family: Lato, sans-serif; |
| 115 | font-size: 16px; |
| 116 | font-style: normal; |
| 117 | font-weight: 400; |
| 118 | line-height: 150%; |
| 119 | } |
| 120 | |
| 121 | .premio-content-list .premio-content-list-items img { |
| 122 | height: 20px; |
| 123 | width: 20px; |
| 124 | |
| 125 | display: inherit; |
| 126 | } |
| 127 | |
| 128 | /* // X-Small devices (portrait phones, less than 576px) */ |
| 129 | |
| 130 | |
| 131 | .premio-update-froms-input { |
| 132 | margin-top: 24px; |
| 133 | position: relative; |
| 134 | height: 45px; |
| 135 | } |
| 136 | |
| 137 | .premio-update-froms-input input { |
| 138 | height: 100%; |
| 139 | padding: 8px; |
| 140 | width: 100%; |
| 141 | border-radius: 8px; |
| 142 | border: 1px solid #C6D7E3; |
| 143 | padding-left: 40px; |
| 144 | font-size: 13px; |
| 145 | height: 45px; |
| 146 | } |
| 147 | |
| 148 | .premio-update-froms-input input:hover, |
| 149 | .premio-update-froms-input input:focus { |
| 150 | border-color: #6558F5; |
| 151 | outline: none; |
| 152 | box-shadow: none; |
| 153 | } |
| 154 | |
| 155 | .premio-update-froms-input .mail-icon { |
| 156 | position: absolute; |
| 157 | left: 10px; |
| 158 | top: 11px; |
| 159 | z-index: 1; |
| 160 | } |
| 161 | .premio-update-froms-input .mail-icon img { |
| 162 | height: 24px; |
| 163 | width: 24px; |
| 164 | } |
| 165 | |
| 166 | .eac-input-wrap { |
| 167 | width: 100%; |
| 168 | } |
| 169 | |
| 170 | .update-popup-btn { |
| 171 | padding: 12px 24px; |
| 172 | display: flex; |
| 173 | align-items: center; |
| 174 | gap: 10px; |
| 175 | border-radius: 8px; |
| 176 | background: #6558F5; |
| 177 | color: #fff; |
| 178 | border: none; |
| 179 | font-family: Lato, sans-serif; |
| 180 | font-size: 14px; |
| 181 | font-weight: 800; |
| 182 | cursor: pointer; |
| 183 | transition: all 0.3s ease-in-out; |
| 184 | } |
| 185 | |
| 186 | .update-popup-btn:hover, .update-popup-btn:disabled { |
| 187 | background-color: #574bd6; |
| 188 | color: #fff !important; |
| 189 | } |
| 190 | .close-popup { |
| 191 | background-color: #EAEFF2; |
| 192 | color: #49687E; |
| 193 | } |
| 194 | .close-popup:hover, .close-popup:disabled { |
| 195 | background-color: #D3DDE2; |
| 196 | color: #49687E !important; |
| 197 | } |
| 198 | |
| 199 | .update-popup-btn .icon { |
| 200 | padding-top: 4px; |
| 201 | display: inline-block; |
| 202 | } |
| 203 | |
| 204 | |
| 205 | |
| 206 | .premio-update-popup-footer { |
| 207 | display: flex; |
| 208 | justify-content: space-between; |
| 209 | width: 100%; |
| 210 | } |
| 211 | |
| 212 | .premio-update-popup-icon-box { |
| 213 | display: flex; |
| 214 | align-items: self-start; |
| 215 | gap: 8px; |
| 216 | width: 33%; |
| 217 | position: relative; |
| 218 | } |
| 219 | |
| 220 | .premio-update-popup-icon-box .content h4 { |
| 221 | color: #49687E; |
| 222 | font-family: Lato, sans-serif; |
| 223 | font-size: 16px; |
| 224 | font-style: normal; |
| 225 | font-weight: 800; |
| 226 | line-height: normal; |
| 227 | margin: 0; |
| 228 | padding-bottom: 4px; |
| 229 | } |
| 230 | |
| 231 | .premio-update-popup-icon-box .content span { |
| 232 | color: #49687E; |
| 233 | font-family: Lato, sans-serif; |
| 234 | font-size: 12px; |
| 235 | font-style: normal; |
| 236 | font-weight: 400; |
| 237 | line-height: normal; |
| 238 | } |
| 239 | |
| 240 | .premio-update-popup-icon-box .absulate-border { |
| 241 | position: absolute; |
| 242 | left: -14px; |
| 243 | top: 0; |
| 244 | content: ''; |
| 245 | height: 20px; |
| 246 | width: 2px; |
| 247 | background-color: #49687E; |
| 248 | opacity: 0.16; |
| 249 | } |
| 250 | |
| 251 | |
| 252 | .premio-update-popup-bg-shape { |
| 253 | border-radius: 448.684px; |
| 254 | background: rgba(101, 88, 245, 0.24); |
| 255 | filter: blur(150px); |
| 256 | display: inline-block; |
| 257 | width: 214.632px; |
| 258 | height: 448.684px; |
| 259 | transform: rotate(109.229deg); |
| 260 | flex-shrink: 0; |
| 261 | position: absolute; |
| 262 | right: 0; |
| 263 | top: 0; |
| 264 | z-index: -1; |
| 265 | } |
| 266 | |
| 267 | .premio-update-popup-bottom-shape-one { |
| 268 | position: absolute; |
| 269 | bottom: 0; |
| 270 | right: 5%; |
| 271 | } |
| 272 | |
| 273 | .premio-update-popup-right-shape-one { |
| 274 | position: absolute; |
| 275 | bottom: 30%; |
| 276 | right: 0; |
| 277 | } |
| 278 | |
| 279 | .popup-update-btn-wrap { |
| 280 | display: flex; |
| 281 | gap: 24px; |
| 282 | margin-top: 24px; |
| 283 | } |
| 284 | |
| 285 | |
| 286 | |
| 287 | #suggestion { |
| 288 | margin: 0; |
| 289 | padding: 0; |
| 290 | font-size: 14px; |
| 291 | color: #970029; |
| 292 | } |
| 293 | |
| 294 | #suggestion i { |
| 295 | color: #2596be; |
| 296 | font-weight: bold; |
| 297 | cursor: pointer; |
| 298 | } |
| 299 | |
| 300 | .eac-sugg { |
| 301 | color: #c1c1c1; |
| 302 | margin-left: 20px; |
| 303 | } |
| 304 | |
| 305 | #pre-loader{ |
| 306 | height: 17px; |
| 307 | width: 16px; |
| 308 | } |
| 309 | /* responsive */ |
| 310 | @media (max-width: 575.98px) { |
| 311 | #wpcontent { |
| 312 | padding-left: 0 !important; |
| 313 | } |
| 314 | .premio-update-user-trust span { |
| 315 | font-size: 12px; |
| 316 | } |
| 317 | .remio-update-popup-content h1 { |
| 318 | font-size: 28px; |
| 319 | } |
| 320 | .premio-content-list .premio-content-list-items { |
| 321 | align-items: start; |
| 322 | } |
| 323 | .premio-content-list .premio-content-list-items img{ |
| 324 | |
| 325 | margin-top: 5px; |
| 326 | } |
| 327 | |
| 328 | |
| 329 | .premio-update-popup-icon-box .absulate-border { |
| 330 | display: none; |
| 331 | } |
| 332 | .premio-update-popup-footer { |
| 333 | gap: 12px; |
| 334 | flex-direction: column; |
| 335 | justify-content: center; |
| 336 | } |
| 337 | |
| 338 | .premio-update-popup-icon-box { |
| 339 | width: auto; |
| 340 | } |
| 341 | } |
| 342 | |
| 343 | /* responsive */ |
| 344 | </style> |
| 345 | |
| 346 | <div class="premio-update-popup-wrap" > |
| 347 | <img src="<?php echo esc_url($popup_data['shape_bottom']);?>" class="premio-update-popup-bottom-shape-one" alt="shape bottom"> |
| 348 | <img src="<?php echo esc_url($popup_data['shape_bottom_right']); ?>" class="premio-update-popup-right-shape-one" alt="shape right"> |
| 349 | <div class="premio-update-popup-content"> |
| 350 | <span class="premio-update-popup-bg-shape"></span> |
| 351 | <?php if(isset($popup_data['plugin_logo'])): ?> |
| 352 | <img class="plugin-logo" src="<?php echo esc_url($popup_data['plugin_logo']);?>" alt="user trust"> |
| 353 | <?php else: ?> |
| 354 | <h3 class="premio-update-heading"><?php echo esc_html($popup_data['plugin_name']) ?></h3> |
| 355 | <?php endif; ?> |
| 356 | <div class="remio-update-popup-content"> |
| 357 | <div class="premio-update-user-trust"> |
| 358 | <img src="<?php echo esc_url($popup_data['trust_user_img']);?>" alt="user trust"> |
| 359 | |
| 360 | <span><?php echo esc_html($popup_data['trust_user']) ?><span> |
| 361 | </div> |
| 362 | |
| 363 | <h1><?php esc_html_e("We Only Email When It's Worth It", 'mystickymenu') ?></h1> |
| 364 | |
| 365 | <div class="premio-content-list"> |
| 366 | <div class="premio-content-list-items"> |
| 367 | <img src="<?php echo esc_url($popup_data['check_circle']);?>" alt="check circle"> |
| 368 | <span><?php esc_html_e('Plugin updates and features for improved performance', 'mystickymenu') ?> </span> |
| 369 | </div> |
| 370 | <div class="premio-content-list-items"> |
| 371 | <img src="<?php echo esc_url($popup_data['check_circle']);?>" alt="check circle"> |
| 372 | <span><?php esc_html_e('Important security updates for site safety', 'mystickymenu') ?></span> |
| 373 | |
| 374 | </div> |
| 375 | <div class="premio-content-list-items"> |
| 376 | <img src="<?php echo esc_url($popup_data['check_circle']);?>" alt="check circle"> |
| 377 | <span><?php esc_html_e('Limited-time offers for WordPress users seeking growth', 'mystickymenu') ?> </span> |
| 378 | </div> |
| 379 | </div> |
| 380 | |
| 381 | <div class="premio-update-froms-input"> |
| 382 | <span class="mail-icon"> |
| 383 | <img src="<?php echo esc_url($popup_data['mail_icon']) ?>" alt="Mail icon"> |
| 384 | </span> |
| 385 | <input type="email" value="<?php echo esc_attr($email) ?>" name="myStickymenu_update_email" id="myStickymenu_update_email" autocomplete="off" placeholder="<?php esc_html_e('Your Email Address', 'mystickymenu') ?>" required> |
| 386 | |
| 387 | </div> |
| 388 | <p id="suggestion"></p> |
| 389 | <div class="popup-update-btn-wrap"> |
| 390 | <button href="#" class="update-popup-btn submit-popup yes"> <?php esc_html_e('Count Me In', 'mystickymenu')?> |
| 391 | <span class="icon"> |
| 392 | <img class="arrow-right" src="<?php echo esc_url($popup_data['arrow_right']) ?>" alt="arrow right"> |
| 393 | <img id="pre-loader" style="display: none;" src="<?php echo esc_url($popup_data['pre_loader']) ?>" alt="pre loader"> |
| 394 | |
| 395 | </span> |
| 396 | |
| 397 | </button> |
| 398 | <button href="#" class="update-popup-btn close-popup no"> <?php esc_html_e('Maybe Later', 'mystickymenu')?> </button> |
| 399 | </div> |
| 400 | |
| 401 | </div> |
| 402 | |
| 403 | |
| 404 | <div class="premio-update-popup-footer"> |
| 405 | <!-- Icon Box --> |
| 406 | <div class="premio-update-popup-icon-box"> |
| 407 | <div class="icon"> |
| 408 | <img src="<?php echo esc_url($popup_data['user_icon']) ?>" alt="user icon"> |
| 409 | </div> |
| 410 | <div class="content"> |
| 411 | <h4><?php echo esc_html($popup_data['website_owners']) ?></h4> |
| 412 | <span><?php esc_html_e('Website Owners', 'mystickymenu') ?></span> |
| 413 | </div> |
| 414 | </div> |
| 415 | <!-- Icon Box --> |
| 416 | <!-- Icon Box --> |
| 417 | <div class="premio-update-popup-icon-box"> |
| 418 | |
| 419 | <span class="absulate-border"></span> |
| 420 | <div class="icon"> |
| 421 | <img src="<?php echo esc_url($popup_data['slash_icon']) ?>" alt="slash icon"> |
| 422 | </div> |
| 423 | <div class="content"> |
| 424 | <h4><?php esc_html_e('No Spam Ever', 'mystickymenu') ?></h4> |
| 425 | <span><?php esc_html_e('Unsubscribe Anytime', 'mystickymenu') ?></span> |
| 426 | </div> |
| 427 | </div> |
| 428 | <!-- Icon Box --> |
| 429 | <!-- Icon Box --> |
| 430 | <div class="premio-update-popup-icon-box"> |
| 431 | |
| 432 | <span class="absulate-border"></span> |
| 433 | <div class="icon"> |
| 434 | <img src="<?php echo esc_url($popup_data['star_icon']) ?>" alt="star icon"> |
| 435 | </div> |
| 436 | <div class="content"> |
| 437 | <h4><?php echo esc_html($popup_data['rating']) ?></h4> |
| 438 | <span><?php echo esc_html($popup_data['review']) ?></span> |
| 439 | </div> |
| 440 | </div> |
| 441 | <!-- Icon Box --> |
| 442 | </div> |
| 443 | <input type="hidden" id="myStickymenu_update_nonce" value="<?php echo wp_create_nonce("myStickymenu_update_nonce") ?>"> |
| 444 | |
| 445 | </div> |
| 446 | </div> |
| 447 | |
| 448 | <script> |
| 449 | jQuery(document).ready(function($) { |
| 450 | var mailcheck_flg = false; |
| 451 | $(document).on("click", ".update-popup-btn", function () { |
| 452 | //$('#myStickymenu_update_email').trigger( 'blur' ); |
| 453 | // after clicking button button should be disable |
| 454 | $('.update-popup-btn').attr("disabled", true); |
| 455 | |
| 456 | $('#suggestion').html(''); |
| 457 | var email = $('#myStickymenu_update_email').val(); |
| 458 | var preLoader = $('#pre-loader'); |
| 459 | var btnIcon = $('.submit-popup .icon .arrow-right'); |
| 460 | var emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; |
| 461 | |
| 462 | var updateStatus = 0; |
| 463 | if ($(this).hasClass("yes")) { |
| 464 | updateStatus = 1; |
| 465 | } |
| 466 | |
| 467 | |
| 468 | msemailcheck(); |
| 469 | |
| 470 | // Check email address is empty or not its email |
| 471 | if(email == '' && updateStatus == 1){ |
| 472 | $('#suggestion').html('Please enter your email address.'); |
| 473 | // empty this after 5 sec |
| 474 | setTimeout(function(){ $('#suggestion').html(''); }, 5000); |
| 475 | $('.update-popup-btn').attr("disabled", false); |
| 476 | return; |
| 477 | }else if (!emailRegex.test(email) && updateStatus == 1) { |
| 478 | $('#suggestion').html('Please enter a valid email address.'); |
| 479 | // empty this after 5 sec |
| 480 | setTimeout(function(){ $('#suggestion').html(''); }, 5000); |
| 481 | $('.update-popup-btn').attr("disabled", false); |
| 482 | return; |
| 483 | } |
| 484 | |
| 485 | btnIcon.hide(); // hide arrow icon |
| 486 | preLoader.show(); // show loader |
| 487 | |
| 488 | if ( $('#suggestion').html() != '' && mailcheck_flg == false ) { |
| 489 | mailcheck_flg = true; |
| 490 | preLoader.hide(); |
| 491 | btnIcon.show(); |
| 492 | $('.update-popup-btn').attr("disabled", false); |
| 493 | return false; |
| 494 | } |
| 495 | |
| 496 | $.ajax({ |
| 497 | url: ajaxurl, |
| 498 | type: 'post', |
| 499 | data: { |
| 500 | action: "sticky_menu_update_status", |
| 501 | status: updateStatus, |
| 502 | email: email, |
| 503 | nonce: jQuery("#myStickymenu_update_nonce").val() |
| 504 | }, |
| 505 | type: 'post', |
| 506 | cache: false, |
| 507 | success: function () { |
| 508 | mailcheck_flg = false; |
| 509 | preLoader.hide(); |
| 510 | window.location.reload(); |
| 511 | } |
| 512 | }) |
| 513 | }); |
| 514 | |
| 515 | var checkdomains = ["yahoo.com" ,"hotmail.com" ,"gmail.com" ,"me.com" ,"aol.com" ,"mac.com" ,"live.com" ,"comcast.net" ,"googlemail.com" ,"msn.com" ,"hotmail.co.uk" ,"facebook.com" ,"verizon.net" ,"sbcglobal.net" ,"att.net" ,"gmx.com" ,"outlook.com" ,"icloud.com" ,"protonmail.com"]; |
| 516 | var topLevelDomains = ["com", "net", "org", "me", "io"]; |
| 517 | jQuery(document).on('blur','#myStickymenu_update_email', function(event) { |
| 518 | msemailcheck(); |
| 519 | }); |
| 520 | |
| 521 | function msemailcheck() { |
| 522 | |
| 523 | jQuery('#myStickymenu_update_email').mailcheck({ |
| 524 | domains: checkdomains, // Optional array like ['gmail.com', 'yahoo.com'] |
| 525 | topLevelDomains: topLevelDomains, // Optional array like ['com', 'net', 'org'] |
| 526 | suggested: function(element, suggestion) { |
| 527 | |
| 528 | jQuery('#suggestion').html("Did you mean <b><i>" + suggestion.full + "</i></b>?"); |
| 529 | }, |
| 530 | empty: function(element) { |
| 531 | jQuery('#suggestion').html(''); |
| 532 | } |
| 533 | }); |
| 534 | } |
| 535 | |
| 536 | $("#myStickymenu_update_email").emailautocomplete({ |
| 537 | domains: ["yahoo.com" ,"hotmail.com" ,"gmail.com" ,"me.com" ,"aol.com" ,"mac.com" ,"live.com" ,"comcast.net" ,"googlemail.com" ,"msn.com" ,"hotmail.co.uk" ,"facebook.com" ,"verizon.net" ,"sbcglobal.net" ,"att.net" ,"gmx.com" ,"outlook.com" ,"icloud.com" ,"protonmail.com"] |
| 538 | }); |
| 539 | |
| 540 | $(document).on("click", "#suggestion i", function (){ |
| 541 | $("#myStickymenu_update_email").val($(this).text()); |
| 542 | setTimeout(function(){ jQuery('#suggestion').html(''); }, 1000); |
| 543 | }); |
| 544 | }); |
| 545 | </script> |
| 546 | <?php ?> |
| 547 | |
| 548 | |
| 549 | |
| 550 | |
| 551 | |
| 552 |