DEPRECATION WARNING

This documentation is not using the current rendering mechanism and is probably outdated. The extension maintainer should switch to the new system. Details on how to use the rendering mechanism can be found here.

EXT: Browser's page title

Author:Kasper Skårhøj
Created:2002-11-01T00:32:00
Changed by:toto
Changed:2006-05-13T19:28:27
Author:Bertrand Mure
Email:bertrand.mure@worldonline.fr
Info 3:
Info 4:

EXT: Browser's page title

Extension Key: browser_page_title

Copyright 2000-2006, Bertrand Mure, <bertrand.mure@worldonline.fr>

This document is published under the Open Content License

available from http://www.opencontent.org/opl.shtml

The content of this document is related to TYPO3

- a GNU/GPL CMS/Framework available from www.typo3.com

Table of Contents

EXT: Browser's page title 1

Introduction 1

What does it do? 1

Screenshots 1

Users manual 1

Configuration 2

Reference 2

Known problems 2

To-Do list 3

Changelog 3

Introduction

What does it do?

The goal of this extension is to define by several ways the html title of your pages (<title> tag) :

  • First, you can define a default generic layout for your title which is inherited by all sub pages. Eg : “Default string - Page title“. The first element “Default string” is static and the second one, “Page title”, is dynamic and corresponds to a page header field (here “Page title”).
  • Second, you can define a custom and specific title for a given page which override the generic layout (if its value not blank). The value of this specific title can be the one of the new field “Browser title” but can be also any field of the header page.
  • Third, if the default generic layout and the specific title values are blank, “Page title” field is used (can't be blank).
  • Fourth, this mechanism works independentlyfor each alternative languages.

Screenshots

No screenshots.

Users manual

Your web site administrator has defined a default layout for your pages title (eg img-1 ) but you can define a specific title for each page. To do this on your default language page you must :

  • Click on “Web > page” module img-2
  • Select a page img-3
  • Edit the page header img-4
  • Edit “Browser title” field img-5
  • Save. That's it !! Now see this new page title in frontend img-6
  • You can do the same thing for your alternative languages pages by editing the correspondent header img-7

Configuration

TS configuration needed. See “Reference” part.

Reference

defaultTitle

Property

defaultTitle

Data type

string

Description

You can define here a layout of your choice. Eg :

static string 1

static string 1 - {dynamic field}

static string 1 - {dynamic field} - static string 2

{dynamic field}

{dynamic field} - static string 2

etc...

You can specify just one dynamic field. This dynamic field corresponds to the field name in the database table “pages”. This dynamic field must be surrounded by curly brackets { }.

When you define a static string and a dynamic field for defaultTitle , the value will be considered as blank if the dynamic field value is blank, even if the static string value (of course) is not.

defaultTitle is used only if currentTitle value is blank.If defaultTitle is evaluated as blankthe “Page title” header field is used.

Default

currentTitle

Property

currentTitle

Data type

string

Description

Like defaultTitle.

tx_browserpagetitle_browser_title is the database field name corresponding to the new “Browser title” field in page header.

Default

[tsref:plugin.browser_page_title]

((generated))
Example

You have to put some typoscript in the Setup of your main template. This is an example of the “standard“ configuration (see Reference subsection for details) :

# Including the class and calling the right function

includeLibs.tx_browserpagetitle = typo3conf/ext/browser_page_title/class.tx_browserpagetitle.php

config.titleTagFunction = tx_browserpagetitle->getTitle

# Default language parameters

plugin.browser_page_title {

defaultTitle = Bonjour tout le monde - {title}

currentTitle = {tx_browserpagetitle_browser_title}

}

# Alternative language parameters

[globalVar=GP:L=1]

plugin.browser_page_title.defaultTitle = Hello everybody - {title}

plugin.browser_page_title.currentTitle = {tx_browserpagetitle_browser_title}

[global]

Known problems

None at this time.

To-Do list

None.

Changelog

Version 1.0.0: Initial public version.

Version 1.0.5: Documentation updated.

Version 1.0.6: German translation added (thanks to Uwe Schmelzer).

Version 1.0.7: Documentation updated.

Version 1.1.0: Typo3.5 compatibility removed. Now works without any modifications on Typo3.6 and higher (including 4.0).

img-8 EXT: Browser's page title - 3