Hi, I'm trying to swap the default home page with images of my choice. I think I could achieve it in one of two ways: either displaying images with a particular tag, e.g 'start'; or creating a gallery which would be excluded from the list of galleries and shown only on the first page (the later seems to be more work).
The thing is I can't find in the documentation how I could display filtered image list (with both link, and description).
Is there any easy way to achieve this goal? Thanks in advanced.
Comments
Thanks in advanced.
Once you have done a search returning what you want in the dynamic album click on the admin toolbox link on the search page. The dropdown will have a link to create an album.
See the user rights tutorial on the user guide.
I've figured out how to use the dynamic album feature. The thing is that it works only on the list of albums. I tried to include it in the index.php with new Album() method:
`
$albumobject = new Album($galleryobject,"startpage.alb");
var_dump($albumobject);
`
but the dumped object is empty:
`
{ ["name"]=> string(13) "startpage.alb" ["localpath"]=> string(47) "/public_html/albums/startpage.alb" ["exists"]=> bool(true) ["images"]=> NULL ["parent"]=> NULL ["parentalbum"]=> NULL ["gallery"]=> object(Gallery)#10 (7) { ["albumdir"]=> string(34) "/public_html/albums/" ["albums:protected"]=> NULL ["theme:protected"]=> NULL ["themes:protected"]=> NULL ["lastalbumsort:protected"]=> NULL ["data:protected"]=> array(23) { ["gallery_sortdirection"]=> int(0) ["gallery_sorttype"]=> string(2) "id" ["gallery_title"]=> string(23) "Gallery" ["Gallery_description"]=> string(45) "About
/admin/options/gallery/description" ["gallery_password"]=> NULL ["gallery_user"]=> NULL ["gallery_hint"]=> NULL ["hitcounter"]=> NULL ["current_theme"]=> string(7) "zenpage" ["website_title"]=> string(23) "Gallery" ["website_url"]=> string(0) "" ["gallery_security"]=> string(6) "public" ["login_user_field"]=> bool(false) ["album_use_new_image_date"]=> int(1) ["thumb_select_images"]=> int(1) ["persistent_archive"]=> int(0) ["unprotected_pages"]=> string(98) "a:5:{i:0;s:5:"index";i:1;s:10:"normalizer";i:2;s:7:"gallery";i:3;s:7:"contact";i:5;s:7:"archive";}" ["album_publish"]=> int(1) ["image_publish"]=> int(1) ["album_session"]=> int(0) ["multilevel_thumb_select_images"]=> int(1) ["sort_direction"]=> int(0) ["codeblock"]=> string(39) "a:3:{i:1;s:0:"";i:2;s:0:"";i:3;s:0:"";}" } ["unprotected_pages:protected"]=> array(5) { [0]=> string(5) "index" [1]=> string(10) "normalizer" [2]=> string(7) "gallery" [3]=> string(7) "contact" [5]=> string(7) "archive" } } ["searchengine"]=> NULL ["sidecars"]=> array(0) { } ["manage_rights"]=> int(8388608) ["manage_some_rights"]=> int(262144) ["view_rights"]=> int(512) ["subalbums:protected"]=> NULL ["index:protected"]=> NULL ["lastimagesort:protected"]=> NULL ["lastsubalbumsort:protected"]=> NULL ["albumthumbnail:protected"]=> NULL ["subrights:protected"]=> NULL ["dynamic:protected"]=> bool(true) ["comments"]=> NULL ["commentcount"]=> NULL ["data"]=> array(37) { ["id"]=> string(2) "15" ["parentid"]=> NULL ["folder"]=> string(13) "startpage.alb" ["title"]=> string(9) "startpage" ["desc"]=> string(0) "" ["date"]=> string(19) "2012-06-07 15:42:56" ["updateddate"]=> NULL ["location"]=> string(0) "" ["show"]=> string(1) "1" ["closecomments"]=> string(1) "0" ["commentson"]=> string(1) "0" ["thumb"]=> string(1) "1" ["mtime"]=> string(10) "1339080176" ["sort_type"]=> string(0) "" ["subalbum_sort_type"]=> string(0) "" ["sort_order"]=> NULL ["image_sortdirection"]=> string(1) "0" ["album_sortdirection"]=> string(1) "0" ["hitcounter"]=> string(1) "0" ["password"]=> string(0) "" ["password_hint"]=> string(0) "" ["publishdate"]=> NULL ["expiredate"]=> NULL ["total_value"]=> string(1) "0" ["total_votes"]=> string(1) "0" ["used_ips"]=> NULL ["custom_data"]=> string(0) "" ["dynamic"]=> string(1) "1" ["search_params"]=> string(51) "words=start&searchfields=tags&inalbums=0&inimages=1" ["album_theme"]=> NULL ["user"]=> NULL ["rating"]=> NULL ["rating_status"]=> string(1) "3" ["watermark"]=> NULL ["watermark_thumb"]=> NULL ["owner"]=> string(3) "lea" ["codeblock"]=> string(39) "a:3:{i:1;s:0:"";i:2;s:0:"";i:3;s:0:"";}" } ["updates"]=> array(0) { } ["loaded"]=> bool(true) ["table"]=> string(6) "albums" ["unique_set"]=> array(1) { ["folder"]=> string(13) "startpage.alb" } ["cache_by"]=> string(13) "startpage.alb" ["id"]=> int(15) ["use_cache"]=> bool(true) ["transient"]=> bool(false) ["tempdata"]=> array(0) { } }`
I don't see here any images either filenames or ids
Alternatively you could use makeAlbumCurrrent() (view the doc for the correct name and usage) to make it a current album and then use the image and/or album loops (you read about these on the theming tutorial).
http://www.php.net/manual/en/language.oop5.php
Then you need to review our function documentation which methods the album and image class have you can use.
Sorry, we can't take you by the hand with this. The easiest for you is to make the album current and use the loops. BAsic php knowledge is not avoidable, sorry.
For instance, if you really understand object programming you would not be suprised that there are no images listed when no method has been invoked that would populate the images.
You might also want to put your arrogance on hold and pay attention to what acrylian has suggested as the best approach for you.
No intention to offend anyone. Honestly, I think it's not systematic enough for someone who wants to customize a core theme quickly and is dealing with the script for the first time. I reached my goal according to your advice. Otherwise I would do it in a less elegant manner. Great thanks for your help. Peace, no need for flames.
So I would like to repeat that you are welcome to provide documentation on what you think is missing. But if you get into the object model you will see that you most likely don't know where to stop as you can do quite a lot things with it. Putting out images is the simplest actually.