Ejemplo n.º 1
0
 protected function get_caption()
 {
     if (!$this->show_caption) {
         return;
     }
     $caption = parent::get_caption();
     if (empty($caption)) {
         return;
     }
     $this->captions .= "<span class=\"orbit-caption\" id=\"post" . get_the_ID() . "\">{$caption}</span>";
 }
Ejemplo n.º 2
0
 protected function get_caption($i = 0)
 {
     $caption = parent::get_caption();
     $position = get_post_meta(get_the_ID(), 's3_caption_position', true);
     if (empty($position)) {
         $position = $this->default_position;
     }
     if ($position == 'left-right') {
         $i % 2 == 0 ? $position = 'right' : ($position = 'left');
     }
     return "<span class=\"s3slider-{$position}\">{$caption}</span>";
 }
Ejemplo n.º 3
0
 protected function get_caption()
 {
     if (!$this->show_caption) {
         return;
     }
     $caption = parent::get_caption();
     if (empty($caption)) {
         return;
     }
     $position = get_post_meta(get_the_ID(), 'coin_caption_position', true);
     if (empty($position)) {
         $position = $this->default_position;
     }
     return "<span class=\"{$position}\">{$caption}</span>";
 }
Ejemplo n.º 4
0
 protected function get_caption()
 {
     if (!$this->show_caption) {
         return;
     }
     $caption = parent::get_caption();
     if (empty($caption)) {
         return;
     }
     $position = get_post_meta(get_the_ID(), 'nivo_caption_position', true);
     if (empty($position)) {
         $position = $this->default_position;
     }
     $this->captions .= "<div id=\"slide-" . get_the_ID() . "\" class=\"nivo-html-caption\" data-position=\"{$position}\">{$caption}</div>";
 }
Ejemplo n.º 5
0
    public function render($loop)
    {
        ?>
		<ul id="anythingSlider" style="display:none;">
			<?php 
        while ($loop->have_posts()) {
            $loop->the_post();
            $this->target_link = metaboxesGenerator::the_superlink();
            $slide_type = get_post_meta(get_the_ID(), 'anything_slide_type', true);
            $video_link = get_post_meta(get_the_ID(), 'anything_video_link', true);
            if (!empty($video_link)) {
                $slide_type = 'video';
            }
            ?>
			<li><?php 
            switch ($slide_type) {
                case 'video':
                    echo $this->getVideoObject($video_link);
                    break;
                case 'text':
                    the_content();
                    break;
                case 'image_text':
                    if (!get_post_thumbnail_id()) {
                        continue;
                    }
                    $caption = parent::get_caption();
                    $position = get_post_meta(get_the_ID(), 'anything_text_position', true);
                    if (empty($position)) {
                        $position = $this->default_text_position;
                    }
                    ?>
						<div class="text_slide_<?php 
                    echo $position;
                    ?>
">
							<div class="pic"><?php 
                    the_post_thumbnail('slider_anything_small', array('title' => false));
                    ?>
</div>
							<div class="txt"><?php 
                    echo $caption;
                    ?>
</div>
							<div class="clear"></div>
						</div>
					<?php 
                    break;
                case 'image':
                default:
                    if (!get_post_thumbnail_id()) {
                        continue;
                    }
                    echo $this->get_caption();
                    the_post_thumbnail('slider_anything_big', array('title' => false));
                    break;
            }
            ?>
</li>
			<?php 
        }
        ?>
		</ul>
<?php 
    }