/** * Return a JSON coded array of Image ids for a requested gallery * * @param int $galleryID * @return array (JSON) */ static function get_image_ids($galleryID) { if (!function_exists('json_encode')) { return -2; } $gallery = flagdb::get_ids_from_gallery($galleryID, 'pid', 'ASC', false); header('Content-Type: text/plain; charset=' . get_option('blog_charset'), true); $output = json_encode($gallery); return $output; }