Book Image

Mastering TypoScript: TYPO3 Website, Template, and Extension Development

Book Image

Mastering TypoScript: TYPO3 Website, Template, and Extension Development

Overview of this book

Free, open-source, flexible, and scalable, TYPO3 is one of the most powerful PHP content management systems. It is well suited for creating intranets and extranets for the enterprise. While providing an easy-to-use web interface for non-technical authors and editors of content, its messaging and workflow system enable shared authoring and collaboration. TYPO3 provides flexible and powerful interfaces for both content editors and administrators, giving them full control of the core aspects the system. However for developers who need to customize the system, TYPO3 offers a powerful configuration language called TypoScript. Good knowledge of TypoScript is really a prerequisite for implementing complex applications with TYPO3 and gives developers full control over the configuration of TYPO3 and its template engine. TypoScript enables the complete output template to be created and manipulated, giving you full control over the layout of the site. TypoScript also allows you to integrate dynamic contents, JavaScript-based menus, Flash, Graphics, etc. with ease. You have maximum control over the design of the website and can control all options that would otherwise be addressed by HTML-simple text output, formatting, and much more. TypoScript also allows you to generate graphics at run time and display different content dynamically.
Table of Contents (19 chapters)
Mastering TypoScript: TYPO3 Website, Template, and Extension Development
Credits
About the Author
Preface

Modifying Graphics


A glance at the source text illustrates that the well-known attributes of the<img> tag, such as width, height, etc. are set automatically. In other words, TYPO3 displays the embedded graphic in its original size. This can be easily changed.

Changing the Graphic Size

You can change the size of a graphic as desired by changing the file.width property of the IMAGE object. TYPO3 then creates this graphic afresh on the server, while the original graphic remains intact in the specified directory. The newly created graphic is stored in the typo3.temp/pics/ directory and loaded from there.

IMAGE.file.width = 300 IMAGE.file.height = 200

You can see in the source text that the graphic is no longer being loaded from the specified fileadmin/_temp_/images/logo.jpg directory, but automatically from typo3.temp/pics/. TYPO3 did not even use the original file name.

The typo3.temp/pics/ directory will soon be storage intensive. Every time the size of an image is changed, TYPO3 creates...