Add in auto-generate facility to gallery handler.
This commit is contained in:
parent
97c4afdda9
commit
f1a9142335
@ -191,6 +191,14 @@ void gallery_handler( struct gallery_info* gallery,
|
||||
hdf_set_value( cgi->hdf, "gallery.title", gallery->gallery_title );
|
||||
hdf_set_value( cgi->hdf, "gallery.desc", gallery->gallery_desc );
|
||||
hdf_set_int_value( cgi->hdf, "photos", contents->photos->length );
|
||||
|
||||
/* Are we generating the gallery? */
|
||||
if ( hdf_get_int_value( cgi->hdf, "Query.generate", 0 ) ) {
|
||||
/* We will do this ignoring the ClearSilver library */
|
||||
printf("Location: %s/gallery.cgi/%s/%s?generate=1\n\n", get_cgiuri(),
|
||||
gallery->gallery_name, contents->photos->string[0] );
|
||||
return;
|
||||
}
|
||||
|
||||
size_t i;
|
||||
struct photo_info photo;
|
||||
|
Loading…
Reference in New Issue
Block a user