Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter djjuvan

    (@djjuvan)

    Bumping, cuz it’s important!

    Thread Starter djjuvan

    (@djjuvan)

    Is it even possible to add shortcode outside the post editor? I dont know, or my hope for this too high?

    Try modifying your template, calling the nextgen random image function where you want the images to be displayed. Here is the function you need:
    nggDisplayRandomImages($number, $width, $height, $exclude, $list)

    $number: the number of pics you want to display, there is no default, so you have to provide this. You want to specify 4 images.
    $width: the width of each picture, defaults to 75 if you don’t provide anything
    $height: the height of each picture, defaults to 50 if you don’t provide anything
    $exclude: gallery restriction type:
    all means include all galleries
    denied means deny the galleries in $list
    allow means only allow the galleries in $list
    $list: gallery IDs affected by your $exclude

    This example uses 4 random images, 130px wide by 85px high, from gallery ID 5:
    nggDisplayRandomImages("4","130","85","allow","5")

    Reference:
    https://www.vuthy.com/blog/2008/11/16/nextgen-gallery-random-photos-from-a-specific-gallery/#instructions.
    The above post is old, but it should help.

    Good luck!

    Or…
    https://nextgen-gallery.com/2009/02/23/two-new-shortcodes/

    But I don’t think you can specify the gallery.

    Thread Starter djjuvan

    (@djjuvan)

    wow, i’ll try this out!

    Thank you very much! Life saver =)

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: NextGEN Gallery] Shortcodes in single template’ is closed to new replies.