Community Forums › Forums › Archived Forums › Design Tips and Tricks › Custom post type archive loading some posts outside of content div
- This topic has 2 replies, 2 voices, and was last updated 10 years, 4 months ago by Au Coeur.
-
AuthorPosts
-
June 6, 2014 at 12:48 am #108285Au CoeurMember
On http://www.mobanetwork.org/new/members/ I cannot figure out why half of the posts are loading as they should within the content div and half are loading after the content-sidebar-wrap. It is very strange. Has anyone seen this before?
Mother. Web & Graphic Designer. Lactation Consultant. Blogging about how it all fits together, most recently from northern Colorado. Visit my blog or my design site.
June 6, 2014 at 3:43 pm #108393rfmeierMemberHello,
It looks like the
float: right;
on the .content wrapper element may be causing some issues. I was able to correct it with a change in the style.css;.content { background: #fff url(images/pattern-light.png); background-size: 10px 10px; float: none; /* changed to none from right */ padding: 0; width: 760px; }
Hope this helps.
Was this page meant to have a sidebar? I started thinking about why the main content would have a float: right property assigned.
June 6, 2014 at 5:09 pm #108408Au CoeurMemberChanging the float does not impact half of the posts rendering outside of the content-sidebar-wrap. This is a custom post type archive and it seems to be ignoring some of my settings on the archive page, which may be associated to this issue?
This is what I have in archive-member.php
<?php /** * This file adds the custom member post type archive template to the MOBA Theme. * * @author Au Coeur Design */ /* Template Name: Member Archive */ //* Force full-width-content layout setting add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' ); //* Remove the breadcrumb navigation remove_action( 'genesis_before_loop', 'genesis_do_breadcrumbs' ); //* Remove the post info function remove_action( 'genesis_entry_header', 'genesis_post_info', 5 ); //* Remove the post content remove_action( 'genesis_entry_content', 'genesis_do_post_content' ); //* Remove the post image remove_action( 'genesis_entry_content', 'genesis_do_post_image', 8 ); //* Add member body class to the head add_filter( 'body_class', 'executive_add_member_body_class' ); function executive_add_member_body_class( $classes ) { $classes[] = 'executive-pro-member'; return $classes; } //* Add the featured image after post title add_action( 'genesis_entry_header', 'executive_member_grid' ); function executive_member_grid() { if ( $image = genesis_get_image( 'format=url&size=portfolio' ) ) { printf( '<div class="portfolio-featured-image"><a href="%s" rel="bookmark"><img src="%s" alt="%s" /></a></div>', get_permalink(), $image, the_title_attribute( 'echo=0' ) ); echo strip_tags(the_excerpt($post- id)); } } //* Remove the post meta function remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); genesis();
For some reason, it is ignoring the forced full-width command. I actually hid the sidebar with CSS. That is probably why you see the float.
Any other ideas?
Mother. Web & Graphic Designer. Lactation Consultant. Blogging about how it all fits together, most recently from northern Colorado. Visit my blog or my design site.
-
AuthorPosts
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.