Plugin Directory

Changeset 2452710


Ignore:
Timestamp:
01/08/2021 03:57:40 PM (5 years ago)
Author:
hqtheme
Message:

Theme setup wizard improvements

Location:
hqtheme-extra
Files:
14 edited
1 copied

Legend:

Unmodified
Added
Removed
  • hqtheme-extra/tags/1.0.7/hqtheme-extra.php

    r2430987 r2452710  
    55 * Plugin URI:        https://marmot.hqwebs.net/marmot/?utm_source=wp-admin&utm_medium=link&utm_campaign=default&utm_term=hqtheme-extra&utm_content=plugin-uri
    66 * Description:       HQTheme Extra adds extras for Marmot Theme - Ready sites one click import
    7  * Version:           1.0.6
     7 * Version:           1.0.7
    88 * Requires at least: 5.3
    99 * Requires PHP:      7.2
    1010 * Author:            HQWebS
    1111 * Author URI:        https://marmot.hqwebs.net/?utm_source=wp-admin&utm_medium=link&utm_campaign=default&utm_term=hqtheme-extra&utm_content=plugin-author
    12  * License:           GPL v2 or later
    13  * License URI:       https://www.gnu.org/licenses/gpl-2.0.html
     12 * License:           GPL v3 or later
     13 * License URI:       https://www.gnu.org/licenses/gpl-3.0.html
    1414 * Text Domain:       hqtheme-extra
    1515 */
     
    5757 * @var string
    5858 */
    59 const VERSION = '1.0.6';
     59const VERSION = '1.0.7';
    6060
    6161// Load Autoloader
  • hqtheme-extra/tags/1.0.7/inc/admin-notifications.php

    r2387081 r2452710  
    112112     * @param int $dismiss_expire
    113113     */
    114     public function add_notice($notice_key, $type, $message, $dismiss, $dismiss_expire = 0) {
     114    public function add_notice($notice_key, $type, $message, $dismiss = 1, $dismiss_expire = 0) {
    115115        global $hq_notices;
    116116
  • hqtheme-extra/tags/1.0.7/inc/admin/page/theme-setup-wizzard.php

    r2430987 r2452710  
    7272                    <?php _ex('Marmot Theme Setup Wizzard will assist you through the initial website setup.', 'admin', 'hqtheme-extra'); ?><br>
    7373                </p>
     74
    7475                <div class="hqt-container">
    7576                    <?php
    76                     $this->header($step);
     77                    $this->display_notices();
     78                    $this->display_steps($step);
    7779
    7880                    switch ($this->wizard_step) {
     
    189191            }
    190192            ?>
    191             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=' . $next_step); ?>" class="btn btn-primary">
     193            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=' . $next_step)); ?>" class="btn btn-primary">
    192194                <?php _ex('Next step', 'admin', 'hqtheme-extra'); ?>
    193195            </a>
     
    208210                <?php _ex('You have to complete previous steps!', 'admin', 'hqtheme-extra'); ?>
    209211            </p>
    210             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1'); ?>" class="btn btn-primary">
     212            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1')); ?>" class="btn btn-primary">
    211213                <?php _ex('Go to uncompleted step', 'admin', 'hqtheme-extra'); ?>
    212214            </a>
     
    225227            <p>
    226228                <?php _ex('You can skip this step, if do not plan to use pro features and demos.', 'admin', 'hqtheme-extra'); ?>
    227                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3&skip-license=1'); ?>">
     229                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3&skip-license=1')); ?>">
    228230                    <?php _ex('Skip this step', 'admin', 'hqtheme-extra'); ?>
    229231                </a>
     
    232234        } else {
    233235            ?>
    234             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3'); ?>" class="btn btn-primary">
     236            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3')); ?>" class="btn btn-primary">
    235237                <?php _ex('Next step', 'admin', 'hqtheme-extra'); ?>
    236238            </a>
     
    269271                <?php _ex('You have to complete previous steps!', 'admin', 'hqtheme-extra'); ?>
    270272            </p>
    271             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=' . (defined('\HQExtra\VERSION') ? $step : 1)); ?>" class="btn btn-primary">
     273            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=' . (defined('\HQExtra\VERSION') ? $step : 1))); ?>" class="btn btn-primary">
    272274                <?php _ex('Go to uncompleted step', 'admin', 'hqtheme-extra'); ?>
    273275            </a>
     
    276278        }
    277279        ?>
    278         <a href="<?php echo admin_url('admin.php?page=marmot-ready-sites'); ?>" class="btn btn-primary mr-1">
     280        <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-ready-sites')); ?>" class="btn btn-primary mr-1">
    279281            <?php _ex('Ready Sites', 'admin', 'hqtheme-extra'); ?>
    280282        </a>
    281         <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4&skip-demo=1'); ?>" class="">
     283        <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4&skip-demo=1')); ?>" class="">
    282284            <?php _ex('Skip this step', 'admin', 'hqtheme-extra'); ?>
    283285        </a>
     
    297299                <?php _ex('You have to complete previous steps!', 'admin', 'hqtheme-extra'); ?>
    298300            </p>
    299             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1'); ?>" class="btn btn-primary">
     301            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1')); ?>" class="btn btn-primary">
    300302                <?php _ex('Go to uncompleted step', 'admin', 'hqtheme-extra'); ?>
    301303            </a>
     
    312314        <p class="m-0"><?php _ex('If you have imported pre-made demo your customization will be very easy.', 'admin', 'hqtheme-extra'); ?></p>
    313315        <p class="m-0"><?php echo sprintf('%1$s <a target="_blank" href="%2$s">%3$s</a>.', _x('Just follow the tutorial', 'admin', 'hqtheme-extra'), 'https://marmot.hqwebs.net/documentation/how-to-edit-header-template/', _x('How to edit header template', 'admin', 'hqtheme-extra')); ?></p>
    314         <p class="mt-0"><?php _ex('All other elements work same way. Go to page -> from Edit with Elementor dropdown choose template and edit.', 'admin', 'hqtheme-extra'); ?></p>
    315         <p class="mb-0"><?php _ex('If you do not use out pre-made website use our documentation to find out how to attach templates.', 'admin', 'hqtheme-extra'); ?></p>
     316        <p class="mt-0"><?php _ex('All other elements work same way. Go to page -> from Edit with Elementor dropdown (you must be logged in as an administrator) choose template and edit.', 'admin', 'hqtheme-extra'); ?></p>
     317        <p class="mb-0"><?php _ex('If you do not use our pre-made website use our documentation to find out how to attach templates.', 'admin', 'hqtheme-extra'); ?></p>
    316318        <p><?php echo sprintf('<a target="_blank" class="btn btn-primary" href="%1$s">%2$s</a>', 'https://marmot.hqwebs.net/documentation/', _x('Full documentation', 'admin', 'hqtheme-extra')); ?></p>
    317319
     
    319321    }
    320322
    321     protected function header($step) {
     323    protected function display_steps($step) {
    322324        ?>
    323325
     
    327329                    <div class="hqt-row">
    328330                        <div class="<?php echo esc_attr($this->getHeaderStepClass(1)) ?>">
    329                             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1'); ?>" class="step-box step-1">
     331                            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1')); ?>" class="step-box step-1">
    330332                                <div class="step">
    331333                                    <span class="step-arrow step-arrow-left"></span>
     
    340342                        <?php if (defined('\WP_FS__DEMO_MODE') && \WP_FS__DEMO_MODE) : ?>
    341343                            <div class="<?php echo esc_attr($this->getHeaderStepClass(3)) ?>">
    342                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3'); ?>" class="step-box step-3">
     344                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3')); ?>" class="step-box step-3">
    343345                                    <div class="step">
    344346                                        <span class="step-arrow step-arrow-left"></span>
     
    352354                            </div>
    353355                            <div class="<?php echo esc_attr($this->getHeaderStepClass(4)) ?>">
    354                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4'); ?>" class="step-box step-4">
     356                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4')); ?>" class="step-box step-4">
    355357                                    <div class="step">
    356358                                        <span class="step-arrow step-arrow-left"></span>
     
    366368                        <?php else : ?>
    367369                            <div class="<?php echo esc_attr($this->getHeaderStepClass(2)) ?>">
    368                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=2'); ?>" class="step-box step-2">
     370                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=2')); ?>" class="step-box step-2">
    369371                                    <div class="step">
    370372                                        <span class="step-arrow step-arrow-left"></span>
     
    378380                            </div>
    379381                            <div class="<?php echo esc_attr($this->getHeaderStepClass(3)) ?>">
    380                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3'); ?>" class="step-box step-3">
     382                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3')); ?>" class="step-box step-3">
    381383                                    <div class="step">
    382384                                        <span class="step-arrow step-arrow-left"></span>
     
    390392                            </div>
    391393                            <div class="<?php echo esc_attr($this->getHeaderStepClass(4)) ?>">
    392                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4'); ?>" class="step-box step-4">
     394                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4')); ?>" class="step-box step-4">
    393395                                    <div class="step">
    394396                                        <span class="step-arrow step-arrow-left"></span>
     
    410412    }
    411413
     414    protected function display_notices() {
     415        $theme = wp_get_theme();
     416       
     417        if ('Marmot' === $theme->name || 'Marmot' !== $theme->parent_theme) {
     418            ?>
     419            <div class="hqt-row border-rad-10 hqt-box-shadow mt-1 mb-4 mx-0 py-3 px-2" style="border-left: solid 4px #2096F3;">
     420                <div class="hqt-col-1-1">
     421                    <h3 class="p-0 mt-0 mb-2"><?php _ex('Not using a child theme?', 'admin', 'hqtheme-extra'); ?></h3>
     422                    <p class="m-0">
     423                        <?php _ex('A child theme allows you to change small aspects of your site`s appearance yet still preserve your theme’s look and functionality. It protects your changes to be overwritten on update of main theme.', 'admin', 'hqtheme-extra'); ?>
     424                    </p>
     425                    <p class="mt-0 mb-3">
     426                        <?php echo sprintf('<a href="%1$s" target="_blank">%2$s</a> %3$s', 'https://developer.wordpress.org/themes/advanced-topics/child-themes/', _x('Learn more', 'admin', 'hqtheme-extra'), _x('what is a child theme and how it works.', 'admin', 'hqtheme-extra')); ?>
     427                    </p>
     428                    <a href="https://github.com/hqwebs/marmot-theme-child/releases/download/1.0.0/marmot-theme-child.zip" class="btn btn-primary mr-1"><?php _ex('Download Marmot Child', 'admin', 'hqtheme-extra'); ?></a>
     429                </div>
     430            </div>
     431            <?php
     432        }
     433    }
     434
    412435    private function getHeaderStepClass($step) {
    413436        $classes = ['hqt-col-1-4 mb-3'];
  • hqtheme-extra/tags/1.0.7/inc/hqlib/helper.php

    r2400862 r2452710  
    336336                            <?php if (!empty($require['link'])) : ?>
    337337                                <div class="ml-2">
    338                                     <a href="<?php echo admin_url($require['link']); ?>">Settings</a>
     338                                    <a href="<?php echo esc_url(admin_url($require['link'])); ?>">Settings</a>
    339339                                </div>
    340340                            <?php endif; ?>
     
    359359                            <?php if (!empty($require['link'])) : ?>
    360360                                <div class="ml-2">
    361                                     <a href="<?php echo admin_url($require['link']); ?>">Settings</a>
     361                                    <a href="<?php echo esc_url(admin_url($require['link'])); ?>">Settings</a>
    362362                                </div>
    363363                            <?php endif; ?>
  • hqtheme-extra/tags/1.0.7/inc/hqlib/license.php

    r2430987 r2452710  
    202202                    <h2 class="mt-0 mb-3"><?php _ex('You\'re ready to go!', 'license info', 'hqtheme-extra'); ?></h2>
    203203                    <p class="mt-0 mb-2"><?php _ex('Start building your website like a Pro! Enjoy all the premium features - import awesome templates with a click, create stunning popups, attach custom headers and footers on each page, use advanced widgets for Elementor with <b>Dynamic Tags</b>, create unique WooCommerce checkout flow and more, and more...', 'license info', 'hqtheme-extra'); ?></p>
    204                     <a href="<?php echo admin_url('admin.php?page=marmot'); ?>" class="btn btn-border mt-3"><?php _ex('Start Using Premium Features', 'license info', 'hqtheme-extra'); ?></a>
    205                     <a href="<?php echo admin_url('admin.php?page=marmot-ready-sites'); ?>" class="btn btn-danger-border mt-3 ml-2"><?php _ex('Import Demo', 'license info', 'hqtheme-extra'); ?></a>
     204                    <a href="<?php echo esc_url(admin_url('admin.php?page=marmot')); ?>" class="btn btn-border mt-3"><?php _ex('Start Using Premium Features', 'license info', 'hqtheme-extra'); ?></a>
     205                    <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-ready-sites')); ?>" class="btn btn-danger-border mt-3 ml-2"><?php _ex('Import Demo', 'license info', 'hqtheme-extra'); ?></a>
    206206
    207207                    <?php
  • hqtheme-extra/tags/1.0.7/inc/menu.php

    r2400862 r2452710  
    4242    private function __construct() {
    4343        add_action('init', [$this, 'registerPosttype'], 50, 0);
     44
     45        add_action('admin_enqueue_scripts', [$this, 'load_admin_assets'], 10);
    4446    }
    4547
     
    7072    }
    7173
     74    /**
     75     * Fix Clever menu
     76     *
     77     * @since 1.0.6
     78     */
     79    public function load_admin_assets() {
     80        // Fix Clever Menu in Customizer
     81        wp_localize_script('cmm4e-admin', 'cleverMenuItems', []);
     82    }
     83
    7284}
  • hqtheme-extra/tags/1.0.7/readme.txt

    r2430987 r2452710  
    55Tested up to: 5.5
    66Requires PHP: 7.2
    7 Stable tag: 1.0.6
     7Stable tag: 1.0.7
    88License: GPL v2 or later
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html
     
    4949== Changelog ==
    5050
    51 = 1.0.0 - 2020-09-20 =
    52 * Initial Public Release!
     51= 1.0.7 - 2021-01-08- =
     52* Theme setup wizard improvements
     53* Escape admin_url
     54
     55= 1.0.6 - 2020-12-03- =
     56* Marmot theme options added
     57* Theme setup wizard improvements
     58
     59= 1.0.5 - 2020-11-17 =
     60* Reindex Yoast index on demo import
     61
     62= 1.0.4 - 2020-10-22 =
     63* Improving activation and configuration flow
     64
     65= 1.0.3 - 2020-10-01 =
     66* Added Elementor plugin dependency
     67* updating site urls
     68
     69= 1.0.2 - 2020-09-30 =
     70* Filesystem class added in library
     71* get_terms_objects and get_terms_for_options added in library
    5372
    5473= 1.0.1 - 2020-09-24 =
     
    5675* Remove theme recommendation
    5776
    58 = 1.0.2 - 2020-09-30 =
    59 * Filesystem class added in library
    60 * get_terms_objects and get_terms_for_options added in library
    61 
    62 = 1.0.3 - 2020-10-01 =
    63 * Added Elementor plugin dependency
    64 * updating site urls
    65 
    66 = 1.0.4 - 2020-10-22 =
    67 * Improving activation and configuration flow
    68 
    69 = 1.0.5 - 2020-11-17 =
    70 * Reindex Yoast index on demo import
    71 
    72 = 1.0.6 - 2020-12-03- =
    73 * Marmot theme options added
    74 * Theme setup wizard improvements
     77= 1.0.0 - 2020-09-20 =
     78* Initial Public Release!
  • hqtheme-extra/trunk/hqtheme-extra.php

    r2430987 r2452710  
    55 * Plugin URI:        https://marmot.hqwebs.net/marmot/?utm_source=wp-admin&utm_medium=link&utm_campaign=default&utm_term=hqtheme-extra&utm_content=plugin-uri
    66 * Description:       HQTheme Extra adds extras for Marmot Theme - Ready sites one click import
    7  * Version:           1.0.6
     7 * Version:           1.0.7
    88 * Requires at least: 5.3
    99 * Requires PHP:      7.2
    1010 * Author:            HQWebS
    1111 * Author URI:        https://marmot.hqwebs.net/?utm_source=wp-admin&utm_medium=link&utm_campaign=default&utm_term=hqtheme-extra&utm_content=plugin-author
    12  * License:           GPL v2 or later
    13  * License URI:       https://www.gnu.org/licenses/gpl-2.0.html
     12 * License:           GPL v3 or later
     13 * License URI:       https://www.gnu.org/licenses/gpl-3.0.html
    1414 * Text Domain:       hqtheme-extra
    1515 */
     
    5757 * @var string
    5858 */
    59 const VERSION = '1.0.6';
     59const VERSION = '1.0.7';
    6060
    6161// Load Autoloader
  • hqtheme-extra/trunk/inc/admin-notifications.php

    r2387081 r2452710  
    112112     * @param int $dismiss_expire
    113113     */
    114     public function add_notice($notice_key, $type, $message, $dismiss, $dismiss_expire = 0) {
     114    public function add_notice($notice_key, $type, $message, $dismiss = 1, $dismiss_expire = 0) {
    115115        global $hq_notices;
    116116
  • hqtheme-extra/trunk/inc/admin/page/theme-setup-wizzard.php

    r2430987 r2452710  
    7272                    <?php _ex('Marmot Theme Setup Wizzard will assist you through the initial website setup.', 'admin', 'hqtheme-extra'); ?><br>
    7373                </p>
     74
    7475                <div class="hqt-container">
    7576                    <?php
    76                     $this->header($step);
     77                    $this->display_notices();
     78                    $this->display_steps($step);
    7779
    7880                    switch ($this->wizard_step) {
     
    189191            }
    190192            ?>
    191             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=' . $next_step); ?>" class="btn btn-primary">
     193            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=' . $next_step)); ?>" class="btn btn-primary">
    192194                <?php _ex('Next step', 'admin', 'hqtheme-extra'); ?>
    193195            </a>
     
    208210                <?php _ex('You have to complete previous steps!', 'admin', 'hqtheme-extra'); ?>
    209211            </p>
    210             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1'); ?>" class="btn btn-primary">
     212            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1')); ?>" class="btn btn-primary">
    211213                <?php _ex('Go to uncompleted step', 'admin', 'hqtheme-extra'); ?>
    212214            </a>
     
    225227            <p>
    226228                <?php _ex('You can skip this step, if do not plan to use pro features and demos.', 'admin', 'hqtheme-extra'); ?>
    227                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3&skip-license=1'); ?>">
     229                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3&skip-license=1')); ?>">
    228230                    <?php _ex('Skip this step', 'admin', 'hqtheme-extra'); ?>
    229231                </a>
     
    232234        } else {
    233235            ?>
    234             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3'); ?>" class="btn btn-primary">
     236            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3')); ?>" class="btn btn-primary">
    235237                <?php _ex('Next step', 'admin', 'hqtheme-extra'); ?>
    236238            </a>
     
    269271                <?php _ex('You have to complete previous steps!', 'admin', 'hqtheme-extra'); ?>
    270272            </p>
    271             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=' . (defined('\HQExtra\VERSION') ? $step : 1)); ?>" class="btn btn-primary">
     273            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=' . (defined('\HQExtra\VERSION') ? $step : 1))); ?>" class="btn btn-primary">
    272274                <?php _ex('Go to uncompleted step', 'admin', 'hqtheme-extra'); ?>
    273275            </a>
     
    276278        }
    277279        ?>
    278         <a href="<?php echo admin_url('admin.php?page=marmot-ready-sites'); ?>" class="btn btn-primary mr-1">
     280        <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-ready-sites')); ?>" class="btn btn-primary mr-1">
    279281            <?php _ex('Ready Sites', 'admin', 'hqtheme-extra'); ?>
    280282        </a>
    281         <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4&skip-demo=1'); ?>" class="">
     283        <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4&skip-demo=1')); ?>" class="">
    282284            <?php _ex('Skip this step', 'admin', 'hqtheme-extra'); ?>
    283285        </a>
     
    297299                <?php _ex('You have to complete previous steps!', 'admin', 'hqtheme-extra'); ?>
    298300            </p>
    299             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1'); ?>" class="btn btn-primary">
     301            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1')); ?>" class="btn btn-primary">
    300302                <?php _ex('Go to uncompleted step', 'admin', 'hqtheme-extra'); ?>
    301303            </a>
     
    312314        <p class="m-0"><?php _ex('If you have imported pre-made demo your customization will be very easy.', 'admin', 'hqtheme-extra'); ?></p>
    313315        <p class="m-0"><?php echo sprintf('%1$s <a target="_blank" href="%2$s">%3$s</a>.', _x('Just follow the tutorial', 'admin', 'hqtheme-extra'), 'https://marmot.hqwebs.net/documentation/how-to-edit-header-template/', _x('How to edit header template', 'admin', 'hqtheme-extra')); ?></p>
    314         <p class="mt-0"><?php _ex('All other elements work same way. Go to page -> from Edit with Elementor dropdown choose template and edit.', 'admin', 'hqtheme-extra'); ?></p>
    315         <p class="mb-0"><?php _ex('If you do not use out pre-made website use our documentation to find out how to attach templates.', 'admin', 'hqtheme-extra'); ?></p>
     316        <p class="mt-0"><?php _ex('All other elements work same way. Go to page -> from Edit with Elementor dropdown (you must be logged in as an administrator) choose template and edit.', 'admin', 'hqtheme-extra'); ?></p>
     317        <p class="mb-0"><?php _ex('If you do not use our pre-made website use our documentation to find out how to attach templates.', 'admin', 'hqtheme-extra'); ?></p>
    316318        <p><?php echo sprintf('<a target="_blank" class="btn btn-primary" href="%1$s">%2$s</a>', 'https://marmot.hqwebs.net/documentation/', _x('Full documentation', 'admin', 'hqtheme-extra')); ?></p>
    317319
     
    319321    }
    320322
    321     protected function header($step) {
     323    protected function display_steps($step) {
    322324        ?>
    323325
     
    327329                    <div class="hqt-row">
    328330                        <div class="<?php echo esc_attr($this->getHeaderStepClass(1)) ?>">
    329                             <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1'); ?>" class="step-box step-1">
     331                            <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=1')); ?>" class="step-box step-1">
    330332                                <div class="step">
    331333                                    <span class="step-arrow step-arrow-left"></span>
     
    340342                        <?php if (defined('\WP_FS__DEMO_MODE') && \WP_FS__DEMO_MODE) : ?>
    341343                            <div class="<?php echo esc_attr($this->getHeaderStepClass(3)) ?>">
    342                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3'); ?>" class="step-box step-3">
     344                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3')); ?>" class="step-box step-3">
    343345                                    <div class="step">
    344346                                        <span class="step-arrow step-arrow-left"></span>
     
    352354                            </div>
    353355                            <div class="<?php echo esc_attr($this->getHeaderStepClass(4)) ?>">
    354                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4'); ?>" class="step-box step-4">
     356                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4')); ?>" class="step-box step-4">
    355357                                    <div class="step">
    356358                                        <span class="step-arrow step-arrow-left"></span>
     
    366368                        <?php else : ?>
    367369                            <div class="<?php echo esc_attr($this->getHeaderStepClass(2)) ?>">
    368                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=2'); ?>" class="step-box step-2">
     370                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=2')); ?>" class="step-box step-2">
    369371                                    <div class="step">
    370372                                        <span class="step-arrow step-arrow-left"></span>
     
    378380                            </div>
    379381                            <div class="<?php echo esc_attr($this->getHeaderStepClass(3)) ?>">
    380                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3'); ?>" class="step-box step-3">
     382                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=3')); ?>" class="step-box step-3">
    381383                                    <div class="step">
    382384                                        <span class="step-arrow step-arrow-left"></span>
     
    390392                            </div>
    391393                            <div class="<?php echo esc_attr($this->getHeaderStepClass(4)) ?>">
    392                                 <a href="<?php echo admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4'); ?>" class="step-box step-4">
     394                                <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-theme-setup&wizzard-page=4')); ?>" class="step-box step-4">
    393395                                    <div class="step">
    394396                                        <span class="step-arrow step-arrow-left"></span>
     
    410412    }
    411413
     414    protected function display_notices() {
     415        $theme = wp_get_theme();
     416       
     417        if ('Marmot' === $theme->name || 'Marmot' !== $theme->parent_theme) {
     418            ?>
     419            <div class="hqt-row border-rad-10 hqt-box-shadow mt-1 mb-4 mx-0 py-3 px-2" style="border-left: solid 4px #2096F3;">
     420                <div class="hqt-col-1-1">
     421                    <h3 class="p-0 mt-0 mb-2"><?php _ex('Not using a child theme?', 'admin', 'hqtheme-extra'); ?></h3>
     422                    <p class="m-0">
     423                        <?php _ex('A child theme allows you to change small aspects of your site`s appearance yet still preserve your theme’s look and functionality. It protects your changes to be overwritten on update of main theme.', 'admin', 'hqtheme-extra'); ?>
     424                    </p>
     425                    <p class="mt-0 mb-3">
     426                        <?php echo sprintf('<a href="%1$s" target="_blank">%2$s</a> %3$s', 'https://developer.wordpress.org/themes/advanced-topics/child-themes/', _x('Learn more', 'admin', 'hqtheme-extra'), _x('what is a child theme and how it works.', 'admin', 'hqtheme-extra')); ?>
     427                    </p>
     428                    <a href="https://github.com/hqwebs/marmot-theme-child/releases/download/1.0.0/marmot-theme-child.zip" class="btn btn-primary mr-1"><?php _ex('Download Marmot Child', 'admin', 'hqtheme-extra'); ?></a>
     429                </div>
     430            </div>
     431            <?php
     432        }
     433    }
     434
    412435    private function getHeaderStepClass($step) {
    413436        $classes = ['hqt-col-1-4 mb-3'];
  • hqtheme-extra/trunk/inc/hqlib/helper.php

    r2400862 r2452710  
    336336                            <?php if (!empty($require['link'])) : ?>
    337337                                <div class="ml-2">
    338                                     <a href="<?php echo admin_url($require['link']); ?>">Settings</a>
     338                                    <a href="<?php echo esc_url(admin_url($require['link'])); ?>">Settings</a>
    339339                                </div>
    340340                            <?php endif; ?>
     
    359359                            <?php if (!empty($require['link'])) : ?>
    360360                                <div class="ml-2">
    361                                     <a href="<?php echo admin_url($require['link']); ?>">Settings</a>
     361                                    <a href="<?php echo esc_url(admin_url($require['link'])); ?>">Settings</a>
    362362                                </div>
    363363                            <?php endif; ?>
  • hqtheme-extra/trunk/inc/hqlib/license.php

    r2430987 r2452710  
    202202                    <h2 class="mt-0 mb-3"><?php _ex('You\'re ready to go!', 'license info', 'hqtheme-extra'); ?></h2>
    203203                    <p class="mt-0 mb-2"><?php _ex('Start building your website like a Pro! Enjoy all the premium features - import awesome templates with a click, create stunning popups, attach custom headers and footers on each page, use advanced widgets for Elementor with <b>Dynamic Tags</b>, create unique WooCommerce checkout flow and more, and more...', 'license info', 'hqtheme-extra'); ?></p>
    204                     <a href="<?php echo admin_url('admin.php?page=marmot'); ?>" class="btn btn-border mt-3"><?php _ex('Start Using Premium Features', 'license info', 'hqtheme-extra'); ?></a>
    205                     <a href="<?php echo admin_url('admin.php?page=marmot-ready-sites'); ?>" class="btn btn-danger-border mt-3 ml-2"><?php _ex('Import Demo', 'license info', 'hqtheme-extra'); ?></a>
     204                    <a href="<?php echo esc_url(admin_url('admin.php?page=marmot')); ?>" class="btn btn-border mt-3"><?php _ex('Start Using Premium Features', 'license info', 'hqtheme-extra'); ?></a>
     205                    <a href="<?php echo esc_url(admin_url('admin.php?page=marmot-ready-sites')); ?>" class="btn btn-danger-border mt-3 ml-2"><?php _ex('Import Demo', 'license info', 'hqtheme-extra'); ?></a>
    206206
    207207                    <?php
  • hqtheme-extra/trunk/inc/menu.php

    r2400862 r2452710  
    4242    private function __construct() {
    4343        add_action('init', [$this, 'registerPosttype'], 50, 0);
     44
     45        add_action('admin_enqueue_scripts', [$this, 'load_admin_assets'], 10);
    4446    }
    4547
     
    7072    }
    7173
     74    /**
     75     * Fix Clever menu
     76     *
     77     * @since 1.0.6
     78     */
     79    public function load_admin_assets() {
     80        // Fix Clever Menu in Customizer
     81        wp_localize_script('cmm4e-admin', 'cleverMenuItems', []);
     82    }
     83
    7284}
  • hqtheme-extra/trunk/readme.txt

    r2430987 r2452710  
    55Tested up to: 5.5
    66Requires PHP: 7.2
    7 Stable tag: 1.0.6
     7Stable tag: 1.0.7
    88License: GPL v2 or later
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html
     
    4949== Changelog ==
    5050
    51 = 1.0.0 - 2020-09-20 =
    52 * Initial Public Release!
     51= 1.0.7 - 2021-01-08- =
     52* Theme setup wizard improvements
     53* Escape admin_url
     54
     55= 1.0.6 - 2020-12-03- =
     56* Marmot theme options added
     57* Theme setup wizard improvements
     58
     59= 1.0.5 - 2020-11-17 =
     60* Reindex Yoast index on demo import
     61
     62= 1.0.4 - 2020-10-22 =
     63* Improving activation and configuration flow
     64
     65= 1.0.3 - 2020-10-01 =
     66* Added Elementor plugin dependency
     67* updating site urls
     68
     69= 1.0.2 - 2020-09-30 =
     70* Filesystem class added in library
     71* get_terms_objects and get_terms_for_options added in library
    5372
    5473= 1.0.1 - 2020-09-24 =
     
    5675* Remove theme recommendation
    5776
    58 = 1.0.2 - 2020-09-30 =
    59 * Filesystem class added in library
    60 * get_terms_objects and get_terms_for_options added in library
    61 
    62 = 1.0.3 - 2020-10-01 =
    63 * Added Elementor plugin dependency
    64 * updating site urls
    65 
    66 = 1.0.4 - 2020-10-22 =
    67 * Improving activation and configuration flow
    68 
    69 = 1.0.5 - 2020-11-17 =
    70 * Reindex Yoast index on demo import
    71 
    72 = 1.0.6 - 2020-12-03- =
    73 * Marmot theme options added
    74 * Theme setup wizard improvements
     77= 1.0.0 - 2020-09-20 =
     78* Initial Public Release!
Note: See TracChangeset for help on using the changeset viewer.