Page 1 of 1

Override {title} & mMenuText with {$page_title}

Posted: Thu Oct 07, 2010 10:55 pm
by richardjkeys
Hi,

I've followed this post about setting news page's H1 tags, which works a treat.

However, my news, blog, events, company directory pages all use detailpages, which means the breadcrumb displays the page alias, and the {title} tag displays the page alias also.

What I'd like to do is something like this:

Code: Select all

{if isset($page_title)}
{title = $page_title}
{/if}
I think the breadcrumb uses mMenuText from the content object, but I'm not sure.

Any help would be great.

Regards,

Rich

Re: Override {title} with {$page_title}

Posted: Thu Oct 07, 2010 11:40 pm
by Peciura

Re: Override {title} with {$page_title}

Posted: Thu Oct 07, 2010 11:50 pm
by richardjkeys
Hi, thanks for the link.

That works great on the title tag, however I need to also set the Menu Text variable (for the breadcrumb) I think.

Re: Override {title} & mMenuText with {$page_title}

Posted: Thu Oct 07, 2010 11:58 pm
by Peciura
If you set variable {$page_title} in content it is also valid in menu manager. It does not look complicated to attache another word to breadcumbs.

Can not tell much more without seeing template and without knowing exactly, what you have now and what you want to do - link or couple of images would do.

Re: Override {title} & mMenuText with {$page_title}

Posted: Fri Oct 08, 2010 12:10 am
by richardjkeys
The problem is I have used detailpages with the modules.

For example, my news breadcrumb is:

Home > News > News Article

Simply adding to the breadcrumb gives:

Home > News > News Article -> $page_title

When what I want is:

Home > News > $page_title

I hope that makes things clearer.