• Resolved dotherightthing

    (@dotherightthing)


    Hi, is it possible to access the (maximum) width and height of gallery images in PHP, as set by the WP admin in the NextGen gallery ‘Image settings’ tab?

    Gallery > Options > Images > Image Settings

    I have a horizontally scrolling div, and I’d like to be able to dynamically set the width of the container by multiplying count($images) by the maximum width of the enlargement images.

    The reason I am not doing this with JavaScript is because this is the styling for the noscript fallback 🙂

    Thanks,
    Dan

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter dotherightthing

    (@dotherightthing)

    Have got the thumbnail dimensions code – I think this will do me for now:

    $thumbwidth = $ngg_options[thumbwidth];
    $thumbheight = $ngg_options[thumbheight];

    Thread Starter dotherightthing

    (@dotherightthing)

    I found the answer:

    $ngg_options = nggGallery::get_option('ngg_options'); // from nggfunctions.php
    echo( $ngg_options['imgWidth'] . 'x' . $ngg_options['imgHeight'] ); // eg '600x400'

    HTH someone 🙂

    Dan

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘[Plugin: NextGEN Gallery] Accessing ‘Image settings’ dimensions’ is closed to new replies.