WordPress.org

Ready to get started?Download WordPress

Forums

Coraline
[resolved] Featured image (39 posts)

  1. That's right, you need to use an FTP program to upload or download files to your host. It can be Filezilla or another program. Once you get the hang of it, FTP is quite simple to use, but I realize this is a lot of new stuff to be learning at once!

    http://codex.wordpress.org/FTP_Clients

    Why would a theme have a feature image option that seems so user friendly if this is what it takes to use it?

    I can understand that you're frustrated. Featured images don't normally need a child theme to be used. The reason it does in this case is that you're trying to override a default height set in the theme.

  2. Marcihess
    Member
    Posted 1 year ago #

    Thanks for understanding my frustration. I really wasn't trying to override a default. I thought I was trying to do exactly what was required for a featured pic (FP). The instructions for the FP state one requirement (990x400) but the program defaults it to 990x180. Truly, I was just trying to follow instructions!!

    I'm game for the "learning." I'll read up on this and download FileZilla and Keep on Truckin'!! Uh-oh -- showing my age there!!

    And....I cannot aptly express my heartfelt thanks for your assistance and patience with me. THANK YOU!!!!

  3. It's been my pleasure to help - I realize there's a learning curve here. :-)

    The instructions for the FP state one requirement (990x400)

    I'm not sure where you saw that, because the theme's default header height is 180px. If it was somewhere in any official documentation, just show me the link and I'll make sure it's updated with the correct info.

    Keep me posted on your child theme setup progress if you'd like to keep pursuing this. Good luck!

  4. Marcihess
    Member
    Posted 1 year ago #

    I am baffled where I saw that. I went looking today to see if I could recreate the moment where my head took over thinking that it was 990x400. I'll find it but haven't so far!

    You are incredibly gracious to offer and I do want to pursue setting up the child theme. I'm completely lost with the FTP set up though. I'm going to need to "chat" with my hosting company. I can only get so far and then none of the instructions match anything I'm seeing on the screen. Once I get this set up, I'll be back to work on finishing it!

  5. Marcihess
    Member
    Posted 1 year ago #

    Been pondering this and have a couple more questions...

    1) Why wouldn't it work to change the FP to 990x400 in the CSS Stylesheet Editor? Based on the language there it seems as though it would.
    2) If I can figure out how to get the Style.CSS file that you had me write into the FTP, would that be sufficient to make this change? This would be a triage move then I could have time to actually learn what I'm doing.
    3) The only reason I'm working with FTP right now is because I could only get a folder (not a file) into the hosting site, right?

    Thanks!

  6. These are good questions. Let me try to explain - it's a bit technical, so bear with me. :-)

    1) Why wouldn't it work to change the FP to 990x400 in the CSS Stylesheet Editor? Based on the language there it seems as though it would.

    This is because of the way the the height for featured images that are used as the custom header is coded into the theme. This is this relevant function in /inc/custom-header.php:

    function coraline_custom_header_setup() {
    	$args = array(
    		'default-image'          => '%s/images/headers/water-drops.jpg',
    		'default-text-color'     => '000',
    		'width'                  => apply_filters( 'coraline_header_image_width', 990 ),
    		'height'                 => apply_filters( 'coraline_header_image_height', 180 ),
    		'flex-height'            => true,
    		'wp-head-callback'       => 'coraline_header_style',
    		'admin-head-callback'    => 'coraline_admin_header_style',
    		'admin-preview-callback' => 'coraline_admin_header_image',
    	);

    The numbers you see there - 990 (width) and 180 (height) - are inserted right into the image tag, which you can see in the browser's source for the page:

    <img width="990" height="180" src="http://driftlessprairies.org/wp-content/uploads/2014/02/Bee-emerging-14featpic1.jpg" class="attachment-post-thumbnail wp-post-image" alt="Bee emerging (14){featpic}" />

    The way HTML and CSS interact, CSS is not capable of overriding those values. The number 180 needs to be changed in the image tag itself, and that's only possible with a child theme.

    2) If I can figure out how to get the Style.CSS file that you had me write into the FTP, would that be sufficient to make this change? This would be a triage move then I could have time to actually learn what I'm doing.

    The child theme has several parts, depending on what you're trying to change. The style.css file needs to be in your child theme folder, as well as a functions.php file with the function I gave you earlier. If those two files are contained within your child theme folder, and everything is coded properly and in the right place, the new height on the featured image should work. You will also need to run the Regenerate Thumbnails plugin I mentioned earlier.

    3) The only reason I'm working with FTP right now is because I could only get a folder (not a file) into the hosting site, right?

    FTP is the usual method for uploading new files and folders to a server. Sometimes a hosting control panel lets you do these things, but in your case your host seems to be telling you there are some limitations.

  7. Marcihess
    Member
    Posted 1 year ago #

    Your explanations make sense. Since I an not the author of the theme, I cannot access the html so my options for changes to the original code are via CSS and child themes. At this point, I would not know whether it was html or CSS without you telling me though!

    2 steps forward and...boom...there's that wall again!! This may be a question I need to ask somewhere else (you'll let me know if that is the case, right?). I was successful in getting the files transferred to FileZilla, but...I'm running WordPress 3.8.1 yet it is not showing up in my files. Secondly, there are 2 themes showing in wp-content, neither are Coraline. How could this be possible?

  8. I was successful in getting the files transferred to FileZilla, but...I'm running WordPress 3.8.1 yet it is not showing up in my files. Secondly, there are 2 themes showing in wp-content, neither are Coraline. How could this be possible?

    You might want to get some hands-on help at this point - someone who can look at the files on your server and/or in your dashboard and see what's going on. Your host may be able to provide that assistance, or you could consider hiring a freelance WordPress expert.

    The other option is to just live with the 180px height on featured images, if this isn't something you want to pursue further. If you upload a shot of bees that's 990 by 180, it won't be stretched, and it'll still look good.

    Child theming opens up many doors in terms of customizing your theme, but if you only need to make one little change, it might not be worth the time - you'll need to be the judge of that. :-)

    Good luck with this whatever route you choose! If you have other questions about Coraline feel free to start a new thread.

  9. Marcihess
    Member
    Posted 1 year ago #

    You've been wonderful to help me this far. Thank you very much!

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags

No tags yet.