Changeset 2478250
- Timestamp:
- 02/21/2021 04:04:12 AM (5 years ago)
- Location:
- simple-alert-system/trunk
- Files:
-
- 4 edited
-
alert.php (modified) (2 diffs)
-
controls/sas-settings.php (modified) (4 diffs)
-
index.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
simple-alert-system/trunk/alert.php
r2443304 r2478250 2 2 3 3 // Define varibale 4 $bgcolor = $simple_alert_system_options = $setColor = $ftColor = $alert_link = $sas_schedule_start_date = $sas_schedule_end_date = $today = $run_sas_alert = $ctaBg = $ctaftColor = $post_slug = $scopeArray = $selected = $scopeRange = $pageInclusive = $sas_active_theme = $ctaValue = "";4 $bgcolor = $simple_alert_system_options = $setColor = $ftColor = $alert_link = $sas_schedule_start_date = $sas_schedule_end_date = $today = $run_sas_alert = $ctaBg = $ctaftColor = $post_slug = $scopeArray = $selected = $scopeRange = $pageInclusive = $sas_active_theme = $ctaValue = $publicDisplay = ""; 5 5 6 6 $simple_alert_system_options = get_option( 'simple_alert_system_option_name' ); … … 58 58 $run_sas_alert === "yes" && 59 59 $pageInclusive === "YES" ) { 60 $publicDisplay = "YES"; 61 62 } 63 64 if(($publicDisplay === "YES") || is_admin()) { 60 65 61 66 $bgcolor = $simple_alert_system_options[ 'background_0' ]; -
simple-alert-system/trunk/controls/sas-settings.php
r2443304 r2478250 56 56 </style> 57 57 <h1 class="sas_title">Simple Alert System</h1> 58 <script> 59 60 // Wait for document to be ready 61 jQuery(function(){ 62 jQuery(".switch.livePreview [type='checkbox']").on("change", function() { 63 var showPreview = "showPreview"; 64 jQuery(".button.button-primary").trigger("click"); 65 }); 66 67 }); 68 69 70 71 </script> 58 72 <?php 59 73 // Show alert Preview if the setting is enabled 60 74 $simple_alert_system_options = get_option( 'simple_alert_system_option_name' ); 61 if ( !empty( $simple_alert_system_options[ 'enable_preview' ] ) ) {75 if ( !empty( $simple_alert_system_options[ 'enable_preview' ] ) || isset( $_COOKIE[ "sas_preview_alert" ] ) ) { 62 76 ?> 63 77 <div> … … 75 89 76 90 ?> 77 </form>78 <?php $seo_pyramid_ready_message = 'Note: If you enable the customization section, its settings will override all default settings.'; ?>79 <div class="sas_notice">91 </form> 92 <?php $seo_pyramid_ready_message = 'Note: If you enable the customization section, its settings will override all default settings.'; ?> 93 <div class="sas_notice"> 80 94 <?php printf( __( '%s', 'seo-pyramid' ), $seo_pyramid_ready_message ); ?> 81 </div>82 <script>95 </div> 96 <script> 83 97 // Instantenious Preview script 84 98 jQuery(function () { … … 483 497 484 498 485 '<label class="switch "><input type="checkbox" name="simple_alert_system_option_name[enable_alert]" id="tenable_alert" value="enable_alert" %s><span class="slider round"></span></label>',499 '<label class="switch "><input type="checkbox" name="simple_alert_system_option_name[enable_alert]" id="tenable_alert" value="enable_alert" %s><span class="slider round"></span></label>', 486 500 487 501 … … 501 515 502 516 503 '<label class="switch "><input type="checkbox" name="simple_alert_system_option_name[enable_preview]" id="tenable_alert" value="enable_preview" %s><span class="slider round"></span></label>',517 '<label class="switch livePreview"><input type="checkbox" name="simple_alert_system_option_name[enable_preview]" id="tenable_alert" value="enable_preview" %s><span class="slider round"></span></label>', 504 518 505 519 -
simple-alert-system/trunk/index.php
r2443304 r2478250 8 8 * Description: Simplified website alert system for WordPress. 9 9 10 * Version: 1. 1.910 * Version: 1.2.0 11 11 12 12 * Author: Chibueze Okechukwu -
simple-alert-system/trunk/readme.txt
r2443304 r2478250 6 6 Tested up to: 5.6 7 7 Requires PHP: 5.0 8 Stable tag: 1. 1.98 Stable tag: 1.2.0 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 92 92 93 93 ### 1.1.9 94 This update was facilitated to fix the need for users to enable public alerts before seeing a live preview in the backend. The "Enable Preview button can now be used to toggle the live preview feature. 95 96 ### 1.1.9 94 97 This update includes but is not limited to code enhancements, U.I enhancements, and the introduction of a live preview feature to enable users to see a replica of the alert within the settings window. 95 98
Note: See TracChangeset
for help on using the changeset viewer.