Page title tag auto generated from Gallery problem
Posted: Mon Jun 06, 2016 8:21 pm
Hi there, I'm having a problem that I can't seem to figure out although I've found the "exact" answer on this forum here: http://forum.cmsmadesimple.org/viewtopi ... 51#p252651
I'm really confused and have tried many different options. I'm 100% sure that I have the correct code in the right places, but still not working.
Problem
Just trying to get the Gallery module to display the $gallerytitle as the page <title>.
On my Gallery template I have the following line of code to set the correct variable:
Then on the page template displaying the Gallery photos, I have the following:
I also tried it this way:
I have tried so many different variations of the code, but nothing seems to work. Could there be something wrong with my Smarty installation?
For example, this page's title should be Cambria Countertops, but instead it just shows Gallery - the main gallery title. But you can see that the h3 tag is pulling the correct title on the page itself: http://www.gandmexpress.com/gallery/Cam ... -Photos/63
I checked System Maintenance: No structural errors were detected in the database
System Information doesn't seem to have any errors!
I cleared the Cache.
I'm currently using CMSMS version 2.1.1
Gallery module version 2.1 (I know the latest is 2.1.5 but I was scared to upgrade until I figure out the problem)
Any suggestions? Thank you for your help
I'm really confused and have tried many different options. I'm 100% sure that I have the correct code in the right places, but still not working.
Problem
Just trying to get the Gallery module to display the $gallerytitle as the page <title>.
On my Gallery template I have the following line of code to set the correct variable:
Code: Select all
{if !empty($gallerytitle)}<h3>{$gallerytitle}</h3>{assign var='gallery_title' value=$gallerytitle}{/if}
Code: Select all
<title>{sitename} - {title}{if isset($gallery_title)} - {$gallery_title}{/if}</title>
Code: Select all
{if isset($gallery_title)} <title>{$gallery_title}</title> {else} <title>{title}</title> {/if}
For example, this page's title should be Cambria Countertops, but instead it just shows Gallery - the main gallery title. But you can see that the h3 tag is pulling the correct title on the page itself: http://www.gandmexpress.com/gallery/Cam ... -Photos/63
I checked System Maintenance: No structural errors were detected in the database
System Information doesn't seem to have any errors!
I cleared the Cache.
I'm currently using CMSMS version 2.1.1
Gallery module version 2.1 (I know the latest is 2.1.5 but I was scared to upgrade until I figure out the problem)
Any suggestions? Thank you for your help