Page title

Author Message

Amina Bacar

Friday 26 December 2003 9:13:33 am

When I view my page in IE the title is the article URL.
Using the option view source of the browser, the title is correct.

I have changed the title in site.ini.append.php in the siteaccess

Is there another place where I have to set the Page title?

Thanks in advance.

Amina.
Mzbusiness.com

Paul Borgermans

Friday 26 December 2003 11:56:45 am

Hi Amina

The title you set in site.ini.append.php is the default. This means it is overriden by the module being called. For content views, it is the object name with the path to the object appended to it.

So it is hard to change without modifying the kernel code. What did you have in mind?

-paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Balazs Halasy

Friday 26 December 2003 1:32:35 pm

I believe Amina would like to have a static title that appears, for example "My cool company" for all pages, regardless of the content/node that is displayed. Just guessing.. not exactly sure how to do this myself - never tried.. any suggestions Paul?

Balazs

Amina Bacar

Saturday 27 December 2003 12:38:14 am

Yes Balazs that's what i have in mind.

I'm not to concerned about other pages, but i would like to have a nice title in the homepage.

Did anyone tried this before?

Amina.

Paul Borgermans

Saturday 27 December 2003 4:12:27 am

Hi Balazs & Amina

It turns out to be easy by modifying page_head.tpl

Suppose your sitedesign is "mysite", then copy the template file design/standard/templates/page_head.tpl to
design/mysite/templates/page_head.tpl and look for the code around line 14 and comment out the section that loops the reverse path as below and leaving only the site title

-----------------------------
{set-block scope=root variable=site_title}
{*section loop=$Path:reverse_path}{$:item.text|wash}{delimiter} / {/delimiter}{/section*}{$site.title|wash}
{/set-block}
-----------------------------

After this, clear the template cache and you should only get the site name as title in the <head> section.

I suggest to do this only for your "mysite" design, and not to modify the design/standard/templates/page_head.tpl

If you need to change other templates like this always copy them to your specific design in the templates directory.

regards

-paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 31 2025 05:35:30
Script start
Timing: Jan 31 2025 05:35:30
Module start 'layout'
Timing: Jan 31 2025 05:35:30
Module start 'content'
Timing: Jan 31 2025 05:35:30
Module end 'content'
Timing: Jan 31 2025 05:35:30
Script end

Main resources:

Total runtime0.0138 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0050 588.0078151.1953
Module start 'layout' 0.00500.0029 739.203136.6016
Module start 'content' 0.00790.0045 775.804794.1094
Module end 'content' 0.01240.0014 869.914133.9922
Script end 0.0138  903.9063 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002417.6461140.0002
Check MTime0.00107.5434140.0001
Mysql Total
Database connection0.00075.146110.0007
Mysqli_queries0.002215.850330.0007
Looping result0.00000.174110.0000
Template Total0.00117.610.0011
Template load0.00085.870010.0008
Template processing0.00021.735510.0002
Override
Cache load0.00064.120710.0006
General
dbfile0.00042.567980.0000
String conversion0.00000.081040.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs