Neos CMS Documentation Release 2.3.3
Total Page:16
File Type:pdf, Size:1020Kb
Neos CMS Documentation Release 2.3.3 The Neos Team Jun 16, 2019 Contents 1 Getting Started 3 1.1 Feature List..............................................3 1.2 Installation..............................................5 2 Technical Principles 11 3 User Guide 13 3.1 User Interface Basics......................................... 13 3.2 Workspaces.............................................. 15 4 Creating a Site with Neos 17 4.1 Node Types.............................................. 17 4.2 TypoScript.............................................. 30 4.3 Rendering Custom Markup..................................... 42 4.4 Content Dimensions......................................... 70 4.5 Multi Site Support.......................................... 74 4.6 Content Cache............................................ 74 4.7 Permissions & Access Management................................. 80 5 Extending Neos 89 5.1 Creating a plugin........................................... 89 5.2 Custom Backend Modules...................................... 94 5.3 Custom Edit/Preview-Modes..................................... 95 5.4 Custom Editors............................................ 96 5.5 Custom Eel Helper.......................................... 97 5.6 Custom FlowQuery Operations................................... 98 5.7 Custom TypoScript Objects..................................... 100 5.8 Custom Validators.......................................... 101 5.9 Custom ViewHelpers......................................... 101 5.10 Customizing the Inspector...................................... 104 5.11 Data sources............................................. 107 5.12 Interaction with the Neos backend.................................. 108 5.13 Rendering special formats (CSV, JSON, XML, . )......................... 110 5.14 Writing Tests For Neos........................................ 111 6 Inside of Neos 115 6.1 User Interface Development..................................... 115 7 References 125 7.1 Property Editor Reference...................................... 125 7.2 View Helper Reference........................................ 135 i 7.3 TypoScript Reference........................................ 211 7.4 Eel Helpers Reference........................................ 226 7.5 FlowQuery Operation Reference................................... 249 7.6 Command Reference......................................... 257 7.7 Validator Reference......................................... 286 7.8 Signal Reference........................................... 295 7.9 Coding Guideline Reference..................................... 305 7.10 Node Migration Reference...................................... 329 8 Contribute 335 8.1 Development............................................. 335 8.2 Documentation............................................ 337 9 How To’s 339 9.1 Neos Best Practices (to be written)................................. 339 9.2 Adding A Simple Contact Form................................... 339 9.3 Changing the Body Class with a condition............................. 341 9.4 Changing Defaults Depending on Content Placement........................ 341 9.5 Creating a simple Content Element................................. 342 9.6 Customize Login Screen....................................... 343 9.7 Editing a shared footer across all pages............................... 344 9.8 Extending the Page.......................................... 344 9.9 Integrating a JavaScript-based slider................................. 345 9.10 Rendering a Menu.......................................... 348 9.11 Rendering a Meta-Navigation.................................... 349 9.12 Selecting a Page Layout....................................... 350 9.13 Translating content.......................................... 353 9.14 Wrapping a List of Content Elements................................ 354 10 Neos Operations 357 10.1 Command Line Tools........................................ 357 11 Appendixes 361 12 Indices and tables 363 ii Neos CMS Documentation, Release 2.3.3 Neos is a free enterprise web content management system licensed under the GPL. This version of the documentation covering Neos 2.3.3 has been rendered at: Jun 16, 2019 Contents 1 Neos CMS Documentation, Release 2.3.3 2 Contents CHAPTER 1 Getting Started 1.1 Feature List Note: The following list contains the key technical features of Neos. If you want to learn about the great features and experience that neos offers to editors and visitors please have a look at the Neos Website. 1.1.1 ContentRepository and ContentElements The content repository is the conceptual core of Neos. It can store arbitrary content by managing so called Nodes that can have custom properties and child nodes. The list of available NodeTypes is extensible and hierarchical so new NodeTypes can be created by extending the existing ones. Neos already comes with a sophisticated list of ContentElements to cover the basic editing needs with- out further extension. The Standard ContentElements are implemented as NodeTypes from the Package TYPO3.Neos.NodeTypes and contain the elements Headline, Text, Image, Image with Text, 2- 3- 4-Columns, Download List, Forms and Menu. The List of ContentElements is easily extensible and the demo site already contains examples for YouTube and Flickr Integration and even a Custom Image Slider. Note: To lean about the Structure and Extensibility of the ContentRepository have a look at the Sections Content Structure and the Property Editor Reference. 1.1.2 Inline- and Structural Editing Neos offers inline editing for basically all data that is visible on the website and fully supports the navigation of the website menus during editing. For metadata or mode abstract informations it has an extensible Inspector. By implementing a custom edit/preview mode the editing in Neos can be extended even further. Note: To get an understanding of the editing workflow we recommend the section User Interface Basics. 3 Neos CMS Documentation, Release 2.3.3 1.1.3 Content Dimensions and Languages Most content has to be managed in variants for different languages or target groups. For that neos offers the concept so called content dimensions. Note: The configuration of ContentDimensions is explained in the section Content Dimensions. 1.1.4 Workspaces and Publishing Neos has workspaces built in. Every user works in his personal workspace and can publish his changes to make them public. Furthermore, there is a “Workspace” module which can be used for publishing individual nodes. Note: The concept of workspaces will be extended in future releases so shared editing workspaces between users and publishing to non-live workspaces will become possible. 1.1.5 Import Export Neos has full support for importing and exporting site content using content stored in XML files. That can also be used to regularly import external data into Neos or to migrate content from other systems. Note: The reference of the import and export command can be found in the Neos Command Reference. 1.1.6 Multi Domain Support Using the command line tools or the site-management backend module it’s possible to link a hostname to a site node, making it possible to have a multi domain installation in Neos. This way you can for example create a multilingual website using a ‘multi-tree concept’. Note: There are still a few bugs related to URI resolving in this area; it needs to be more thoroughly tested. 1.1.7 Robust and secure Foundation Being built upon the most advanced PHP framework to date – Flow – makes your websites ready for whatever the future holds for you. Flow is secure by default, keeping your developers focussed on their main task - building your application - without having to worry about low level implementations. 1.1.8 Surf Deployment and Cloud Support The developers of Neos also created “Surf” a professional tool for downtime free server-deployment that is opti- mized for Neos. With Surf Neos can be easily deployed to all kinds of hosting environments being it dedicated servers, virtual-machines or cloud solutions of different flavours. The media handling of Neos is “cloud ready” by design and can handle external resources exceptionally well. 4 Chapter 1. Getting Started Neos CMS Documentation, Release 2.3.3 1.2 Installation Tip: Neos is built on top of the Flow framework. If you run into technical problems, keep in mind to check the Flow documentation for possible hints as well. 1.2.1 Requirements Neos has at least the same system requirements as Flow. You can find them in the Flow Requirements Documen- tation. The most important requirements are: • A Webserver (Apache and Nginx are preferred but others work as well) • A Database (MySQL and MariaDB are preferred but any Database supported by Doctrine DBAL should work). • PHP >= 5.5.0 (make sure the PHP CLI has the same version) – PHP modules mbstring, tokenizer and pdo_mysql – PHP functions system(), shell_exec(), escapeshellcmd() and escapeshellarg() – It is recommended to install one of the PHP modules imagick or gmagick 1.2.2 Fundamental Installation 1. First you need to install the dependency manager Composer (if you don’t have it already): curl -sS https://getcomposer.org/installer | php By issuing this command Composer will get downloaded as composer.phar to your working directory. If you like to have composer installed globally, you can simply move it to a directory within your $PATH environment. mv composer.phar /usr/local/bin/composer Note: If you are on Windows please refer to the offical documentation