Version Description
- Added wp review request
Download this release
Release Info
Developer | seedprod |
Plugin | Coming Soon Page & Maintenance Mode by SeedProd |
Version | 5.0.6 |
Comparing to | |
See all releases |
Code changes from version 5.0.5 to 5.0.6
- README.txt +4 -1
- coming-soon.php +8 -5
- framework/framework.php +41 -4
- framework/review.php +108 -0
- inc/class-seed-csp4.php +1 -0
README.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: http://www.seedprod.com
|
|
4 |
Tags: maintenance mode, coming soon page, coming soon, under construction, launch page, launch, maintenance, construction, offline, unavailable, under construction page, landing page
|
5 |
Requires at least: 3.5.1
|
6 |
Tested up to: 4.7.1
|
7 |
-
Stable tag: 5.0.
|
8 |
Text Domain: coming-soon
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
@@ -113,6 +113,9 @@ This is always a caching issue. Go to the caching plugin's setting page and clea
|
|
113 |
4. Design Page
|
114 |
|
115 |
== Changelog ==
|
|
|
|
|
|
|
116 |
= 5.0.5 =
|
117 |
* Disable REST API while in coming soon and maintenance mode
|
118 |
|
4 |
Tags: maintenance mode, coming soon page, coming soon, under construction, launch page, launch, maintenance, construction, offline, unavailable, under construction page, landing page
|
5 |
Requires at least: 3.5.1
|
6 |
Tested up to: 4.7.1
|
7 |
+
Stable tag: 5.0.6
|
8 |
Text Domain: coming-soon
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
113 |
4. Design Page
|
114 |
|
115 |
== Changelog ==
|
116 |
+
= 5.0.6 =
|
117 |
+
* Added wp review request
|
118 |
+
|
119 |
= 5.0.5 =
|
120 |
* Disable REST API while in coming soon and maintenance mode
|
121 |
|
coming-soon.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Coming Soon Page & Maintenance Mode by SeedProd
|
4 |
* Plugin URI: http://www.seedprod.com
|
5 |
* Description: The #1 Coming Soon Page, Under Construction & Maintenance Mode plugin for WordPress.
|
6 |
-
* Version: 5.0.
|
7 |
* Author: SeedProd
|
8 |
* Author URI: http://www.seedprod.com
|
9 |
* Text Domain: coming-soon
|
@@ -86,17 +86,18 @@ function seed_csp4_welcome_screen_do_activation_redirect() {
|
|
86 |
// Global
|
87 |
global $seed_csp4_settings;
|
88 |
|
89 |
-
require_once( 'framework/get-settings.php' );
|
90 |
$seed_csp4_settings = seed_csp4_get_settings();
|
91 |
|
92 |
-
require_once( 'inc/class-seed-csp4.php' );
|
93 |
add_action( 'plugins_loaded', array( 'SEED_CSP4', 'get_instance' ) );
|
94 |
|
95 |
if( is_admin() ) {
|
96 |
// Admin Only
|
97 |
-
|
98 |
-
require_once( 'framework/framework.php' );
|
99 |
add_action( 'plugins_loaded', array( 'SEED_CSP4_ADMIN', 'get_instance' ) );
|
|
|
100 |
} else {
|
101 |
// Public only
|
102 |
|
@@ -104,3 +105,5 @@ if( is_admin() ) {
|
|
104 |
|
105 |
|
106 |
|
|
|
|
3 |
* Plugin Name: Coming Soon Page & Maintenance Mode by SeedProd
|
4 |
* Plugin URI: http://www.seedprod.com
|
5 |
* Description: The #1 Coming Soon Page, Under Construction & Maintenance Mode plugin for WordPress.
|
6 |
+
* Version: 5.0.6
|
7 |
* Author: SeedProd
|
8 |
* Author URI: http://www.seedprod.com
|
9 |
* Text Domain: coming-soon
|
86 |
// Global
|
87 |
global $seed_csp4_settings;
|
88 |
|
89 |
+
require_once( SEED_CSP4_PLUGIN_PATH.'framework/get-settings.php' );
|
90 |
$seed_csp4_settings = seed_csp4_get_settings();
|
91 |
|
92 |
+
require_once( SEED_CSP4_PLUGIN_PATH.'inc/class-seed-csp4.php' );
|
93 |
add_action( 'plugins_loaded', array( 'SEED_CSP4', 'get_instance' ) );
|
94 |
|
95 |
if( is_admin() ) {
|
96 |
// Admin Only
|
97 |
+
require_once( SEED_CSP4_PLUGIN_PATH.'inc/config-settings.php' );
|
98 |
+
require_once( SEED_CSP4_PLUGIN_PATH.'framework/framework.php' );
|
99 |
add_action( 'plugins_loaded', array( 'SEED_CSP4_ADMIN', 'get_instance' ) );
|
100 |
+
require_once( SEED_CSP4_PLUGIN_PATH.'framework/review.php' );
|
101 |
} else {
|
102 |
// Public only
|
103 |
|
105 |
|
106 |
|
107 |
|
108 |
+
|
109 |
+
|
framework/framework.php
CHANGED
@@ -317,8 +317,45 @@ class SEED_CSP4_ADMIN
|
|
317 |
|
318 |
|
319 |
|
320 |
-
<a href="https://www.seedprod.com/ultimate-coming-soon-page-vs-coming-soon-pro/?utm_source=coming-soon-plugin&utm_medium=banner&utm_campaign=coming-soon-banner-in-plugin" target="_blank"><img src="<?php echo SEED_CSP4_PLUGIN_URL; ?>framework/coming-soon-pro-sidebar.png" /></a>
|
321 |
-
<br><br>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
322 |
<div class="postbox ">
|
323 |
<div class="handlediv" title="Click to toggle"><br /></div>
|
324 |
<h3 class="hndle"><span><i class="fa fa-question-circle"></i> <?php _e('Plugin Support', 'coming-soon') ?></span></h3>
|
@@ -336,7 +373,7 @@ class SEED_CSP4_ADMIN
|
|
336 |
</div>
|
337 |
</div>
|
338 |
|
339 |
-
|
340 |
<div class="handlediv" title="Click to toggle"><br /></div>
|
341 |
<h3 class="hndle"><span><i class="fa fa-heart"></i> <?php _e('Show Some Love', 'coming-soon') ?></span></h3>
|
342 |
<div class="inside">
|
@@ -350,7 +387,7 @@ class SEED_CSP4_ADMIN
|
|
350 |
</ul>
|
351 |
</div>
|
352 |
</div>
|
353 |
-
</div>
|
354 |
|
355 |
|
356 |
|
317 |
|
318 |
|
319 |
|
320 |
+
<!-- <a href="https://www.seedprod.com/ultimate-coming-soon-page-vs-coming-soon-pro/?utm_source=coming-soon-plugin&utm_medium=banner&utm_campaign=coming-soon-banner-in-plugin" target="_blank"><img src="<?php echo SEED_CSP4_PLUGIN_URL; ?>framework/coming-soon-pro-sidebar.png" /></a>
|
321 |
+
<br><br> -->
|
322 |
+
|
323 |
+
|
324 |
+
<div class="postbox " style="background-color:#FAE6A4;color:#734726 !important; border-color:#734726 !important">
|
325 |
+
<div class="handlediv" title="Click to toggle"><br /></div>
|
326 |
+
<h3 class="hndle" style="color:#fff !important;border-color:#734726 !important; background-color:#734726"><span><i class="fa fa-star"></i> <?php _e('Yo-Yo-Yo, Why Go Pro?', 'coming-soon') ?></span></h3>
|
327 |
+
<div class="inside">
|
328 |
+
<div class="support-widget">
|
329 |
+
<!-- <p>
|
330 |
+
<?php _e("I'd love for you to check out what's in the Pro Version with this video Walk Through.",'coming-soon') ?>
|
331 |
+
</p> -->
|
332 |
+
<!-- <iframe width="250" height="188" src="https://www.youtube.com/embed/aMSPV4iY6Tc?rel=0" frameborder="0" allowfullscreen=""></iframe> -->
|
333 |
+
<ul>
|
334 |
+
|
335 |
+
<li><i class="fa fa-check"></i> <strong>Realtime Page Customizer</strong></li>
|
336 |
+
<li><i class="fa fa-check"></i> <strong>More Design Controls and Widgets</strong></li>
|
337 |
+
<li><i class="fa fa-check"></i> <strong>Pre Made Themes</strong></li>
|
338 |
+
<li><i class="fa fa-check"></i> <strong>1000's of Free Stock Images</strong></li>
|
339 |
+
<li><i class="fa fa-check"></i> <strong>Collect Emails (MailChimp, Database and other integrations)
|
340 |
+
</strong></li>
|
341 |
+
<li><i class="fa fa-check"></i> <strong>Go Viral with Social Media Integrations
|
342 |
+
</strong></li>
|
343 |
+
<li><i class="fa fa-check"></i> <strong>Shortcode Support, Google Font Support, Background Slideshow and Videos
|
344 |
+
</strong></li>
|
345 |
+
|
346 |
+
<li><i class="fa fa-check"></i> <strong>Give clients Instant Access with a Bypass Link
|
347 |
+
</strong></li>
|
348 |
+
<li><hr style=" border-top: 1px solid #734726; border-bottom: none"></li>
|
349 |
+
<li><strong>Plus lots more!</strong></li>
|
350 |
+
</ul>
|
351 |
+
<p>
|
352 |
+
<a class="button-primary" style="background-color:#05AE0E; border-color:#05AE0E; box-shadow:none; text-shadow: none; width:100%; text-align:center;" href="https://www.seedprod.com/ultimate-coming-soon-page-vs-coming-soon-pro/?utm_source=coming-soon-plugin&utm_medium=banner&utm_campaign=coming-soon-banner-in-plugin" target="_blank">See What's In The Pro Version</a>
|
353 |
+
</p>
|
354 |
+
|
355 |
+
</div>
|
356 |
+
</div>
|
357 |
+
</div>
|
358 |
+
|
359 |
<div class="postbox ">
|
360 |
<div class="handlediv" title="Click to toggle"><br /></div>
|
361 |
<h3 class="hndle"><span><i class="fa fa-question-circle"></i> <?php _e('Plugin Support', 'coming-soon') ?></span></h3>
|
373 |
</div>
|
374 |
</div>
|
375 |
|
376 |
+
<!-- <div class="postbox like-postbox">
|
377 |
<div class="handlediv" title="Click to toggle"><br /></div>
|
378 |
<h3 class="hndle"><span><i class="fa fa-heart"></i> <?php _e('Show Some Love', 'coming-soon') ?></span></h3>
|
379 |
<div class="inside">
|
387 |
</ul>
|
388 |
</div>
|
389 |
</div>
|
390 |
+
</div> -->
|
391 |
|
392 |
|
393 |
|
framework/review.php
ADDED
@@ -0,0 +1,108 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
// Review Request
|
4 |
+
add_action( 'admin_footer_text', 'seed_csp4_admin_footer' );
|
5 |
+
|
6 |
+
function seed_csp4_admin_footer( $text ) {
|
7 |
+
global $current_screen;
|
8 |
+
$review = get_option( 'seed_csp4_review' );
|
9 |
+
if ( isset( $review['dismissed'] ) && $review['dismissed']){
|
10 |
+
return $text;
|
11 |
+
}
|
12 |
+
|
13 |
+
if ( !empty( $current_screen->id ) && strpos( $current_screen->id, 'settings_page_seed_csp4' ) !== false ) {
|
14 |
+
|
15 |
+
$url = 'https://wordpress.org/support/plugin/coming-soon/reviews/?filter=5#new-post';
|
16 |
+
$text = sprintf( __( 'Please rate <strong>Coming Soon Page & Maintenance Mode by SeedProd</strong> <a href="%s" target="_blank">★★★★★</a> on <a href="%s" target="_blank">WordPress.org</a> to help us spread the word. Thank you from the SeedProd team!', 'coming-soon' ), $url, $url );
|
17 |
+
}
|
18 |
+
return $text;
|
19 |
+
}
|
20 |
+
|
21 |
+
add_action( 'admin_notices', 'seed_csp4_review' );
|
22 |
+
function seed_csp4_review() {
|
23 |
+
|
24 |
+
// Verify that we can do a check for reviews.
|
25 |
+
|
26 |
+
$review = get_option( 'seed_csp4_review' );
|
27 |
+
$time = time();
|
28 |
+
$load = false;
|
29 |
+
$settings = seed_csp4_get_settings();
|
30 |
+
|
31 |
+
|
32 |
+
if ( ! $review ) {
|
33 |
+
$review = array(
|
34 |
+
'time' => $time,
|
35 |
+
'dismissed' => false
|
36 |
+
);
|
37 |
+
$load = true;
|
38 |
+
} else {
|
39 |
+
// Check if it has been dismissed or not.
|
40 |
+
if ( (isset( $review['dismissed'] ) && ! $review['dismissed']) && (isset( $review['time'] ) && (($review['time'] + DAY_IN_SECONDS) <= $time) && $settings['status'] > 0) ) {
|
41 |
+
$load = true;
|
42 |
+
}
|
43 |
+
}
|
44 |
+
|
45 |
+
|
46 |
+
// If we cannot load, return early.
|
47 |
+
if ( ! $load ) {
|
48 |
+
return;
|
49 |
+
}
|
50 |
+
|
51 |
+
// Update the review option now.
|
52 |
+
update_option( 'seed_csp4_review', $review );
|
53 |
+
|
54 |
+
$current_user = wp_get_current_user();
|
55 |
+
$fname = '';
|
56 |
+
if(!empty($current_user->user_firstname)){
|
57 |
+
$fname = $current_user->user_firstname;
|
58 |
+
}
|
59 |
+
|
60 |
+
$page_type = 'Coming Soon Page';
|
61 |
+
if(!empty($settings['status']) && $settings['status'] == 2){
|
62 |
+
$page_type = 'Maintenance Mode Page';
|
63 |
+
}
|
64 |
+
|
65 |
+
|
66 |
+
// We have a candidate! Output a review message.
|
67 |
+
?>
|
68 |
+
<div class="notice notice-info is-dismissible seed-csp4-review-notice">
|
69 |
+
<p><?php printf(__( 'Hey %s, I noticed you created a %s with our plugin - that’s awesome! Could you please do me a BIG favor and give it a 5-star rating on WordPress to help us spread the word?', 'coming-soon' ),$fname, $page_type); ?></p>
|
70 |
+
<p><strong><?php _e( '~ John Turner<br>SeedProd', 'coming-soon' ); ?></strong></p>
|
71 |
+
<p>
|
72 |
+
<a href="https://wordpress.org/support/plugin/coming-soon/reviews/?filter=5#new-post" class="seed-csp4-dismiss-review-notice seed-csp4-review-out" target="_blank" rel="noopener"><?php _e( 'Ok, you deserve it', 'coming-soon' ); ?></a><br>
|
73 |
+
<a href="#" class="seed-csp4-dismiss-review-notice" target="_blank" rel="noopener"><?php _e( 'Nope, maybe later', 'coming-soon' ); ?></a><br>
|
74 |
+
<a href="#" class="seed-csp4-dismiss-review-notice" target="_blank" rel="noopener"><?php _e( 'I already did', 'coming-soon' ); ?></a><br>
|
75 |
+
</p>
|
76 |
+
</div>
|
77 |
+
<script type="text/javascript">
|
78 |
+
jQuery(document).ready( function($) {
|
79 |
+
$(document).on('click', '.seed-csp4-dismiss-review-notice, .seed-csp4-review-notice .notice-dismiss', function( event ) {
|
80 |
+
if ( ! $(this).hasClass('seed-csp4-review-out') ) {
|
81 |
+
event.preventDefault();
|
82 |
+
}
|
83 |
+
|
84 |
+
$.post( ajaxurl, {
|
85 |
+
action: 'seed_csp4_dismiss_review'
|
86 |
+
});
|
87 |
+
|
88 |
+
$('.seed-csp4-review-notice').remove();
|
89 |
+
});
|
90 |
+
});
|
91 |
+
</script>
|
92 |
+
<?php
|
93 |
+
}
|
94 |
+
|
95 |
+
add_action( 'wp_ajax_seed_csp4_dismiss_review', 'seed_csp4_dismiss_review' );
|
96 |
+
function seed_csp4_dismiss_review() {
|
97 |
+
|
98 |
+
$review = get_option( 'seed_csp4_review' );
|
99 |
+
if ( ! $review ) {
|
100 |
+
$review = array();
|
101 |
+
}
|
102 |
+
|
103 |
+
$review['time'] = time();
|
104 |
+
$review['dismissed'] = true;
|
105 |
+
|
106 |
+
update_option( 'seed_csp4_review', $review );
|
107 |
+
die;
|
108 |
+
}
|
inc/class-seed-csp4.php
CHANGED
@@ -181,6 +181,7 @@ class SEED_CSP4{
|
|
181 |
// Finally check if we should show the coming soon page.
|
182 |
$this->comingsoon_rendered = true;
|
183 |
|
|
|
184 |
// set headers
|
185 |
if($status == '2'){
|
186 |
header('HTTP/1.1 503 Service Temporarily Unavailable');
|
181 |
// Finally check if we should show the coming soon page.
|
182 |
$this->comingsoon_rendered = true;
|
183 |
|
184 |
+
|
185 |
// set headers
|
186 |
if($status == '2'){
|
187 |
header('HTTP/1.1 503 Service Temporarily Unavailable');
|