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.

TypoScript objects

There are many different TypoScript objects for rendering a variety of content elements in any given page according to need. To each object there is a corresponding PHP class in the TYPO3 CMS. Each object also has properties. For example, the IMAGE object has a "border" property and a "titleText" property. In the TypoScript Reference (TSref), we can find a complete list of available objects and all their properties, complete with the type of data that each object accepts. Adding arbitrary properties or erroneous values will not work.

The object receives the parameter (as described above) in a PHP array (e.g. $conf['border.']['color'] = 'red';). This array can contain an arbitrary number of entries. Only those entries which are referenced by the object will be used, though (e.g. $conf['border'] or $conf['titleText']).

In the case "titleText", the data type is "string /stdWrap". This means that both text (string) and methods of the stdWrap type are allowed. Looking up the section on stdWrap in TSref will tell you which properties stdWrap evaluates. Hence, we are allowed to augment the method "titleText" with various properties from stdWrap (e.g. titleText.field = header). In doing so, the value of titleText will be filled with standard text first, and, after that, the stdWrap functions are executed.

So, it is not necessary to guess, which object will get manipulated in that way; but, it suffices to look up this information in the TypoScript reference.

Many more objects are used for the rendering of a web page. The challenge is to artfully combine all of them.

In the section Reading content records, we show how we can use the CONTENT object to query to database and return the content of a page. The object receives a list of content elements, which are rendered one after the other (normally in sorting order). Therefore, we use the object CASE to differentiate between the different element type (CType) and render them accordingly.

It is absolutely necessary to know the various TypoScript objects and functions.