Changeset 3248667
- Timestamp:
- 02/28/2025 06:46:17 PM (12 months ago)
- Location:
- quiz-master-next/trunk
- Files:
-
- 9 edited
-
css/admin-dashboard-rtl.css (modified) (1 diff)
-
css/admin-dashboard.css (modified) (2 diffs)
-
css/qsm-admin.css (modified) (1 diff)
-
data/templates.json (modified) (2 diffs)
-
js/qsm-admin.js (modified) (2 diffs)
-
mlw_quizmaster2.php (modified) (3 diffs)
-
php/admin/admin-dashboard.php (modified) (3 diffs)
-
php/admin/functions.php (modified) (4 diffs)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
quiz-master-next/trunk/css/admin-dashboard-rtl.css
r3248261 r3248667 92 92 } 93 93 94 .changelog-ul li .bug {94 .changelog-ul li .bug, .changelog-ul li .hotfix { 95 95 background: #fe2525; 96 96 } -
quiz-master-next/trunk/css/admin-dashboard.css
r3248261 r3248667 126 126 } 127 127 128 .changelog-ul li .bug {128 .changelog-ul li .bug, .changelog-ul li .hotfix { 129 129 background: #FCE7F3; 130 130 color: #92400E; … … 136 136 } 137 137 138 .changelog-ul li span.bug:before {138 .changelog-ul li span.bug:before, .changelog-ul li span.hotfix:before { 139 139 background: #9D174D; 140 140 } -
quiz-master-next/trunk/css/qsm-admin.css
r3248261 r3248667 5097 5097 margin: 20px auto; 5098 5098 } 5099 .qsm-dashboard-warning-container { 5100 background: #fff4d2; 5101 border: 1px solid #FFF2EF; 5102 padding: 30px 20px; 5103 border-radius: 6px; 5104 margin: 20px auto; 5105 } 5099 5106 .qsm-dashboard-error-content div.error { 5100 5107 display: none; 5101 5108 } 5102 .qsm-dashboard-error-content h 2{5109 .qsm-dashboard-error-content h3 { 5103 5110 font-size: 18px; 5104 5111 color: #D43838; -
quiz-master-next/trunk/data/templates.json
r3248261 r3248667 6 6 "template_preview": "competitions-quiz.png", 7 7 "dependency": "1903", 8 "template_content": "<div style=background:linear-gradient(180deg,#3d0072,#4e005f,#6e0068);padding:20px;min-height:100vh><div style=\"max-width:800px;margin:0 auto\"><div style=\"margin:20px 0;font-size:100px;line-height:1;color:#ffc107;text-align:center\">🏆</div><h1 style=color:#ffc107;text-align:center>Excellent <qsmvariabletag>USER_NAME</qsmvariabletag>! You Nailed It!</h1><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:30px><table style=\"max-width:500px;border-collapse:collapse;text-align:center;margin:0 auto\"><tr><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;background:#00c851;color:#fff;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;margin:0 auto\"><qsmvariabletag>AMOUNT_CORRECT</qsmvariabletag></div><span style=margin-top:8px>Right Answer</span></td><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;background:#f35252;color:#fff;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;margin:0 auto\"><qsmvariabletag>AMOUNT_INCORRECT</qsmvariabletag></div><span style=margin-top:8px>Wrong Answer</span></td><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;border:2px dashed #ffc107;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;color:#ffc107;margin:0 auto\"><qsmvariabletag>POINT_SCORE</qsmvariabletag></div><span style=margin-top:8px>Points</span></td></tr></table></div><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:20px><h2 style=color:#ffc107;text-align:center>Leaderboard</h2>[qsm_leaderboard ranks=\"10\" order=\"point_score_asc\" average=\"false\" days=\"0\"]</div><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:20px><h2 style=color:#ffc107;text-align:center>Your Answers</h2><p><qsmvariabletag>QUESTIONS_ANSWERS</qsmvariabletag></div><div style=text-align:center><a href=\"%QUIZ_LINK%\" style=\"text-decoration:none;background:#ffc107;color:#4b015f;border:none;padding:10px 20px;border-radius:25px;font-size:18px;font-weight:700;cursor:pointer;margin:0 auto;width:100%\">⟳ Replay</a></div></div></div>"8 "template_content": "<div style=background:linear-gradient(180deg,#3d0072,#4e005f,#6e0068);padding:20px;min-height:100vh><div style=\"max-width:800px;margin:0 auto\"><div style=\"margin:20px 0;font-size:100px;line-height:1;color:#ffc107;text-align:center\">🏆</div><h1 style=color:#ffc107;text-align:center>Excellent <qsmvariabletag>USER_NAME</qsmvariabletag>! You Nailed It!</h1><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:30px><table style=\"max-width:500px;border-collapse:collapse;text-align:center;margin:0 auto\"><tr><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;background:#00c851;color:#fff;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;margin:0 auto\"><qsmvariabletag>AMOUNT_CORRECT</qsmvariabletag></div><span style=margin-top:8px>Right Answer</span></td><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;background:#f35252;color:#fff;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;margin:0 auto\"><qsmvariabletag>AMOUNT_INCORRECT</qsmvariabletag></div><span style=margin-top:8px>Wrong Answer</span></td><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;border:2px dashed #ffc107;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;color:#ffc107;margin:0 auto\"><qsmvariabletag>POINT_SCORE</qsmvariabletag></div><span style=margin-top:8px>Points</span></td></tr></table></div><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:20px><h2 style=color:#ffc107;text-align:center>Leaderboard</h2>[qsm_leaderboard ranks=\"10\" order=\"point_score_asc\" average=\"false\" days=\"0\"]</div><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:20px><h2 style=color:#ffc107;text-align:center>Your Answers</h2><p><qsmvariabletag>QUESTIONS_ANSWERS</qsmvariabletag></div><div style=text-align:center><a href=\"%QUIZ_LINK%\" style=\"text-decoration:none;background:#ffc107;color:#4b015f;border:none;padding:10px 20px;border-radius:25px;font-size:18px;font-weight:700;cursor:pointer;margin:0 auto;width:100%\">⟳ Replay</a></div></div></div>" 9 9 }, 10 10 { … … 53 53 "template_preview": "competitions-quiz.png", 54 54 "dependency": "1903", 55 "template_content": "<div style=background:linear-gradient(180deg,#3d0072,#4e005f,#6e0068);padding:20px;min-height:100vh><div style=\"max-width:800px;margin:0 auto\"><div style=\"margin:20px 0;font-size:100px;line-height:1;color:#ffc107;text-align:center\">🏆</div><h1 style=color:#ffc107;text-align:center>Excellent <qsmvariabletag>USER_NAME</qsmvariabletag>! You Nailed It!</h1><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:30px><table style=\"max-width:500px;border-collapse:collapse;text-align:center;margin:0 auto\"><tr><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;background:#00c851;color:#fff;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;margin:0 auto\"><qsmvariabletag>AMOUNT_CORRECT</qsmvariabletag></div><span style=margin-top:8px>Right Answer</span></td><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;background:#f35252;color:#fff;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;margin:0 auto\"><qsmvariabletag>AMOUNT_INCORRECT</qsmvariabletag></div><span style=margin-top:8px>Wrong Answer</span></td><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;border:2px dashed #ffc107;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;color:#ffc107;margin:0 auto\"><qsmvariabletag>POINT_SCORE</qsmvariabletag></div><span style=margin-top:8px>Points</span></td></tr></table></div><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:20px><h2 style=color:#ffc107;text-align:center>Leaderboard</h2>[qsm_leaderboard ranks=\"10\" order=\"point_score_asc\" average=\"false\" days=\"0\"]</div><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:20px><h2 style=color:#ffc107;text-align:center>Your Answers</h2><p><qsmvariabletag>QUESTIONS_ANSWERS</qsmvariabletag></div><div style=text-align:center><a href='<qsmvariabletag>QUIZ_LINK</qsmvariabletag>' style=\"text-decoration:none;background:#ffc107;color:#4b015f;border:none;padding:10px 20px;border-radius:25px;font-size:18px;font-weight:700;cursor:pointer;margin:0 auto;width:100%\">⟳ Replay</a></div></div></div>"55 "template_content": "<div style=background:linear-gradient(180deg,#3d0072,#4e005f,#6e0068);padding:20px;min-height:100vh><div style=\"max-width:800px;margin:0 auto\"><div style=\"margin:20px 0;font-size:100px;line-height:1;color:#ffc107;text-align:center\">🏆</div><h1 style=color:#ffc107;text-align:center>Excellent <qsmvariabletag>USER_NAME</qsmvariabletag>! You Nailed It!</h1><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:30px><table style=\"max-width:500px;border-collapse:collapse;text-align:center;margin:0 auto\"><tr><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;background:#00c851;color:#fff;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;margin:0 auto\"><qsmvariabletag>AMOUNT_CORRECT</qsmvariabletag></div><span style=margin-top:8px>Right Answer</span></td><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;background:#f35252;color:#fff;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;margin:0 auto\"><qsmvariabletag>AMOUNT_INCORRECT</qsmvariabletag></div><span style=margin-top:8px>Wrong Answer</span></td><td style=padding:10px;vertical-align:middle;text-align:center;width:166px><div style=\"width:60px;height:60px;border:2px dashed #ffc107;border-radius:50px;line-height:60px;font-size:20px;font-weight:700;color:#ffc107;margin:0 auto\"><qsmvariabletag>POINT_SCORE</qsmvariabletag></div><span style=margin-top:8px>Points</span></td></tr></table></div><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:20px><h2 style=color:#ffc107;text-align:center>Leaderboard</h2>[qsm_leaderboard ranks=\"10\" order=\"point_score_asc\" average=\"false\" days=\"0\"]</div><div style=background:#fff;border-radius:12px;padding:20px;margin-bottom:20px><h2 style=color:#ffc107;text-align:center>Your Answers</h2><p><qsmvariabletag>QUESTIONS_ANSWERS</qsmvariabletag></div><div style=text-align:center><a href='<qsmvariabletag>QUIZ_LINK</qsmvariabletag>' style=\"text-decoration:none;background:#ffc107;color:#4b015f;border:none;padding:10px 20px;border-radius:25px;font-size:18px;font-weight:700;cursor:pointer;margin:0 auto;width:100%\">⟳ Replay</a></div></div></div>" 56 56 }, 57 57 { -
quiz-master-next/trunk/js/qsm-admin.js
r3248261 r3248667 929 929 const selectedTemplateId = templateWrap.find('.qsm-to-replace-page-template').val(); 930 930 const uniqueId = button.data('id'); 931 const editor = tinymce.get('results-page-' + (uniqueId));932 931 const templateType = button.parents('.qsm-insert-page-template-anchor').data('template-type'); 932 if (templateType == 'result') { 933 var editor = tinymce.get('results-page-' + (uniqueId)); 934 } else if (templateType == 'email') { 935 var editor = tinymce.get('email-template-' + (uniqueId)); 936 } 937 933 938 const templateContent = editor.getContent().trim(); 934 939 const isReplace = jQuery('input[name="qsm-template-action"]:checked').val() === 'replace'; … … 1008 1013 jQuery(document).on('click', '.qsm-insert-page-template-anchor', function (e) { 1009 1014 let templateWrap = jQuery(this).find('.qsm-insert-template-wrap'); 1015 let radioButtons = jQuery(this).find('input[type="radio"][name="qsm-template-action"]'); 1016 if (!radioButtons.is(':checked')) { 1017 radioButtons.filter('[value="new"]').prop('checked', true).trigger('change'); 1018 } 1010 1019 jQuery('.qsm-settings-box-details, .qsm-more-settings-box-details').hide(); 1011 1020 if (!templateWrap.is(':visible')) { -
quiz-master-next/trunk/mlw_quizmaster2.php
r3248261 r3248667 3 3 * Plugin Name: Quiz And Survey Master 4 4 * Description: Easily and quickly add quizzes and surveys to your website. 5 * Version: 10.0. 05 * Version: 10.0.1 6 6 * Author: ExpressTech 7 7 * Author URI: https://quizandsurveymaster.com/ … … 44 44 * @since 4.0.0 45 45 */ 46 public $version = '10.0. 0';46 public $version = '10.0.1'; 47 47 48 48 /** … … 1260 1260 <?php 1261 1261 } 1262 qsm_check_plugins_compatibility();1263 1262 } 1264 1263 } -
quiz-master-next/trunk/php/admin/admin-dashboard.php
r3248261 r3248667 50 50 if ( $hidden_box && is_array( $hidden_box ) ) { 51 51 echo in_array( $widget_id, $hidden_box, true ) ? ' hide-if-js' : ''; 52 } 53 } 54 55 function qsm_check_plugins_compatibility() { 56 global $mlwQuizMasterNext; 57 58 if ( class_exists('QSM_Installer') ) { 59 $plugin_path = WP_PLUGIN_DIR . '/qsm-installer/qsm-installer.php'; 60 $plugin_data = get_plugin_data( $plugin_path ); 61 62 // Check if the plugin version is below 2.0.0 63 if ( isset( $plugin_data['Version'] ) && version_compare( $plugin_data['Version'], '2.0.0', '<' ) ) { 64 $account_url = esc_url( qsm_get_utm_link( 'https://quizandsurveymaster.com/account', 'dashboard', 'useful_links', 'qsm_installer_update' ) ); 65 ?> 66 <div class="qsm-dashboard-help-center qsm-dashboard-warning-container"> 67 <div class="qsm-dashboard-error-content"> 68 <h3><?php esc_html_e('Update Available', 'quiz-master-next'); ?></h3> 69 <p><?php esc_html_e('We recommend downloading the latest version of the QSM Installer for a seamless quiz and survey creation experience.', 'quiz-master-next'); ?></p> 70 <a href="<?php echo esc_url($account_url); ?>" class="qsm-dashboard-error-btn" target="_blank"> 71 <?php esc_html_e('Get Latest QSM Installer', 'quiz-master-next'); ?> 72 </a> 73 </div> 74 </div> 75 <?php 76 } 52 77 } 53 78 } … … 61 86 if ( $wp_filesystem->exists( $readme_file ) ) { 62 87 $file_content = $wp_filesystem->get_contents( $readme_file ); 88 63 89 if ( $file_content ) { 64 $parts = explode( '== Changelog ==', $file_content ); 65 $last_change_log = mlw_qmn_get_string_between( $parts[1], ' =', '= ' ); 66 $change_log = array_filter( explode( '* ', trim( $last_change_log ) ) ); 90 $parts = explode( '== Changelog ==', $file_content, 2 ); 91 if ( isset( $parts[1] ) ) { 92 preg_match_all('/\* (.+)/', $parts[1], $matches); 93 if ( ! empty($matches[1]) ) { 94 $change_log = array_slice($matches[1], 0, 5); 95 } 96 } 67 97 } 68 98 } … … 268 298 $popular_addons = isset($qsm_admin_dd['popular_products']) ? $qsm_admin_dd['popular_products'] : []; 269 299 $themes = isset($qsm_admin_dd['themes']) ? $qsm_admin_dd['themes'] : []; 300 qsm_check_plugins_compatibility(); 270 301 qsm_dashboard_display_need_help_section(); 271 302 qsm_dashboard_display_popular_addon_section($popular_addons); -
quiz-master-next/trunk/php/admin/functions.php
r3248261 r3248667 1521 1521 "description" => __( 'Enhance your quizzes with seamless integrations using the QSM Webhooks Addon.', 'quiz-master-next' ), 1522 1522 "chart_image" => plugins_url( '', dirname( __FILE__ ) ) . '/images/proctor_quiz_chart.png', 1523 "warning" => __( 'Missing Feature - webhook Add- on required', 'quiz-master-next' ),1523 "warning" => __( 'Missing Feature - webhook Add-On required', 'quiz-master-next' ), 1524 1524 "information" => __( 'QSM Addon Bundle is the best way to get all our add-ons at a discount. Upgrade to save 95% today. OR you can buy Webhooks Addon separately.', 'quiz-master-next' ), 1525 1525 "buy_btn_text" => __( 'Buy Webhooks Addon', 'quiz-master-next' ), … … 1806 1806 return; 1807 1807 } 1808 ?> 1808 $active_themes = $mlwQuizMasterNext->theme_settings->get_active_themes(); 1809 1810 if ( empty($active_themes) ) { 1811 return; 1812 } 1813 $pro_themes = array( 'Fortune', 'Sigma', 'Pixel', 'Sapience', 'Breeze', 'Fragrance', 'Pool', 'Ivory' ); 1814 1815 $has_pro_theme = false; 1816 foreach ( $active_themes as $theme ) { 1817 if ( in_array($theme['theme_name'], $pro_themes, true) ) { 1818 $has_pro_theme = true; 1819 break; 1820 } 1821 } 1822 1823 if ( ! $has_pro_theme ) { 1824 return; 1825 } 1826 ?> 1809 1827 <a href="?page=qmn_global_settings&tab=qsm-theme-defaults" class="nav-tab <?php echo ! empty( $_GET['tab'] ) && 'qsm-theme-defaults' === $_GET['tab'] ? 'nav-tab-active' : ''; ?>"><?php esc_html_e( 'Theme Defaults', 'quiz-master-next' ); ?></a> 1810 1828 <?php … … 1960 1978 <div id="qsm-dashboard-error-container"> 1961 1979 <div class="qsm-dashboard-error-content"> 1962 <h 2><?php esc_html_e('Unable To Load Required Data', 'quiz-master-next'); ?></h2>1980 <h3><?php esc_html_e('Unable To Load Required Data', 'quiz-master-next'); ?></h3> 1963 1981 <p><?php esc_html_e('We couldn\'t load the required data, contact our support team for assistance, or you can still create a quiz.', 'quiz-master-next'); ?></p> 1964 1982 <ul> … … 1973 1991 <?php 1974 1992 } 1975 1976 function qsm_check_plugins_compatibility() {1977 global $mlwQuizMasterNext;1978 1979 if ( class_exists('QSM_Installer') ) {1980 $plugin_path = WP_PLUGIN_DIR . '/qsm-installer/qsm-installer.php';1981 $plugin_data = get_plugin_data( $plugin_path );1982 1983 // Check if the plugin version is below 2.0.01984 if ( isset( $plugin_data['Version'] ) && version_compare( $plugin_data['Version'], '2.0.0', '<' ) ) {1985 ?>1986 <div class="notice notice-error">1987 <p>1988 <?php1989 $account_url = esc_url( qsm_get_utm_link( 'https://quizandsurveymaster.com/account', 'dashboard', 'useful_links', 'qsm_installer_update' ) );1990 1991 echo wp_kses(1992 sprintf(1993 /* translators: %s is the URL to the QSM account page */1994 __( 'Please download the latest version of the QSM - Installer from <a href="%s" target="_blank" rel="noopener noreferrer">your account</a>.', 'quiz-master-next' ),1995 $account_url1996 ),1997 array(1998 'a' => array(1999 'href' => array(),2000 'target' => array(),2001 'rel' => array(),2002 ),2003 )2004 );2005 ?>2006 </p>2007 </div>2008 <?php2009 }2010 }2011 } -
quiz-master-next/trunk/readme.txt
r3248261 r3248667 5 5 Tested up to: 6.7 6 6 Requires PHP: 5.4 7 Stable tag: 10.0. 07 Stable tag: 10.0.1 8 8 License: GPLv2 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 222 222 223 223 == Changelog == 224 = 10.0.1 ( March 01, 2025 ) = 225 * Hotfix: Resolved JS warning while saving email template 226 224 227 = 10.0.0 ( Fabuary 28, 2025 ) = 225 228 * Feature: Added options to import and create email and result templates
Note: See TracChangeset
for help on using the changeset viewer.