Using Gallery Alias Name as Page Title
Submitted by hmiles on Tue, 2007-10-09 17:24.
The pictures in our galleries are indexed by our search engine and when the results come back, they use the page title as the name for the link.
Right now, the title for all of the pages when viewing images is the site name. We would like to use the name of the gallery where the picture came from.
We are using the borders template and I found the line of code we need to modify in the imageview.tpl.php file:
<? print $site_name; ?>
I believe it needs to be replaced with:
<? print $dir['name']; ?>
which is used further down in the file. However, when we use the replacement code, the title comes up blank when viewing an image.
Please help! Thanks!
Harry
digphilly.com

error-reports
hello,
I have installed phpalbum to a webserver included about 5 Gigabytes of data. It worked really fine but since today two error-reports were seen on the screen like these :
Parse error: parse error, unexpected $ in /var/www/web189/html/phpAlbum/phpdatabase.php(580) : runtime-created function on line 2
Fatal error: Call to undefined function: () in /var/www/web189/html/phpAlbum/phpdatabase.php on line 705
Could you help me and find out what to do ? I really had hard work with uploading for several days, and it would be a pity if nothing can go on.
So long,
Peter from Neuss, Germany
Hello Peter, i just sent you
Hello Peter,
i just sent you an answer to your email ... please try that debug-phpdatabase.php file and give me feedback about the result...
Patrik
debug-pgpdatabase
hello patrik,
I just answered to your email. Thx a lot for your quick answer.
The debug-report is quite long, that´s the reason why I sent it via email.
greetings
Peter
Hello Harry, in
Hello Harry,
in imageview.tpl.php and in album.tpl.php you must print following for title:
print $dir_path[sizeof($dir_path)-1]['name'];
which is the name of the last directory in the path ...
Greets,
Patrik
p.s. in the next version I'll try to do it even better with displaying of picture name and directory and site name together, somehow configurable of course ...
Thanks!
Thanks Patrik!
The code worked like a charm. You have a great application here and I look forward to the next release :)
Harry Miles
digphilly.com
Hi there
Thank you for the Album its very easy to use and powerfull spent many days looking for one but this is my favorite choice I am getting this error I oly got 5 folder name folder1 etc... but I received this error
Parse error: syntax error, unexpected $end in /home/theparty/public_html/phpdatabase.php(580) : runtime-created function on line 2
Fatal error: Call to undefined function: () in /home/theparty/public_html/phpdatabase.php on line 705
Thanks
Thanks Patrik! The code
Thanks Patrik!
The code worked like a charm. You have a great application here and I look forward to the next release :)
http://www.trsohbet.name