forum.coppermine-gallery.net

Support => cpg1.5.x Support => cpg1.5 miscellaneous => Topic started by: biellebrunner on July 16, 2015, 02:29:33 am

Title: Name displayed on browsers
Post by: biellebrunner on July 16, 2015, 02:29:33 am
I apologize in advance if there's already any info on this, cause I didn't even know how to look it up, so I'll try to explain.
When I'm on an album on my gallery, the title displayed on my browser tab is something like "Album name - Gallery name". When on a single photo, it's "Album name - File name - Gallery name". When it's a category, it's "Home > Parent category > Category - Gallery name".
Is there any way to change this format? Can I have the Gallery name at the beginning? Can I omit the file name? Is any customization possible at all?
Thank you.
Title: Re: Name displayed on browsers
Post by: Αndré on July 20, 2015, 11:44:35 am
You'll need to modify the function theme_page_title. Copy it from themes/sample/theme.php to your theme's theme.php file, if it doesn't exist. If you search our board for that function you'll find several threads with examples how to edit that function, e.g. this (http://forum.coppermine-gallery.net/index.php/topic,76888.msg371503.html#msg371503).

If you need further help, let me know.
Title: Re: Name displayed on browsers
Post by: biellebrunner on July 20, 2015, 10:33:47 pm
Hi, André.
Thanks for getting back to me.
I managed to edit the file alright following that thread, but that example isn't exactly how I'd like the title to show up. It doesn't show the category (even when you're just in the parent category page), and shows the file name when in displayimage (which I don't want it to).
Is there any documentation I could follow to try and achieve what I need?
Thanks again.
Title: Re: Name displayed on browsers
Post by: Αndré on July 21, 2015, 12:04:19 am
Unfortunately there's no documentation for exactly that task. You need to reverse-engineer where the function is used and probably adjust what is passed to it. Please describe what exactly you need on which pages and I'll try to create the corresponding mod for you.