• Featured video plsu works exactly as described, and it even works w the responsive video plugin. So it’s great to see two nice clean examples of plugins.

    Sadly, I’m having a little trouble navigating an if/else php statement for my single.php file. my own fault for being rusty/timid on my php skills/following up on someone else’s fussy them dev.

    I’ve selected to use the manual application of featured video plus, as I only want the video to appear in my single.php instance

    As noted: I’m following up on another developers work, and they’ve been unresponsive – so hopefully I can sort this out here.

    Here is the single.php file area needing help:

    <?php
    	if ( have_posts() ) : while ( have_posts () ) : the_post();
    		?>
    		<article id="post-<?php the_ID(); ?>" <?php post_class('entry group'); ?>>
    				<h1  class="section-title"><span><?php the_title(); ?></span></h1>
    
    <!-- I need some php here that says if you've got the video, show the video-->
    <!--if there isn't a video, just do this shit below-->
    
    			<?php if ( ci_has_image_to_show() ) : ?>
    				<figure class="entry-featureImage">
    					<?php $img_url = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'full' ); ?>
    					<a href="<?php echo $img_url[0]; ?>" rel="prettyPhoto">
    						<?php ci_the_post_thumbnail(); ?>
    					</a>
    				</figure>
    
    			<?php endif; ?>

    I’m not 100% clear on using the php functions/callbacks of featured video plus.
    I know it says to use it “exactly like calling featured_image” – however I need a working example, and not an assumed knowledge of php. PLEASE – assume nothing.

    I need my single.php if statement, changed into a if else statement so that IF I have a featured video – USE that, else, if i have one, USE the featured image.

    YES – I’m manually attaching a featured image AND SOME posts also have a featured video. This is a very front end specific need.

    Why is this necessary?
    I use static image thumbs on cats,home, indexes… and do not want video being replaced at every instance of a featured image.
    To compound matters, I’d prefer the evaluative php statement to use a full size featured image OR the featured video in a specifically styled article header in single view.
    Of course, we will have a few editors, that need to focus on content entry, so once this is smoothed out, they can follow consistent instructions accordingly.

    Thank you very much, I’ll be dusting off my chops / breaking my single.php until someone says otherwise ??

  • The topic ‘Featured Video Plus show featured image OR featured video’ is closed to new replies.