<?php $holidays = new STHoliday(); $info_price = STHoliday::get_info_price(); $price = $info_price['price']; $count_sale = $info_price['discount']; if (!empty($count_sale)) { $price = $info_price['price']; $price_sale = $info_price['price_old']; } $link = st_get_link_with_search(get_permalink(), array('start', 'end', 'duration', 'people'), $_GET); ?> <div class=""> <?php echo STFeatured::get_featured(); ?> <div class="thumb"> <header class="thumb-header"> <?php if (!empty($count_sale)) { ?> <span class="box_sale btn-primary"> <?php echo esc_html($count_sale); ?> % </span> <?php } ?> <a href="<?php echo esc_url($link); ?>
<?php $link = st_get_link_with_search(get_permalink(), array('start', 'end', 'room_num_search', 'adult_number', 'child_num'), $_GET); $thumb_url = wp_get_attachment_url(get_post_thumbnail_id(get_the_ID())); ?> <div class="div_item_map <?php echo 'div_map_item_' . get_the_ID(); ?> " > <!--<div class="st_featured"><?php /*echo esc_html($post_type) */ ?> </div>--> <?php echo STFeatured::get_featured(); ?> <div class="thumb item_map"> <header class="thumb-header"> <div class="booking-item-img-wrap st-popup-gallery"> <a href="<?php echo esc_url($thumb_url); ?> " class="st-gp-item"> <?php if (has_post_thumbnail() and get_the_post_thumbnail()) { the_post_thumbnail(array(360, 270, 'bfi_thumb' => TRUE)); } else { echo st_get_default_image(); } ?> </a>
<?php /** * @package WordPress * @subpackage Traveler * @since 1.0 * * Cars element loop 2 * * Created by ShineTheme * */ $link = st_get_link_with_search(get_permalink(), array('pick-up', 'location_id_pick_up', 'drop-off', 'location_id_drop_off', 'drop-off-time', 'pick-up-time', 'drop-off-date', 'pick-up-date'), $_GET); $info_price = STCars::get_info_price(); $price = $info_price['price']; $count_sale = $info_price['discount']; if (!empty($count_sale)) { $price = $info_price['price']; $price_sale = $info_price['price_old']; } ?> <div <?php post_class('col-md-4 style_box'); ?> > <?php echo STFeatured::get_featured(); ?> <div class="thumb"> <header class="thumb-header"> <?php
</tr> <?php if (STCart::use_coupon()) { $price_coupon = floatval(STCart::get_coupon_amount()); if ($price_coupon < 0) { $price_coupon = 0; } ?> <tr> <td class="text-left title"> <?php printf(st_get_language('coupon_key'), STCart::get_coupon_code()); ?> <br/> <a href="<?php echo st_get_link_with_search(get_permalink(), array('remove_coupon'), array('remove_coupon' => STCart::get_coupon_code())); ?> " class="danger"><small class='text-color'>(<?php st_the_language('Remove coupon'); ?> )</small></a> </td> <td class="text-right "> <strong> - <?php echo TravelHelper::format_money($price_coupon); ?> </strong> </td> </tr>
function get_book_history($type = '') { global $current_user; get_currentuserinfo(); $user_id = $current_user->ID; $paged = 1; if (!empty($_REQUEST['paged'])) { $paged = $_REQUEST['paged']; } // get list id order $arg = array('post_type' => 'st_order', 'paged' => $paged, 'post_status' => array('publish'), 'posts_per_page' => '10', 'meta_query' => array(array('key' => 'id_user', 'value' => array($user_id), 'compare' => 'IN'))); if (STInput::request('data_type')) { $type = STInput::request('data_type'); } if ($type != "") { $arg['meta_query'][] = array('key' => 'status', 'value' => array($type), 'compare' => 'IN'); } query_posts($arg); $html = ''; global $wp_query; while (have_posts()) { the_post(); $id_item = get_post_meta(get_the_ID(), 'item_id', true); $check_in = get_post_meta(get_the_ID(), 'check_in', true); $check_out = get_post_meta(get_the_ID(), 'check_out', true); $total_price = get_post_meta(get_the_ID(), 'item_price', true); $comment_post_id = apply_filters('st_real_comment_post_id', $id_item); $action = ''; $user_url = st()->get_option('page_my_account_dashboard'); $data['sc'] = 'write_review'; $data['item_id'] = $id_item; if (STReview::check_reviewable($comment_post_id) and comments_open($comment_post_id)) { $action = '<a href="' . st_get_link_with_search(get_permalink($user_url), array('sc', 'item_id'), $data) . '">' . st_get_language('user_write_review') . '</a>'; } if ($check_in and $check_out) { $date = mysql2date('d/m/y', $check_in) . ' <i class="fa fa-long-arrow-right"></i> ' . mysql2date('d/m/y', $check_out); } if (get_post_type($id_item) == 'st_tours') { $type_tour = get_post_meta($id_item, 'type_tour', true); if ($type_tour == 'daily_tour') { $duration = get_post_meta($id_item, 'duration_day', true); $date = __("Check in : ", ST_TEXTDOMAIN) . mysql2date('d/m/y', $check_in) . "<br>"; $date .= __("Duration : ", ST_TEXTDOMAIN) . $duration; } } $icon_type = $this->get_icon_type_order_item($id_item); if (!empty($icon_type)) { $html .= ' <tr class="' . get_the_ID() . '"> <td class="booking-history-type ' . get_post_type($id_item) . '"> ' . $this->get_icon_type_order_item($id_item) . ' </td> <td class="booking-history-title"> <a href="' . $this->get_link_order_item($id_item) . '">' . $this->get_title_order_item($id_item) . '</a></td> <td>' . $this->get_location_order_item($id_item) . '</td> <td>' . get_the_date() . '</td> <td>' . $date . '</td> <td>' . TravelHelper::format_money($total_price) . '</td> <td>' . get_post_meta(get_the_ID(), 'status', true) . '</td> <td>' . $action . '</td> </tr>'; } } wp_reset_query(); if (!empty($_REQUEST['show'])) { if (!empty($html)) { $status = 'true'; } else { $status = 'false'; } echo json_encode(array('html' => $html, 'data_per' => $paged + 1, 'status' => $status)); die; } else { return $html; } }
case "st_activity": $class = new STActivity(); $rs_string .= $class->get_result_string(); $page_search = st()->get_option('activity_search_result_page'); break; } echo ' <div class="row"> <div class="col-md-3"><h3>' . $obj->labels->singular_name . '</h3></div> <div class="col-md-9 text-right"> <h3>' . $rs_string . '</h3> </div> </div> '; if (!empty($page_search)) { $link_view_all = st_get_link_with_search(get_permalink($page_search), array('location_name', 'location_id', 'item_name', 'price_range', 'pick-up', 'location_id_pick_up'), $_GET); if ($query->query['post_type'] == 'st_cars') { $link_view_all = add_query_arg(array('pick-up' => STInput::request('location_name'), 'location_id_pick_up' => STInput::request('location_id')), $link_view_all); } } else { $link_view_all = "#"; } $content = ""; $i = 0; while (have_posts()) { the_post(); $post_type = get_post_type(); if ($i < $st_number) { switch ($post_type) { case "st_hotel": if ($st_style == '1') {
<?php /** * @package WordPress * @subpackage Traveler * @since 1.0 * * Activity element loop 1 * * Created by ShineTheme * */ $link = st_get_link_with_search(get_permalink(), array('start'), $_GET); $info_price = STActivity::get_info_price(); $price = $info_price['price']; $count_sale = $info_price['discount']; if (!empty($count_sale)) { $price = $info_price['price']; $price_sale = $info_price['price_old']; } $type_activity = get_post_meta(get_the_ID(), 'type_activity', true); $title_type_activity = __('Specific Date', ST_TEXTDOMAIN); if ($type_activity == 'specific_date') { $title_type_activity = __('Specific Date', ST_TEXTDOMAIN); } if ($type_activity == 'daily_activity') { $title_type_activity = __('Daily Activity', ST_TEXTDOMAIN); } ?> <li <?php post_class('booking-item');