-
AuthorPosts
-
June 19, 2014 at 2:24 am #58207
Hi,
I would like my video posts to have a playable video in the posts page in the place where featured image usually comes (such as I can find in Integrity and other stacks) within the Ethos stack. So, not the single post page but rather to be able to play video of the each post in case I’m featuring my video posts on the front page (rather than having a static page). Is this possible? The space for the featured image/video remains empty on my posts page regardless of embedded video or post type.
Tnx!
June 19, 2014 at 4:14 pm #58555Hi Johann,
Thank you for writing in!
For that, follow these steps.
1. Install an ethos child theme if you still don’t have it.
2. Create a file named content-video.php at your child theme (eg. /x-child-ethos/framework/views/ethos/content-video.php)
3. Edit your new content-video.php and paste this code replacing any existing.<?php // ============================================================================= // VIEWS/ETHOS/CONTENT-VIDEO.PHP // ----------------------------------------------------------------------------- // Video post output for Ethos. // ============================================================================= $is_index_featured_layout = get_post_meta( get_the_ID(), '_x_ethos_index_featured_post_layout', true ) == 'on' && ! is_single(); ?> <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> <?php if ( $is_index_featured_layout ) : ?> <?php x_ethos_featured_index(); ?> <?php else : ?> <?php if ( has_post_thumbnail() && ! is_single() ) : ?> <div class="entry-featured"> <?php x_featured_video(); ?> </div> <?php elseif ( is_single() ) : ?> <div class="entry-featured"> <?php x_featured_video(); ?> </div> <?php endif; ?> <div class="entry-wrap"> <?php x_get_view( 'ethos', '_content', 'post-header' ); ?> <?php x_get_view( 'ethos', '_content' ); ?> </div> <?php endif; ?> <?php x_google_authorship_meta(); ?> </article>
4. Save and upload.
Hope this helps.
June 20, 2014 at 9:37 am #58839Hi,
thank you for your input but I’m afraid this doesn’t work. I installed the child theme and added content-video.php file with this code, but still nothing.
In case I wasn’t clear enough, I want all posts listed on the index page to have the video instead of a featured image, which needs to be pulled from the embed code I entered in the Embedded Video Code custom field, while post being assigned as Video Format. (I see this runs perfectly in all other stacks)
When inspecting element on the site, I see that my post is defined as no-post-thumbnail, which is, to my understanding of the code you provided, required to actually run the code properly.
So bottom line question is, how do I set the featured video? There’s no meta field in the editor for that, and it’s not taking my already embedded video. Am I doing/looking something wrong?Thank you!
June 20, 2014 at 1:38 pm #58938Ok, so I managed to get it playable, which works only if Post is not Fullwidth Index Featured Post.
Is there a way to set it up like this: http://tinypic.com/r/nltsth/8 ? Right now the player is very small.June 21, 2014 at 8:55 pm #59361Hey Johann,
Can you give us the URL of your site so we could see the current setup?
Thanks.
June 22, 2014 at 10:17 am #59527Sure, the site is restarttv.devtroopers.com
I managed to set videos on the front page to be full-width, but viewing any category is turning them into thumbnails (see any of the menu items-categories).
Also, do I have to manually input post ID’s of featured posts every time there’s a post I want to feature on carousel/slider, or is there a way to do that through post editor? I can’t use Index featured post option due to aforementioned video display problem…
June 23, 2014 at 10:56 am #59980Hi Johann,
This should still work on category pages with the code above. Would you mind providing us with login credentials so we can take a closer look? To do this, you can make a post with the following info:
– Link to your site
– WordPress Admin username / password
– FTP credentialsDon’t forget to select Set as private reply to ensure that your data remains hidden
June 23, 2014 at 12:34 pm #60031This reply has been marked as private.June 24, 2014 at 4:02 pm #60559Hi Johann,
Added a css at your customizer that fix your category videos.
Cheers!
-
AuthorPosts