Ejemplo n.º 1
0
 function sr_admin_page()
 {
     global $woocommerce;
     $tab = !empty($_GET['tab']) ? $_GET['tab'] : 'smart_reporter_beta';
     switch ($tab) {
         case "smart_reporter_old":
             sr_show_console();
             break;
         default:
             sr_beta_show_console();
             break;
     }
 }
Ejemplo n.º 2
0
    function admin_page()
    {
        global $woocommerce;
        $tab = !empty($_GET['tab']) ? $_GET['tab'] : 'smart_reporter_beta';
        ?>

        <div style = "margin:0.7em 0.5em 0 0" class="wrap woocommerce">

            <h2 class="nav-tab-wrapper woo-nav-tab-wrapper">
                <a href="<?php 
        echo admin_url('admin.php?page=smart-reporter-woo');
        ?>
" class="nav-tab <?php 
        echo $tab == 'smart_reporter_beta' ? 'nav-tab-active' : '';
        ?>
">Smart Reporter <sup style="vertical-align: super;color:red; font-size:15px">Beta</sub></a>
                <a href="<?php 
        echo admin_url('admin.php?page=smart-reporter-woo&tab=smart_reporter_old');
        ?>
" class="nav-tab <?php 
        echo $tab == 'smart_reporter_old' ? 'nav-tab-active' : '';
        ?>
">Smart Reporter</a>
            </h2>

            <?php 
        switch ($tab) {
            case "smart_reporter_old":
                sr_show_console();
                break;
            default:
                sr_beta_show_console();
                break;
        }
        ?>

	    </div>
	    <?php 
    }