WordPress.org

Ready to get started?Download WordPress

Forums

Arconix Portfolio
[resolved] Setting a square image size (4 posts)

  1. Fandabydozy
    Member
    Posted 1 year ago #

    Hi again,
    I'm trying to set the gallery image size to 200px by 200px.
    I've tried the code below but no luck.

    thumb="200, 200"
    thumb="portfolio-thumb, 200, 200"
    thumb=" 'portfolio-thumb', 200, 200"
    thumb="add_image_size, 200, 200"
    thumb="add_image_size( 'portfolio-thumb', 200, 100 )"
    thumb="add_image_size( 'homepage-thumb', 200, 200 )"

    Any help appreciated.
    Many thanks.

    http://wordpress.org/extend/plugins/arconix-portfolio/

  2. John Gardner
    Member
    Plugin Author

    Posted 1 year ago #

    The thumb parameter of the shortcode will only take an image size name. If you want to supply your own image size, you need to add it to your theme by going to your theme's functions.php files and adding the following code:

    add_image_size( my-thumb, 200, 200, true );

    you can rename my-thumb to whatever you'd like, so long as it doesn't conflict with another image name already added.

    Then reference that name in the shortcode [portfolio thumb="my-thumb"]

  3. Fandabydozy
    Member
    Posted 1 year ago #

    Many thanks again John.

  4. John Gardner
    Member
    Plugin Author

    Posted 1 year ago #

    you're welcome

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.