Example #1
0
 function thb_contact_map($params = array())
 {
     $latlong = thb_get_option('contact_lat_long');
     $zoom = thb_get_option("contact_zoom");
     $marker = thb_get_option("contact_marker");
     $map_config = array('height' => '500');
     $map_config = thb_array_asum($map_config, $params);
     if ($latlong != '') {
         echo thb_do_shortcode("[thb_map latlong='{$latlong}' zoom='{$zoom}' " . thb_get_attributes($map_config) . " marker='{$marker}']");
     }
 }
		<div class="slide" <?php 
    thb_data_attributes($slide_data);
    ?>
>
			<?php 
    if ($slide['type'] == 'image') {
        ?>
				<img src="<?php 
        echo thb_image_get_size($slide['id'], $image_size);
        ?>
" alt="">
			<?php 
    } else {
        ?>
				<?php 
        $attributes = thb_get_attributes(array('url' => $slide['url'], 'class' => 'thb_slideshow_video thb-noFit', 'autoplay' => $slide['autoplay'], 'loop' => $slide['loop']));
        echo thb_do_shortcode('[thb_video ' . $attributes . ']');
        ?>
			<?php 
    }
    ?>

			<?php 
    if ($slide['caption'] != '') {
        ?>
				<div class="caption">
					<?php 
        echo thb_text_format($slide['caption'], true);
        ?>
				</div>
			<?php 
 function thb_post_format_gallery($config = array())
 {
     $config = thb_array_asum(array('size' => 'large', 'id' => 'gallery-stream', 'link' => 'file'), $config);
     echo do_shortcode(sprintf('[thb_gallery %s]', thb_get_attributes($config)));
 }
Example #4
0
?>
">
	<ul class="slides">
		<?php 
foreach ($slideshow->getSlides() as $slide) {
    ?>

			<?php 
    if ($slide['type'] == 'image') {
        if ($slideshow_smooth_height) {
            $img = $slide['url'];
        } else {
            $img = thb_get_resized_image($slide['id'], $slideshow_width, $slideshow_height, true);
        }
    } else {
        $video_data = thb_get_attributes(array('fixed_height' => $slideshow_height, 'fixed_width' => $slideshow_width));
    }
    ?>

			<li class="slide" data-thumb="<?php 
    echo $slide['thumb'];
    ?>
" data-type="<?php 
    echo $slide['type'];
    ?>
">
				<?php 
    if ($slide['type'] == 'image') {
        ?>

					<?php 
 /**
  * Display a flash message.
  */
 function thb_flash_message()
 {
     $thb_post_msg = '';
     $thb_post_msg_type = '';
     $flashdata = thb_system_get_flashdata();
     if ($flashdata !== false && $flashdata['message'] != '') {
         $thb_post_msg = $flashdata['message'];
         $thb_post_msg_type = $flashdata['type'];
     }
     $attrs = array('class' => 'thb-msg-container', 'data-type' => $thb_post_msg_type, 'data-message' => $thb_post_msg);
     printf('<div %s></div>', thb_get_attributes($attrs));
 }
 function thb_querystring($pars = array())
 {
     echo thb_get_attributes($pars);
 }