Community Forums › Forums › Archived Forums › Design Tips and Tricks › Home-top featured image not spanning entire area on homepage – Metro Pro
Tagged: featured images, home-top, Metro Pro
- This topic has 7 replies, 3 voices, and was last updated 10 years, 6 months ago by
nomad_jess.
-
AuthorPosts
-
August 21, 2014 at 7:44 am #120206
nomad_jess
MemberHi there,
I'm using Metro Pro and am having an issue with the home-top featured image. It doesn't span across the entire image area, meaning that there is an increased gap between it and the sidebar. This is only an issue on the homepage. When you click through to any post, the gap is gone.
How can I get the featured post in the home-top section to display normally on the homepage?
Many thanks in advance!
http://notesofnomads.comAugust 21, 2014 at 8:40 am #120210AnitaC
KeymasterAugust 21, 2014 at 9:07 am #120214nomad_jess
MemberHi Anita,
Many thanks for the suggestion. I wrote something similar on another thread regarding a different issue, but I'll clarify again here. What I don't understand is that this image is (as are all featured images on our site) actually larger than the area in question. In fact, it displayed fine when I first installed the theme. I'm not sure if other coding I have touched has impacted its display. It should really be "downscaling" rather than "upscaling" (I totally get why that wouldn't work). If I can avoid installing another plugin by being able to tweak some code, I'd prefer it if possible.
Many, many thanks in advance for all your help. REALLY appreciate it!
August 21, 2014 at 9:24 am #120220AnitaC
KeymasterInstall the plugin, run it and then deactivate it and remove it. That will fix the issue.
Need help with customization or troubleshooting? Reach out to me.
August 21, 2014 at 10:58 am #120253nomad_jess
MemberHi Anita,
Thank you. I ran the plugin and while it helped resolved the issue that we've been discussing on another thread, it unfortunately didn't fix this one.
As I mentioned, it was displaying correctly when I installed the theme and it is only this image location that is affected (no matter which post I choose to place there). So I feel like it must be some coding I have touched subsequently and didn't realise that it had affected this area at the time.
Any ideas as to the code that might be affecting the span of the home-top featured image?
Thanks so much for all your help!
August 21, 2014 at 9:48 pm #120393Lauren @ OnceCoupled
MemberWhat size is your featured image set to in the widget? Just to confirm, it's set to "home-top" which says "700 x 400" in parentheses, correct?
We create mobile-first, PageSpeed-optimized, pixel-perfect custom themes! https://www.oncecoupled.com
August 22, 2014 at 12:24 am #120415nomad_jess
MemberHi Lauren,
Thanks so much for responding.
There is reference to the home-top image being that size in the functions.php file:
//* Add new image sizes
add_image_size( 'home-bottom', 150, 150, TRUE );
add_image_size( 'home-middle', 332, 190, TRUE );
add_image_size( 'home-top', 700, 400, TRUE );However, in the style.css file, there doesn't seem to be any specific dimensions listed. I was looking at the following two sections of code:
/*
Widgets
---------------------------------------------------------------------------------------------------- *//* Featured Content
--------------------------------------------- */.featured-content .entry {
background: none;
margin-bottom: 16px;
padding: 0;
}.featured-content .entry p,
.home-bottom .featured-content {
margin-bottom: 0;
}.featured-content .entry-title {
margin-bottom: 8px;
}.home-bottom .featured-content .entry-title {
margin: 8px 0;
}.home-bottom .featured-content .widget-title {
margin-bottom: 20px;
}.home-bottom .featured-content .entry {
border-bottom: 5px solid #f5f5f5;
}.metro-pro-home .home-bottom .entry {
margin-bottom: 20px;
padding-bottom: 20px;
}.home-bottom .featured-content .entry-content p,
.home-bottom .featured-content img {
margin-bottom: 0;
}and...
/*
Content Area
---------------------------------------------------------------------------------------------------- *//* Home Page
--------------------------------------------- */.home-middle {
overflow: hidden;
}.home-middle-left,
.home-middle-right {
width: 332px;
}.home-middle-left {
float: left;
}.home-middle-right {
float: right;
}Does something need to be added here (or elsewhere)?
Many thanks in advance!
Jess
August 24, 2014 at 12:36 pm #120798nomad_jess
MemberThis issue has somehow magically resolved itself. Whatever happened, it now displays correctly. Thanks all for your input. Really appreciate it.
-
AuthorPosts
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.