/**
  * draw_page_slurp_meta_box function.
  *
  * @access public
  * @param mixed $post
  * @return void
  */
 public function draw_page_slurp_meta_box($post)
 {
     global $woocommerce;
     $this->init_mijireh();
     echo "<div id='mijireh_notice' class='mijireh-info alert-message info' data-alert='alert'>";
     echo "<h2>Slurp your custom checkout page!</h2>";
     echo "<p>Get the page designed just how you want and when you're ready, click the button below and slurp it right up.</p>";
     echo "<div id='slurp_progress' class='meter progress progress-info progress-striped active' style='display: none;'><div id='slurp_progress_bar' class='bar' style='width: 20%;'>Slurping...</div></div>";
     echo "<p><a href='#' id='page_slurp' rel=" . $post->ID . " class='button-primary'>Slurp This Page!</a> ";
     echo '<a class="nobold" href="' . Mijireh::preview_checkout_link() . '" id="view_slurp" target="_new">Preview Checkout Page</a></p>';
     echo "</div>";
 }
<div id="mijireh_notice" class="mijireh-info alert-message info" data-alert="alert">
	<h2><?php 
_e('Slurp your custom checkout page!', 'woocommerce-gateway-mijireh-checkout');
?>
</h2>
	<p><?php 
_e('Get the page designed just how you want and when you\'re ready, click the button below and slurp it right up.', 'woocommerce-gateway-mijireh-checkout');
?>
</p>
	<div id="slurp_progress" class="meter progress progress-info progress-striped active" style="display: none;">
		<div id="slurp_progress_bar" class="bar" style="width: 20%;"><?php 
_e('Slurping...', 'woocommerce-gateway-mijireh-checkout');
?>
</div>
	</div>
	<p><a href="#" id="page_slurp" rel="<?php 
echo $post->ID;
?>
" class="button-primary"><?php 
_e('Slurp This Page!', 'woocommerce-gateway-mijireh-checkout');
?>
</a> <a class="nobold" href="<?php 
echo Mijireh::preview_checkout_link();
?>
" id="view_slurp" target="_new"><?php 
_e('Preview Checkout Page', 'woocommerce-gateway-mijireh-checkout');
?>
</a></p>
</div>
 /**
  * Page slurp.
  *
  * @return string
  */
 public static function page_slurp()
 {
     self::init_mijireh();
     $page = get_page(absint($_POST['page_id']));
     $url = get_permalink($page->ID);
     $job_id = $url;
     if (wp_update_post(array('ID' => $page->ID, 'post_status' => 'publish'))) {
         $job_id = Mijireh::slurp($url, $page->ID, str_replace('https:', 'http:', add_query_arg('wc-api', 'WC_Gateway_Mijireh', home_url('/'))));
     }
     echo $job_id;
     die;
 }
 public function init_mijireh()
 {
     if (!class_exists('Mijireh')) {
         require_once 'mijireh/Mijireh.php';
         $settings = get_option('tc_settings');
         Mijireh::$access_key = $this->get_option('access_key');
     }
 }