function getText($id) { return \cf\query2var("SELECT txt FROM cf_page WHERE id=:id", array('id' => \cf\Page::getID($id))); }
function getImages($albumId, $showHidden = false) { $albumId = \cf\Page::getID($albumId); return \cf\query2arrays("\r\n\t\tSELECT cf_gallery_images.id AS id, IFNULL(code,cf_gallery_images.id) AS code, name, image, short_descr, hidden, url\r\n\t\tFROM cf_gallery_images\r\n\t\tINNER JOIN cf_gallery_image_in_album ON cf_gallery_images.id=cf_gallery_image_in_album.image_id\r\n\t\tWHERE cf_gallery_image_in_album.album_id=:aid\r\n\t\tORDER BY sort_order", array('aid' => $albumId)); }