Viewing 3 replies - 1 through 3 (of 3 total)
  • Benjamin

    (@benjaminowens)

    The following should work:

    $gallery_id     = 3; // for example
    $gallery_mapper = C_Gallery_Mapper::get_instance();
    $image_mapper   = C_Image_Mapper::get_instance();
    $storage        = C_Gallery_Storage::get_instance();
    $gallery        = $gallery_mapper->find($gallery_id);
    $image          = $image_mapper->find($gallery->previewpic);
    var_dump($image);
    var_dump($storage->get_image_url($image, 'thumb'));
    var_dump($storage->get_image_url($image, 'full'));

    I hope it helps!

    Thread Starter bhenselmann

    (@bhenselmann)

    Yes – Thanks a lot, Benjamin!

    Plugin Contributor photocrati

    (@photocrati)

    @bhenselmann – Thanks for the update.

    – Cais.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How to catch the preview image of a gallery?’ is closed to new replies.