Plugin Directory

Changeset 3248667


Ignore:
Timestamp:
02/28/2025 06:46:17 PM (12 months ago)
Author:
expresstech
Message:

10.0.1 to trunk

Location:
quiz-master-next/trunk
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • quiz-master-next/trunk/css/admin-dashboard-rtl.css

    r3248261 r3248667  
    9292}
    9393
    94 .changelog-ul li .bug {
     94.changelog-ul li .bug, .changelog-ul li .hotfix {
    9595    background: #fe2525;
    9696}
  • quiz-master-next/trunk/css/admin-dashboard.css

    r3248261 r3248667  
    126126}
    127127
    128 .changelog-ul li .bug {
     128.changelog-ul li .bug, .changelog-ul li .hotfix {
    129129    background: #FCE7F3;
    130130    color: #92400E;
     
    136136}
    137137
    138 .changelog-ul li span.bug:before {
     138.changelog-ul li span.bug:before, .changelog-ul li span.hotfix:before {
    139139    background: #9D174D;
    140140}
  • quiz-master-next/trunk/css/qsm-admin.css

    r3248261 r3248667  
    50975097    margin: 20px auto;
    50985098}
     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}
    50995106.qsm-dashboard-error-content div.error {
    51005107    display: none;
    51015108}
    5102 .qsm-dashboard-error-content h2 {
     5109.qsm-dashboard-error-content h3 {
    51035110    font-size: 18px;
    51045111    color: #D43838;
  • quiz-master-next/trunk/data/templates.json

    r3248261 r3248667  
    66    "template_preview": "competitions-quiz.png",
    77    "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>"
    99  },
    1010  {
     
    5353    "template_preview": "competitions-quiz.png",
    5454    "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>"
    5656  },
    5757  {
  • quiz-master-next/trunk/js/qsm-admin.js

    r3248261 r3248667  
    929929                const selectedTemplateId = templateWrap.find('.qsm-to-replace-page-template').val();
    930930                const uniqueId = button.data('id');
    931                 const editor = tinymce.get('results-page-' + (uniqueId));
    932931                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               
    933938                const templateContent = editor.getContent().trim();
    934939                const isReplace = jQuery('input[name="qsm-template-action"]:checked').val() === 'replace';
     
    10081013            jQuery(document).on('click', '.qsm-insert-page-template-anchor', function (e) {
    10091014                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                }
    10101019                jQuery('.qsm-settings-box-details, .qsm-more-settings-box-details').hide();
    10111020                if (!templateWrap.is(':visible')) {
  • quiz-master-next/trunk/mlw_quizmaster2.php

    r3248261 r3248667  
    33 * Plugin Name: Quiz And Survey Master
    44 * Description: Easily and quickly add quizzes and surveys to your website.
    5  * Version: 10.0.0
     5 * Version: 10.0.1
    66 * Author: ExpressTech
    77 * Author URI: https://quizandsurveymaster.com/
     
    4444     * @since 4.0.0
    4545     */
    46     public $version = '10.0.0';
     46    public $version = '10.0.1';
    4747
    4848    /**
     
    12601260            <?php
    12611261        }
    1262         qsm_check_plugins_compatibility();
    12631262    }
    12641263}
  • quiz-master-next/trunk/php/admin/admin-dashboard.php

    r3248261 r3248667  
    5050    if ( $hidden_box && is_array( $hidden_box ) ) {
    5151        echo in_array( $widget_id, $hidden_box, true ) ? ' hide-if-js' : '';
     52    }
     53}
     54
     55function 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        }
    5277    }
    5378}
     
    6186    if ( $wp_filesystem->exists( $readme_file ) ) {
    6287        $file_content = $wp_filesystem->get_contents( $readme_file );
     88
    6389        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            }
    6797        }
    6898    }
     
    268298                $popular_addons = isset($qsm_admin_dd['popular_products']) ? $qsm_admin_dd['popular_products'] : [];
    269299                $themes = isset($qsm_admin_dd['themes']) ? $qsm_admin_dd['themes'] : [];
     300                qsm_check_plugins_compatibility();
    270301                qsm_dashboard_display_need_help_section();
    271302                qsm_dashboard_display_popular_addon_section($popular_addons);
  • quiz-master-next/trunk/php/admin/functions.php

    r3248261 r3248667  
    15211521            "description"  => __( 'Enhance your quizzes with seamless integrations using the QSM Webhooks Addon.', 'quiz-master-next' ),
    15221522            "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' ),
    15241524            "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' ),
    15251525            "buy_btn_text" => __( 'Buy Webhooks Addon', 'quiz-master-next' ),
     
    18061806        return;
    18071807    }
    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    ?>
    18091827    <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>
    18101828    <?php
     
    19601978    <div id="qsm-dashboard-error-container">
    19611979        <div class="qsm-dashboard-error-content">
    1962             <h2><?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>
    19631981            <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>
    19641982            <ul>
     
    19731991    <?php
    19741992}
    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.0
    1984         if ( isset( $plugin_data['Version'] ) && version_compare( $plugin_data['Version'], '2.0.0', '<' ) ) {
    1985             ?>
    1986             <div class="notice notice-error">
    1987                 <p>
    1988                     <?php
    1989                     $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_url
    1996                         ),
    1997                         array(
    1998                             'a' => array(
    1999                                 'href'   => array(),
    2000                                 'target' => array(),
    2001                                 'rel'    => array(),
    2002                             ),
    2003                         )
    2004                     );
    2005                     ?>
    2006                 </p>
    2007             </div>
    2008             <?php
    2009         }
    2010     }
    2011 }
  • quiz-master-next/trunk/readme.txt

    r3248261 r3248667  
    55Tested up to: 6.7
    66Requires PHP: 5.4
    7 Stable tag: 10.0.0
     7Stable tag: 10.0.1
    88License: GPLv2
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    222222
    223223== Changelog ==
     224= 10.0.1 ( March 01, 2025 ) =
     225* Hotfix: Resolved JS warning while saving email template
     226
    224227= 10.0.0 ( Fabuary 28, 2025 ) =
    225228* Feature: Added options to import and create email and result templates
Note: See TracChangeset for help on using the changeset viewer.