How to set Featured Image to float left
-
I want to change the position of the featured image for blog post list/archive/search and cannot figure it out.
Originally, the theme was designed to display, in this order:
1. Featured image
2. Post header
3. Post date, # of comments
4. ExcerptIn my child theme I have managed to alter the content.php to rearrange the display to:
1. Post header
2. Post date, # of comments
3. Featured image
4. ExcerptHowever, I would also like the image to float left. I cannot figure out how to do this, whether I can do this in the content.php or if I have to also alter the CSS. Any help would be appreciated.
Here is the code for content.php:
<?php /** * The default template for displaying content * * Used for both single and index/archive/search * * @package Catch Themes * @subpackage Clean Box * @since Clean Box 0.1 */ ?> <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> <div class="entry-container"> <header class="entry-header"> <h1 class="entry-title"><a href="<?php the_permalink(); ?>" rel="bookmark"><?php the_title(); ?></a></h1> <?php if ( 'post' == get_post_type() ) : ?> <?php clean_box_entry_meta(); ?> <?php endif; ?> </header><!-- .entry-header --> <div class="archive-post-wrap"> <?php /** * clean_box_before_entry_container hook * * @hooked clean_box_archive_content_image - 10 */ do_action( 'clean_box_before_entry_container' ); // Get the Excerpt $cleanbox_excerpt = get_the_excerpt(); ?> <?php $options = clean_box_get_theme_options(); if ( is_search() || ( 'full-content' != $options['content_layout'] && !empty( $cleanbox_excerpt ) ) ) : // Only display Excerpts for Search and if 'full-content' is not selected ?> <div class="entry-summary"> <?php the_excerpt(); ?> </div><!-- .entry-summary --> <?php else : ?> <div class="entry-content"> <?php the_content(); ?> <?php wp_link_pages( array( 'before' => '<div class="page-links"><span class="pages">' . __( 'Pages:', 'clean-box' ) . '</span>', 'after' => '</div>', 'link_before' => '<span>', 'link_after' => '</span>', ) ); ?> </div><!-- .entry-content --> <?php endif; ?> <footer class="entry-footer"> <?php clean_box_tag_category(); ?> </footer><!-- .entry-footer --> </div><!-- .archive-post-wrap --> </div><!-- .entry-container --> </article><!-- #post -->
- The topic ‘How to set Featured Image to float left’ is closed to new replies.