WordPress.org

Ready to get started?Download WordPress

Forums

Dynamic Content Gallery
First attached image display? (6 posts)

  1. wadams92101
    Member
    Posted 2 years ago #

    I posted about this a long time ago but never got a response. Its not displaying the first attached image (according to Post>Upload Image>Gallery>Order) I have it set to Auto. Any idea what's going on?

    http://wordpress.org/extend/plugins/dynamic-content-gallery-plugin/

  2. madri2
    Member
    Posted 1 year ago #

    bump, i'm looking for it too.
    When using auto, it search inside the content, and is not using the attachment

  3. madri2
    Member
    Posted 1 year ago #

    you must add the possibility to choose the size of the image displayed.
    function dfcg_grab_post_image($parent_id) {
    $args = array(
    'size' => 'full',
    'attr' => 'full',
    'num' => 0
    );
    // Get the image attachment ID
    $id = dfcg_get_image_id($parent_id, $args['num']);
    // Get the image details (returns array of src, width, height)
    $image = wp_get_attachment_image_src($id, $args['size']);
    // We only want the src
    $output = $image[0];
    return $output;
    }

    the option to change "full" to the size of our choice

  4. wadams92101
    Member
    Posted 1 year ago #

    Madri2, Thanks for posting your solution!

  5. madri2
    Member
    Posted 1 year ago #

    well in fact it IS displaying the attached picture, but since you can't change the size of it without modifying the source code, it's not practical

  6. Easy Web Scripts
    Member
    Posted 1 year ago #

    I beleave I have the same issue, but don't understand the above.

    It is Not pulling first image. I noticed it had been but that was Not the image I wanted so I added one before it, still pulls other one it had before instead.

    Any way to have it pull the featured image? This would probally work best.

    And I just cant seem to get the size right as well, Any thoughts?

    Demo: http://portnewengland.com

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic