WordPress.org

Ready to get started?Download WordPress

Forums

Jetpack by WordPress.com
[resolved] Centering Square Tiles / Carousel (8 posts)

  1. wp510
    Member
    Posted 11 months ago #

    Hi,

    How do I get the square tile gallery to center align on my page?

    Thanks.

    http://wordpress.org/plugins/jetpack/

  2. Jeremy Herve
    Happiness Engineer
    Plugin Author

    Posted 11 months ago #

    You could use CSS to center the whole gallery, but instead I would suggest that you add a $content_width variable so that the gallery uses the whole width available in your theme's content area.

    To do so, just add the following to your theme's functions.php file:

    if ( ! isset( $content_width ) )
    	$content_width = 600;

    Of course, you'll want to adjust the value to your own theme.

    You can read more about it here:
    http://codex.wordpress.org/Content_Width

    If you do not want to make changes to your theme, you can use this plugin instead:
    http://wordpress.org/plugins/custom-content-width/

  3. wp510
    Member
    Posted 11 months ago #

    Thanks for the response - so in my website's case the gallery does use the whole content area width, but (in the desktop view of the page) the thumbnails don't quite have enough room to fit in to one more column on the right; so there is a white space on the right that is a little narrower than the width of each gallery thumbnail.

    How can I reduce the size of the thumbnails so I get that extra column on the right?

    Thanks!

  4. Richard Archambault
    Happiness Engineer
    Plugin Author

    Posted 11 months ago #

    Could you post your site URL here, so I can have a look?

  5. wp510
    Member
    Posted 11 months ago #

    Here!

    Thanks for your help,
    -wp510

  6. Richard Archambault
    Happiness Engineer
    Plugin Author

    Posted 11 months ago #

    There's not enough room on the right, because the div#container includes a padding of 50px. You could try to reduce the padding on the right by 12 pixels or so (so, 38 pixels or less), and make section#content 972px wide or a touch more, that might do the trick.

  7. wp510
    Member
    Posted 11 months ago #

    Thanks for your help, I fixed it!
    -wp510

  8. Richard Archambault
    Happiness Engineer
    Plugin Author

    Posted 11 months ago #

    Awesome, it looks good!

Reply

You must log in to post.

About this Plugin

About this Topic