示例#1
0
                <div class="col-md-5 col-sm-5 col-xs-5">
                    <i class="fa fa-map-marker"> &nbsp;</i>
                    <?php 
$address = get_post_meta(get_the_ID(), 'address', true);
?>
                    <?php 
if (!empty($address)) {
    echo esc_html($address);
}
?>
                </div>
                <div class="col-md-7 col-sm-7 col-xs-7 text-right">
                    <div class="package-info">
                        <i class="fa fa-calendar">&nbsp;</i>
                        <span class=""><?php 
STLanguage::st_the_language('holiday_date');
?>
: </span>
                        <?php 
$type_holiday = get_post_meta(get_the_ID(), 'type_holiday', true);
if ($type_holiday == 'daily_holiday') {
    $day = STHoliday::get_duration_unit();
    echo esc_html($day);
} else {
    $check_in = get_post_meta(get_the_ID(), 'check_in', true);
    $check_out = get_post_meta(get_the_ID(), 'check_out', true);
    if (!empty($check_in) and !empty($check_out)) {
        $date = date_i18n(TravelHelper::getDateFormat(), strtotime($check_in)) . ' <i class="fa fa-long-arrow-right"></i> ' . date_i18n(TravelHelper::getDateFormat(), strtotime($check_out));
        echo balanceTags($date);
    } else {
        st_the_language('holiday_none');
示例#2
0
    ?>
           <header class="thumb-header">
               <a href="<?php 
    the_permalink();
    ?>
" class="hover-img">
                   <?php 
    $img = get_the_post_thumbnail(get_the_ID(), array(800, 600, 'bfi_thumb' => true));
    if (!empty($img)) {
        echo balanceTags($img);
    } else {
        echo '<img width="800" height="600" alt="no-image" class="wp-post-image" src="' . bfi_thumb(get_template_directory_uri() . '/img/no-image.png', array('width' => 800, 'height' => 600)) . '">';
    }
    ?>
                   <h5 class="hover-title-center"><?php 
    STLanguage::st_the_language('book_now');
    ?>
</h5>
               </a>
           </header>
           <div class="thumb-caption">
               <ul class="icon-group text-tiny text-color">
                   <?php 
    echo TravelHelper::rate_to_string(STReview::get_avg_rate());
    ?>
               </ul>
               <h5 class="thumb-title">
                   <a href="<?php 
    the_permalink();
    ?>
" class="text-darken">
示例#3
0
 function st_the_language($key)
 {
     if (class_exists('STLanguage')) {
         STLanguage::st_the_language($key);
     } else {
         global $st_language;
         if (!empty($st_language[$key])) {
             echo balanceTags($st_language[$key]);
         } else {
             echo balanceTags($key);
         }
     }
 }
示例#4
0
                <?php 
$img = get_the_post_thumbnail(get_the_ID(), array(800, 600, 'bfi_thumb' => true));
if (!empty($img)) {
    echo balanceTags($img);
} else {
    echo '<img width="800" height="600" alt="no-image" class="wp-post-image" src="' . get_template_directory_uri() . '/img/no-image.png">';
}
?>
                <h5 class="hover-title-top-left hover-hold"><?php 
the_title();
?>
</h5>
            </a>
        </header>
        <div class="thumb-caption text-center">
            <p class="thumb-desc"><?php 
the_excerpt();
?>
</p>
            <a class="btn btn-default btn-ghost mt10" href="<?php 
the_permalink();
?>
">
                <?php 
STLanguage::st_the_language('read_more');
?>
                <i class="fa fa-angle-right"></i>
            </a>
        </div>
    </div>
</div>
示例#5
0
        echo '<i class="fa fa-map-marker"></i> ';
        echo esc_html($address);
        echo '</div>';
    }
    ?>

                       <div class="col-md-7 col-sm-7 col-xs-7 <?php 
    if ($address) {
        echo 'text-right';
    }
    ?>
">
                           <div class="package-info">
                               <i class="fa fa-calendar"></i>
                               <span class=""><?php 
    STLanguage::st_the_language('tour_date');
    ?>
: </span>
                               <?php 
    $type_tour = get_post_meta(get_the_ID(), 'type_tour', true);
    if ($type_tour == 'daily_tour') {
        $day = STTour::get_duration_unit();
        echo esc_html($day);
    } else {
        $check_in = get_post_meta(get_the_ID(), 'check_in', true);
        $check_out = get_post_meta(get_the_ID(), 'check_out', true);
        if (!empty($check_in) and !empty($check_out)) {
            $format = TravelHelper::getDateFormat();
            $date = date_i18n($format, strtotime($check_in)) . ' <i class="fa fa-long-arrow-right"></i> ' . date_i18n($format, strtotime($check_out));
            echo balanceTags($date);
        } else {
示例#6
0
}
?>
                    </ul>

                <?php 
$page_search = st_get_page_search_result($st_type);
if (!empty($page_search)) {
    //$link = add_query_arg(array('location_id'=>get_the_ID()),get_the_permalink($page_search));
    $link = add_query_arg(array('location_id' => get_the_ID(), 'pick-up' => get_the_title()), get_the_permalink($page_search));
} else {
    //$link = home_url(esc_url('?s=&post_type='.$st_type.'&location_id='.get_the_ID()));
    //$link = home_url(esc_url('?s=&post_type='.$st_type.'&location_id='.get_the_ID()."&pick-up=".get_the_title()));
    $link = add_query_arg(array('s' => '', 'post_type' => $st_type, 'location_id' => get_the_ID(), 'pick-up' => get_the_title()), home_url('/'));
}
if ($link_to == 'single') {
    $link = get_the_permalink();
}
?>
                <a class="btn btn-white btn-ghost mt10" href="<?php 
echo esc_url($link);
?>
">
                    <i class="fa fa-angle-right"></i>
                    <?php 
STLanguage::st_the_language('explore');
?>
                </a>
            </div>
        </div>
    </div>
</div>