Get a list of galleries from an album in NextGEN Gallery [closed]

Put this into your page template:

<?php
    global $nggdb;
    $galleries = array();

    $album = $nggdb->find_album(1);

    foreach( $album->gallery_ids as $galleryid ){
        $gallery = $nggdb->find_gallery($galleryid);
        $galleries[$galleryid]['title'] = $gallery->title;
        $galleries[$galleryid]['url'] = get_bloginfo('url') . '/portfolio/?album=all&gallery=' . $galleryid;
    }

    foreach($galleries as $category){
        echo '<a href="' . $category['url'] . '">' . $category['title'] . '</a><br />';
    }
?>

You have to adapt the album id and you need to link to a page where the album code of NGG is active.

All functions can be found in /wp-content/plugins/nextgen-gallery/lib/ngg-db.php.