//----------------------------------------------------------------------------- // Maintenance Mode //----------------------------------------------------------------------------- add_action( 'init', 'cherry_maintenance_mode_redirecte' ); function cherry_maintenance_mode_redirecte() { global $pagenow; $mtc_options = get_option('mtc_options'); if(isset($mtc_options['mtc_mode_on'])){ // if (current_user_can( 'administrator')) { if ( is_user_logged_in() ) { if(is_admin()){ if($pagenow != "admin.php"){ add_action( 'admin_notices', 'cherry_maintenance_mode_notice' ); } }else{ add_action( 'wp_before_admin_bar_render', 'cherry_maintenance_mode_notice' ); } }else{ $page_url_now = cherry_get_page_URL(); if(!strripos($page_url_now, '/wp-admin') && $pagenow != "wp-login.php"){ add_action("wp_head", "cherry_under_construction_page_content"); } } register_sidebar(array( 'name' => __('Under Construction Page Widgets Area.', CHERRY_PLUGIN_DOMAIN), 'id' => 'under-construction-area', 'description' => __('Under construction page widgets area.', CHERRY_PLUGIN_DOMAIN), 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', )); } } function cherry_under_construction_page_content(){ $files = '/plugin-under-construction-content.php'; $template_dir = file_exists(CURRENT_THEME_DIR . $files) ? CURRENT_THEME_DIR . $files : CHERRY_PLUGIN_DIR .'includes' . $files ; include_once ($template_dir); exit; } function cherry_maintenance_mode_notice(){ echo cherry_add_notice(array( 'wrapper_id' => 'maintenance_mode_notice', 'wrapper_class' => 'error', 'notice_content' => ''.__('Maintenance mode activated. Website is blocked from public', CHERRY_PLUGIN_DOMAIN).' '.__('Settings.', CHERRY_PLUGIN_DOMAIN).'' ) ); if(!is_admin()){ echo ''; } } add_action('wp_ajax_mtc_save', 'cherry_mtc_save'); function cherry_mtc_save() { $post_date = isset($data) ? $data : $_POST['data'] ; update_option('mtc_options', $post_date); exit(); } //----------------------------------------------------------------------------- // End Maintenance Mode //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- // Add notace in admin panel or web site //----------------------------------------------------------------------------- function cherry_add_notice($attr = array()){ $default = array( 'wrapper_id' => '', 'wrapper_class' => 'error', 'notice_content' => '' ); extract(array_merge($default, $attr)); $wrapper_id = $wrapper_id ? ' id ="'.$wrapper_id.'"' : '' ; $wrapper_class = $wrapper_class ? ' class ="'.$wrapper_class.'"' : '' ; $output = '


'; return $output; } //----------------------------------------------------------------------------- // get now page url //----------------------------------------------------------------------------- function cherry_get_page_URL(){ if(!isset($_SERVER['REQUEST_URI'])){ $site_uri = $_SERVER['PHP_SELF']; } else { $site_uri = $_SERVER['REQUEST_URI']; $https = empty($_SERVER["HTTPS"]) ? '' : ($_SERVER["HTTPS"] == "on") ? "s" : ""; $site_protocol = strtolower($_SERVER["SERVER_PROTOCOL"]); $site_protocol = substr($site_protocol,0,strpos($site_protocol,"/")).$https; $site_port = ($_SERVER["SERVER_PORT"] == "80") ? "" : (":".$_SERVER["SERVER_PORT"]); } return $site_protocol."://".$_SERVER['SERVER_NAME'].$site_port.$site_uri; } » sstrickland

Recent Posts by sstrickland

Principles of Core Stability

Watch this video to get the most out of your core workout. Core stability is often misunderstood. The truth is it has very little to do with sit-ups and crunches.  

Telemark Ski Exercise: Rotational Row

This video demonstrates a split stance with rotational row that can be incorporated into Stability, Strength or Power training program. Strengthen your legs, quads, glutes, core and back. Check out Telemark Fitness Ski Training Video, endorsed by US Ski Team Physician, F. Lincoln Avery, M.D.  

Telemark Ski Power Training for Abs

After building a base of muscular endurance, joint stability, balance and strength, your abs and core are ready for a more advanced power workout. Move with greater speed and agility on the ski slopes this winter while reducing injuries.  

Telemark Skier Magazine : Issue from October 2012

I write a monthly fitness column for Telemark Skier Magazine. In this first issue from October 2012, learn about a great core exercise for skiing and the importance of core stability. “…Twist, rotate, step, or reach, and the movement is centered around the spine. Performing a true core stability exercise means the spine does not…

Telemark Fitness Exercise Tips : Stretch the Hips for a Stronger Butt!

Fitness training for telemark skiing isn’t just about about lunges and strong quadriceps. You need a strong butt too! Tightness in the hip flexor inhibits your ability to get good hip extension and as a result, minimizes how well your butt muscle can contract. Without a butt muscle that works well, you’ll ski inefficiently and…

Telemark Skiing Power Training Exercise Series for the Legs

For those who have completed the stability/muscular endurance and strength phases of training, this is a great introductory power exercise series for the legs.  Make telemark skiing more fun by improving your ability to move quickly into and out of your telemark ski stance (great in crud and on the steeps). Check out the video…

Telemark Ski Core Workout: Abdominal Challenge

Incorporate this telemark ski fitness exercise into your core workout to improve your strength and power on the slopes. Get the most out of your ski season by getting in shape before the snow flies, and maintain your fitness level by working the muscle groups most utilized in telemark skiing.  

Recent Comments by sstrickland

No comments by sstrickland yet.