' . $imgsHTML . abcf_lib_html_div_clr() . ''; $js = abcfal_cntbldrs_gallery_js(); return $divGridCntr . $js; } function abcfal_cntbldrs_get_data( $collID ){ $collURL = abcfic_dbu_coll_url($collID); $dbRows = abcfal_db_images($collID); $imgsHTML = ''; if ($dbRows) { foreach ( $dbRows as $dbRow ) { $imgsHTML .= abcfal_cntbldrs_data_item($collURL, $dbRow->img_id, $dbRow->filename, $dbRow->alt, $dbRow->img_title, $dbRow->thumb_w, $dbRow->thumb_h); } } else{ //Count images $imgQty = abcfic_dbu_count_published($collID); if(empty($imgQty)){ return abcf_err_2part_msg( abcfal_txtbldr(13) );} $all = $imgQty['all']; $published = $imgQty['published']; if($all == 0){ //Collection is empty. return abcf_err_2part_msg( abcfal_txtbldr(14) ); } if($published == 0){ //All images have status: Unpublished. return abcf_err_2part_msg(abcfal_txtbldr(15), abcfal_txtbldr(16)); } } return $imgsHTML; } function abcfal_cntbldrs_data_item($collURL, $imgID, $filename, $alt, $imgTitle, $thumb_w, $thumb_h) { if (empty($filename)) { return ''; } $cntrS = '
'; $cntrE = '
'; $aStart = ''; $thumbImgTag = abcf_lib_img_html_tag('', $imgT, $alt, $imgTitle, $thumb_w, $thumb_h ); return $cntrS . $aStart . $imgHREF . $thumbImgTag . $aEnd . $cntrE; } function abcfal_cntbldrs_gallery_js(){ //------------------------------------------------------ $out = '