Attention

TYPO3 v6 has reached its end-of-life April 18th, 2017 and is not maintained by the community anymore. Looking for a stable version? Use the version switch on the top left.

There is no further ELTS support. It is strongly recommended updating your project.

page

Property

page, ...

Data type

->PAGE

Description

PAGE is used to define what is to be rendered in the frontend.

Example:

page = PAGE
page.typeNum = 1

Guidelines:

Good, general PAGE object names to use are such as:

  • page for the main page with content

  • top, left, menu, right, bottom, border for top etc.

These are just recommendations. However, especially the name 'page' for the content bearing page is very common.

Pages are referenced by two main values. The "id" and "type".

The "id" points to the uid of the page (or the alias). Thus the page is found.

The "type" is used to define how the page should be rendered.

A good habit is to use "page" as the top-level object name for the content-page on a website.

Most of this code is executed in the PHP script typo3/sysext/frontend/Classes/Page/PageGenerator.php (typo3/sysext/cms/tslib/class.tslib_pagegen.php).

PAGE

Property details

1,2,3,4...

Property

1,2,3,4...

Data type

cObject

Description

These properties can be used to define any number of objects, just like you can do with a COA content object.

adminPanelStyles

Property

adminPanelStyles

Data type

boolean

Description

Will include CSS styles for the Admin Panel.

bgImg

Property

bgImg

Data type

imgResource

Description

Background image on the page. This is automatically added to the body- tag.

bodyTag

Property

bodyTag

Data type

<tag>

Description

Body tag on the page

Example:

<body bgcolor="{$bgCol}">

Default

<body>

bodyTagAdd

Property

bodyTagAdd

Data type

string

Description

This content is added to the end of the bodyTag.

bodyTagCObject

Property

bodyTagCObject

Data type

cObject

Description

This is the default body tag. It is overridden by ".bodyTag", if that is set.

Note: Additionally to the body tag properties noted here, there also is the property "config.disableBodyTag", which - if set - disables body tag generation independently from what might be set here.

bodyTagMargins

Property

bodyTagMargins

Data type

integer

Description

margins in the body tag.

Property:

.useCSS = 1 (boolean) - will set a "BODY {margin: ...}" line in the in-document style declaration - for XHTML compliance.

Example:

bodyTagMargins = 4

This adds leftmargin="4" topmargin="4" marginwidth="4" marginheight="4" to the bodyTag.

config

Property

config

Data type

->CONFIG

Description

Configuration for the page. Any entries made here override the same entries in the top-level object "config".

CSS_inlineStyle

Property

CSS_inlineStyle

Data type

string

Description

This value is just passed on as CSS.

Note: To make TYPO3 actually output these styles as inline CSS (in-document CSS encapsulated in <style> tags), config.inlineStyle2TempFile must be set to 0.

cssInline

Property

cssInline

Data type

->CARRAY

Description

Use cObjects for creating inline CSS

Example:

cssInline {
    10 = TEXT
    10.value = h1 {margin:15px;}

    20 = TEXT
    20.value = h1 span {color: blue;}
}

extOnReady

Property

extOnReady

Data type

->CARRAY

Description

ExtJS specific, adds inline JavaScript, wrapped in Ext.onReady.

Example:

page.extOnReady {
   10 = TEXT
   10.value = Ext.Msg.alert("TypoScript Message","Hello World!");
}

will produce following source:

Ext.onReady(function() {Ext.Msg.alert("TypoScript Message","Hello World!"); });

footerData

Property

footerData

Data type

->CARRAY

Description

Same as headerData above, except that this block gets included at the bottom of the page (just before the closing body tag).

frameSet

FRAME is an object type.

Attention

FRAME, FRAMESET and frameSet have been deprecated in version 8.5 of the TYPO3 core. Using this is no longer considered good practice.

Additionally, frameset and frame are no longer supported in HTML

See Deprecation: #78217 - frameset and frame (8.5 Changelog).

Property

frameSet

Data type

->FRAMESET

Description

if any properties is set to this property, the page is made into a frameset.

headerData

Property

headerData

Data type

->CARRAY

Description

Inserts content in the header-section. Could be JavaScripts, meta- tags, other stylesheet references.

By default, gets inserted after all the style definitions.

headTag

Property

headTag

Data type

<tag>

Description

Head-tag if alternatives are wanted

Default

<head>

hover

Property

hover

Data type

HTML-color

Description

The color of a link when the mouse moves over it! (only MSIE). Uses in-document stylesheet.

Note: This option was deprecated and has been removed in TYPO3 6.0. Use stylesheets instead.

hoverStyle

Property

hoverStyle

Data type

string

Description

Additional style information to the hover-color.

Example:

page.hoverStyle = font: bold; text-decoration: none;

Note: This option was deprecated and has been removed in TYPO3 6.0. Use stylesheets instead.

includeCSS.[array]

Property

includeCSS.[array]

Data type

resource

Description

Inserts a stylesheet (just like the .stylesheet property), but allows setting up more than a single stylesheet, because you can enter files in an array.

The file definition must be a valid "resource" data type, otherwise nothing is inserted.

Each file has optional properties:

.allWrap: Wraps the complete tag, useful for conditional comments.

.allWrap.splitChar: (Since TYPO3 6.2) Defines an alternative splitting character (default is "|" - the vertical line).

.alternate: If set (boolean) then the rel-attribute will be "alternate stylesheet".

.disableCompression: (Since TYPO3 4.6) If config.compressCss is enabled, this disables the compression of this file.

.excludeFromConcatenation: (Since TYPO3 4.6) If config.concatenateCss is enabled, this prevents the file from being concatenated.

.external: If set, there is no file existence check. Useful for inclusion of external files.

.forceOnTop: Boolean flag. If set, this file will be added on top of all other files.

.if: (Since TYPO3 4.7) Allows to define conditions, which must evaluate to TRUE for the file to be included. If they do not evaluate to TRUE, the file will not be included. Extensive usage might cause huge numbers of temporary files to be created. See ->if for details.

.import: If set (boolean) then the @import way of including a stylesheet is used instead of <link>

.media: Setting the media attribute of the <style> tag.

.title: Setting the title of the <style> tag.

Example:

includeCSS {
  file1 = fileadmin/mystylesheet1.css
  file2 = stylesheet_uploaded_to_template*.css
  file2.title = High contrast
  file2.media = print
  ie6Style = fileadmin/css/style3.css
  ie6Style.allWrap = <!--[if lte IE 7]>|<![endif]-->
  cooliris = http://www.cooliris.com/shared/
             resources/css/global.css
  cooliris.external = 1
}

includeCSSLibs.[array]

Property

includeCSSLibs.[array]

Data type

resource

Description

(Since TYPO3 6.2) Adds CSS library files to head of page.

The file definition must be a valid "resource" data type, otherwise nothing is inserted. This means that remote files cannot be referenced (i.e. using "http://..."), except by using the ".external" property.

Each file has optional properties:

.allWrap: Wraps the complete tag, useful for conditional comments.

.allWrap.splitChar: Defines an alternative splitting character (default is "|" - the vertical line).

.alternate: If set (boolean) then the rel-attribute will be "alternate stylesheet".

.disableCompression: If config.compressCss is enabled, this disables the compression of this file.

.excludeFromConcatenation: If config.concatenateCss is enabled, this prevents the file from being concatenated.

.external: If set, there is no file existence check. Useful for inclusion of external files.

.forceOnTop: Boolean flag. If set, this file will be added on top of all other files.

.if: Allows to define conditions, which must evaluate to TRUE for the file to be included. If they do not evaluate to TRUE, the file will not be included. Extensive usage might cause huge numbers of temporary files to be created. See ->if for details.

.import: If set (boolean) then the @import way of including a stylesheet is used instead of <link>

.media: Setting the media attribute of the <style> tag.

.title: Setting the title of the <style> tag.

Example:

includeCSSLibs.twitter = http://twitter.com/styles/blogger.css
includeCSSLibs.twitter.external = 1

includeJS.[array]

Property

includeJS.[array]

Data type

resource

Description

Inserts one or more (Java)Scripts in <script> tags.

The file definition must be a valid "resource" data type, otherwise nothing is inserted. This means that remote files cannot be referenced (i.e. using "http://..."), except by using the ".external" property.

Each file has optional properties:

.allWrap: Wraps the complete tag, useful for conditional comments.

.allWrap.splitChar: (Since TYPO3 6.2) Defines an alternative splitting character (default is "|" - the vertical line).

.disableCompression: (Since TYPO3 4.6) If config.compressJs is enabled, this disables the compression of this file.

.excludeFromConcatenation: (Since TYPO3 4.6) If config.concatenateJs is enabled, this prevents the file from being concatenated.

.external: If set, there is no file existence check. Useful for inclusion of external files.

.forceOnTop: Boolean flag. If set, this file will be added on top of all other files.

.if: (Since TYPO3 4.7) Allows to define conditions, which must evaluate to TRUE for the file to be included. If they do not evaluate to TRUE, the file will not be included. Extensive usage might cause huge numbers of temporary files to be created. See ->if for details.

.type: Setting the MIME type of the script (default: text/javascript).

Example:

includeJS {
  file1 = fileadmin/helloworld.js
  file1.type = application/x-javascript
  # Include a second file, but only if myConstant is set
  # in the TS constants field.
  file2 = javascript_uploaded_to_template*.js
  file2.if.isTrue = {$myConstant}
}

includeJSFooter.[array]

Property

includeJSFooter.[array]

Data type

resource

Description

Same as includeJS above, except that this block gets included at the bottom of the page (just before the closing body tag).

includeJSFooterlibs.[array]

Property

includeJSFooterlibs.[array]

Data type

resource

Description

Same as includeJSlibs, except that this block gets included at the bottom of the page (just before the closing body tag).

includeJSlibs.[array]

Property

includeJSlibs.[array]

Data type

resource

Description

Adds JS library files to head of page.

The file definition must be a valid "resource" data type, otherwise nothing is inserted. This means that remote files cannot be referenced (i.e. using "http://..."), except by using the ".external" property.

Each file has optional properties:

.allWrap: Wraps the complete tag, useful for conditional comments.

.allWrap.splitChar: (Since TYPO3 6.2) Defines an alternative splitting character (default is "|" - the vertical line).

.disableCompression: (Since TYPO3 4.6) If config.compressJs is enabled, this disables the compression of this file.

.excludeFromConcatenation: (Since TYPO3 4.6) If config.concatenateJs is enabled, this prevents the file from being concatenated.

.external: If set, there is no file existence check. Useful for inclusion of external files.

.forceOnTop: Boolean flag. If set, this file will be added on top of all other files.

.if: (Since TYPO3 4.7) Allows to define conditions, which must evaluate to TRUE for the file to be included. If they do not evaluate to TRUE, the file will not be included. Extensive usage might cause huge numbers of temporary files to be created. See ->if for details.

Example:

includeJSlibs.twitter = http://twitter.com/javascripts/blogger.js
includeJSlibs.twitter.external = 1

includeLibs

Property

includeLibs

Data type

(array of strings)

Description

With this you may include PHP files. This does the same as "includeLibrary" in ->CONFIG but this can include more than one file. These files are included after the file of includeLibrary.

Note:

The top-level object "includeLibs" and the scripts defined with this property are added to each other. Script-keys (that is the "array of strings"-value, like below "tx_myext") from this property of the page override any scripts-keys from the top-level "includeLibs" property!

The script filenames are of the data type "resource".

Example:

page.includeLibs.tx_myext = lib_filename.php

Note: This property was deprecated and has been removed with TYPO3 7! If you only need the included files inside a certain scope, e.g. inside a COA_INT or USER_INT cObject, use the includeLibs functionalities of this cObject instead. You can also use hooks during the Frontend set up to execute custom PHP code.

inlineJS

Property

inlineJS

Data type

->CARRAY

Description

Inserts inline JavaScript in the header-section. Don't use script-tags as they are added by TYPO3.

Example:

page.inlineJS.10 = TEXT
page.inlineJS.10.value = function a(val) { alert(val); }

With config.removeDefaultJS = external the inlineJS is moved to external file.

With config.minifyJS = 1 (removed in TYPO3 6.0) the inlineJS was minified as well.

Note: This option was deprecated and has been removed in TYPO3 4.3. Use jsInline instead.

inlineLanguageLabel

Property

inlineLanguageLabel

Data type

(array of strings)

Description

ExtJS specific, adds language labels to the page.

Example:

inlineLanguageLabel {
   label1 = 123
   label2 = 456
}

will produce following source:

TYPO3.lang = {"label1":"123","label2":"456"};

inlineSettings

Property

inlineSettings

Data type

(array of strings)

Description

ExtJS specific, adds settings to the page.

Example:

page.inlineSettings {
   setting1 = Hello
   setting2 = GoOnTop
}

will produce following source:

TYPO3.settings = {"TS":{"setting1":"Hello","setting2":"GoOnTop"}};

insertClassesFromRTE

Property

insertClassesFromRTE

Data type

boolean

Description

If set, the classes for the Rich Text Editor configured in Page TSconfig are inserted as the first thing in the Style-section right after the setting of the stylesheet.

.add_mainStyleOverrideDefs: [* / list of tags ]. Will add all the "RTE.default. mainStyleOverride_add" - tags configured as well.

Might be deprecated soon. Most likely the RTE should be configured by the stylesheet instead. Stay tuned...

javascriptLibs

Property

javascriptLibs

Data type

(array of strings)

Description

This allows to include the JavaScript libraries that are shipped with the TYPO3 Core.

javascriptLibs {
   # Note: All jQuery-related options are available since TYPO3 v6.0
   # include jQuery (boolean)
   jQuery = 1
   # Change the version
   # (possible values: latest|1.7.2|…, default: latest)
   # Note: jQuery.source has to be a CDN like "google"
   # when jQuery.version is not "latest"
   jQuery.version = latest
   # Include from local or different CDNs
   # (possible values: local|google|jquery|msn, default: local)
   jQuery.source = local
   # Set jQuery into its own scope to avoid conflicts (boolean)
   jQuery.noConflict = 1
   # Change the namespace when noConflict is activated
   # and use jQuery with "TYPO3.###NAMESPACE###(…);"
   # (string, default: jQuery)
   jQuery.noConflict.namespace = ownNamespace

     # include prototype
   Prototype = 1

     # include Scriptaculous
   Scriptaculous = 1
     # adds modules dragdrop and controls to Scriptaculous
   Scriptaculous.modules = dragdrop,controls

     # include ExtCore
   ExtCore = 1
     # include ExtCore debug file (uncompressed)
   ExtCore.debug = 1

     # includes ExtJS
   ExtJs = 1
     # include ext-all.css
   ExtJs.css = 1
     # include default theme
   ExtJs.theme = 1
    # load specific adapter (jquery|prototype|yui)
   ExtJs.adapter = 
     # initialize QuickTips
   ExtJs.quickTips = 1
     # includes ExtJS debug file (uncompressed)
   ExtJs.debug = 1

     # include SVG library
   SVG = 1
     # include SVG debug file
   SVG.debug = 1
     #force rendering with flash
   SVG.forceFlash = 1
}

Note: If both ExtCore and ExtJS are requested, the only superset ExtJS will be loaded. This will also affect any options set. They will only come from ExtJS.

Note: Before TYPO3 4.5.3 you should either request ExtJS or ExtCore, but not both together. Requesting both at the same time will lead to errors.

jsFooterInline

Property

jsFooterInline

Data type

->CARRAY

Description

Same jsInline above, except that the JavaScript gets inserted at the bottom of the page (just before the closing body tag).

jsInline

Property

jsInline

Data type

->CARRAY

Description

Use cObjects for creating inline JavaScript

Example:

page.jsInline {
        10 = TEXT
        10.stdWrap.dataWrap = var pageId = {TSFE:id};
}

Note:

With config.removeDefaultJS = external, the inlineJS is moved to an external file.

With config.minifyJS = 1 (removed in TYPO3 6.0) the inlineJS was minified as well.

meta

Property

meta

Data type

->META

noLinkUnderline

Property

noLinkUnderline

Data type

boolean

Description

Disables link-underlining. Uses in-document stylesheet.

Note: This option was deprecated and has been removed in TYPO3 6.0. Use stylesheets instead.

shortcutIcon

Property

shortcutIcon

Data type

resource

Description

Favicon of the page. Create a reference to an icon here!

Browsers that support favicons display them in the address bar of the browser, next to the name of the site in lists of bookmarks and next to the title of the page in the tab.

Note: The file must be a valid ".ico" file (icon file).

Note: The reference to this file will only be included in the output of your website, if the file actually exists! Should the file be missing, the tag will not be rendered.

smallFormFields

Property

smallFormFields

Data type

boolean

Description

Renders form fields like textarea, input and select-boxes small with "verdana size 1" font.

Uses inline stylesheet.

Tip:

Use this together with the option "config.compensateFieldWidth" set to "0.6" for Netscape browsers in order to render the small form fields in the same width as is normal for other browsers!

Note: This option was deprecated and has been removed in TYPO3 6.0. Use stylesheets instead.

stdWrap

Property

stdWrap

Data type

->stdWrap

Description

Wraps the content of the cObject array with stdWrap options.

stylesheet

Property

stylesheet

Data type

resource

Description

Inserts a stylesheet in the <HEAD>-section of the page;

<link rel="stylesheet" href="[resource]">

typeNum

Property

typeNum

Data type

integer

Description

This determines the typeId of the page. The &type= parameter in the URL determines, which page object will be rendered. The value defaults to 0 for the first found PAGE object, but it must be set and be unique as soon as you use more than one such object.

Default

0

wrap

Property

wrap

Data type

wrap

Description

Wraps the content of the cObject array.