shortcode_wrapper( array( __CLASS__, 'output' ), $atts ); } /** * Output the shortcode. * * @access public * @param array $atts * @return void */ public static function output( $atts ) { global $woocommerce; if ( ! is_user_logged_in() ) { woocommerce_get_template( 'myaccount/form-login.php' ); } else { extract( shortcode_atts( array( 'order_count' => 5 ), $atts ) ); woocommerce_get_template( 'myaccount/my-account.php', array( 'current_user' => get_user_by( 'id', get_current_user_id() ), 'order_count' => 'all' == $order_count ? -1 : $order_count ) ); } } }