Okay
  Public Ticket #224239
Gallery Thumbnails
Closed

Comments

  • Cathy started the conversation

    Is there any way I can adjust the content of the thumbnails in the gallery? It's really awkward to have people's heads cut off in them. 

  •  296
    Paul replied

    Hi,

    Please try the followings:

    1. Open "/includes/theme-functions.php" file.

    2. Find this code:

    add_image_size( 'theme-large-square', 400, 400, true );
    add_image_size( 'theme-medium-square', 280, 280, true );
    add_image_size( 'theme-small-square', 120, 120, true );

    3. Change the value from "true" to "false". This will disable the "cropping" feature of WordPress when generating thumbnails.

    4. Reupload all the images and put the gallery into the page once again.

    This should help!

    Cheers,
    Paul

  • Cathy replied

    Tried it and it didn't fix the problem.  I did make a child theme, so not sure that would effect it, but I essentially copied everything from the original theme folder into the new theme folder.  I edited the theme-functions.php file within the child theme "includes" folder.  Removed all images from the gallery on the page, and then also from the media library.  Started the gallery again and uploaded each image again.  Still heads cut off - still cropping.  I had even gone into the WordPress Media settings and unchecked the box that says crop thumbnails.

    Boo.  I'm sure my client won't like the way these look.  Too bad because the gallery is such a cool feature.

  •  296
    Paul replied

    Well, actually editing that code works... I would suggest to copy only the template files or some functions (that you want to modify) of the parent into the child theme's, not all the files, because some code might still refer to the parent's unless you change it. 

    For example, if you look into "functions.php" file you will see that it is using "get_template_directory()" function for including any other required PHP files and this function will search the files in the parent theme's directory. It means that even you have edited the included files in child theme, it still get the files from the parent's. You might need to use the function of "get_stylesheet_directory()" for the child theme instead. Here is the doc about the function: http://codex.wordpress.org/Function_Reference/get_...

    Just in case you are not sure about how to implement child theme, I would recommend to find a developer/freelancer to help you out on the theme customization.

  • Cathy replied

    Thank you for your persistence.  I did get it to work!  Yey!  It seems that sometimes, it's not enough to just make a CSS file for the child theme.  So I started with just the child CSS and the gallery wouldn't lay out right.  I just kept adding certain files into the child theme folder, trying to keep it minimal, until everything worked right.  That's the non-programmer to handle it :-)  Anyway, I'm happy and client is happy!

  •  296
    Paul replied

    Awesome! Glad to hear that you have figured it out! :)