Example #1
0
	    					</div>
	    				<?php } else {

	    				$image_attributes = wp_get_attachment_image_src( get_post_thumbnail_id(), 'full' );
	    				$imgurl = $image_attributes[0];
	    				$urlquery = parse_url($imgurl);
							if (isset($urlquery['query'])) {
								parse_str($urlquery['query'], $output);
								if (isset($output['resize'])) {
									$imgsize = explode(",", $output['resize']);
									$image_attributes[1] = $imgsize[0];
									$image_attributes[2] = $imgsize[1];
								}
							}
							?>
	    				<div class="dummy" style="margin-top: <?php echo get_dummy_height($image_attributes[1],$image_attributes[2]); ?>%"></div>
	    				<a href="<?php the_permalink(); ?>" class="video pushed"><?php the_post_thumbnail(get_image_size($size)); ?>
	    				<?php
		    				if ($video) echo '<div class="video"></div>';
	    				?></a>
	    				<?php } ?>
	    			</div>
	    		<?php } ?>
		<?php if ( $titleON || $contentON) { ?>
			<div class="entry-text-cont">
				<?php if ($titleON && !$quote) { ?>
				<h2 class="entry-title"><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
				<?php } ?>
				<?php if ($contentON) {
    			if ($dateON && !$quote) { ?>
	    		<div class="entry-meta">
							if (isset($output['resize'])) {
								$imgsize = explode(",", $output['resize']);
								$image_attributes[1] = $imgsize[0];
								$image_attributes[2] = $imgsize[1];
							}
						}
						$alt = ($portfolio_mb->get_the_value('alt')) ? $portfolio_mb->get_the_value('alt') : basename($imgurl);
						$image_code = wp_get_attachment_image( $imgID, get_image_size($getsize), 0, array('class' => "attachment-full", 'alt' => $alt) );
						$dummy_code = '<div class="dummy" style="margin-top: '.get_dummy_height($image_attributes[1],$image_attributes[2]).'%"></div>';
					} else {
						if (isset($imgID)) {
							$imgurl = $imgID;
							$alt = ($portfolio_mb->get_the_value('alt')) ? $portfolio_mb->get_the_value('alt') : basename($imgurl);
							$image_code = '<img src="'.$imgID.'" alt="'.$alt.'" />';
							$image_attributes = getimagesize($imgID);
							$dummy_code = '<div class="dummy" style="margin-top: '.get_dummy_height($image_attributes[0],$image_attributes[1]).'%"></div>';
						}
					}

					$caption = $portfolio_mb->get_the_value('caption');

					if ($portfolio_mb->get_the_value('panning')) $panning = ' data-fresco-options="fit: \'width\'"';
					else $panning = '';

					if ($portfolio_mb->get_the_value('video')) {

						if ($imgID && ($provider == 'Vimeo' || $provider == 'Youtube')) {

							echo $dummy_code;
						?>