2014-04-26

TYPO3 Neos 1.0.2 The Compendium

translated into english

LOBACHER . Patrick Lobacher Roland Schenke Head of Web Development TYPO3 Neos - the Compendium Feedback LOBACHER.

Feedback requested ! • Dear Neos Enthusiast!

I try to keep the TYPO3 Neos Compendium on an up-to-date Level. To achieve this I need your Input! If you have ideas regarding Code Examples, FAQ Entries or just want to praise or criticize please do not hesitate to contact me at the following address:

patrick [AT] lobacher.de

Have fun with the Compendium! Patrick Lobacher & Roland Schenke

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 2 TYPO3 Neos - the Compendium Changelog LOBACHER.

Changelog Date Changes 2013-08-08 Initial Version / Thanks to Christian Schwerdt for domainFACTORY specific Input

2013-08-09 included proof corrections by Roland Schenke and Michael Oehlhof - Thanks!

2013-08-10 added Nginx-Config - Thanks to Christian Kuhn, Christian Müller and Anja Leichsenring

2013-08-10 added Troubleshoot Section

2013-08-18 included proof corrections by Roland Schenke - Thanks!

2013-08-18 translated from german into english by Roland Schenke - Thanks a lot!

2013-12-12 updated to TYPO3 Neos 1.0 final

2013-12-15 updated to TYPO3 Neos 1.0.1

2014-01-07 Link for the installation under Shared Hosting and proof corrections (Thanks to Christian Glass!)

2014-03-03 migrated to „LOBACHER.“ CI

2014-03-05 updated to TYPO3 Neos 1.0.2

2014-03-07 added installation on a all-inkl.com Server. Thanks to Mario Janetzko!

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 3 TYPO3 Neos - the Compendium Changelog LOBACHER.

Changelog Date Changes 2014-04-26 He did it again! Many thanks to Roland Schenke for updating the english translation to Neos 1.0.2!!!

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 4 LOBACHER.

What is TYPO3 Neos?

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 5 TYPO3 Neos - the Compendium TYPO3 Neos - the next generation CMS LOBACHER.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 6 TYPO3 Neos - the Compendium TYPO3 Neos - the next generation CMS LOBACHER.

http://neos.typo3.org/download/marketing-material.html

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 7 TYPO3 Neos - the Compendium TYPO3 Neos - the next generation CMS LOBACHER.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 8 TYPO3 Neos - the Compendium TYPO3 Neos - the next generation CMS LOBACHER.

Neos (greek νέος) is just “new”

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 9 TYPO3 Neos - the Compendium The History of TYPO3 Neos starts with TYPO3 CMS LOBACHER.

The History of TYPO3 Neos starts with TYPO3 CMS ! • TYPO3 CMS is a „Enterprise Open Source Content Management Framework“ • TYPO3 CMS exists since 1998 / invented by the Dane Kaspar Skårhøj • approx. 500.000 Installations worldwide / > 5 Mio Downloads • Usage in DE e.g. at > 50% all DAX 500 Enterprises, > 50% all „German Soccer League“ Clubs, discounter, car rentals, public agencies • > 6.000 Extensions • > 100.000 Developers worldwide • > 1500 Agencies worldwide • funded and backed by the TYPO3 Association

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 10 TYPO3 Neos - the Compendium The History of TYPO3 Neos: TYPO3 Phoenix LOBACHER.

The History of TYPO3 Neos: TYPO3 Phoenix ! • At the very first T3DD (TYPO3 Developer Days) in 2006, the decision was made to rewrite TYPO3 from scratch. • Codename: TYPO3 Phoenix (resp. TYPO3 5.0) • some necessary PHP Features were not available at this time and had to be implemented from the ground up: Content Respository, Aspect Oriented Programming, Dependency Injection, ... • The "Berlin Manifesto" of 2008 states the differentiation to the TYPO3 CMS http://typo3.org/roadmap/berlin-manifesto/ (In the meantime Parts of the manifesto became obsolete.)

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 11 TYPO3 Neos - the Compendium The History of TYPO3 Neos: TYPO3 Flow and Ne0s LOBACHER.

The History of TYPO3 Neos: TYPO3 Flow and Ne0s

• Many base functionalities of a CMS are not specific to a CMS (Session- Handling, Datenbank-Handling, Templating, ...) => therefore outsourcing into an own Framework TYPO3 Flow • The introduction of Extbase in 2009 made it possible to write TYPO3 CMS extensions which are executable in TYPO3 Flow with minor adjustments • On 20 October 2011 the Application Framework TYPO3 Flow (once FLOW3) has been released as Final • TYPO3 Neos ist an Application based on TYPO3 Flow • TYPO3 Neos Alpha 7 in October 2013 / Beta 1 on Nov. 12, 2013 • First final Version on 10 December 2013

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 12 TYPO3 Neos - the Compendium The History of TYPO3 Neos: TYPO3 Flow and Ne0s LOBACHER.

Version History TYPO3 Neos

Version Datum TYPO3 Phoenix Sprint Release 1 2010-05-31 ...... TYPO3 Phoenix Sprint Release 9 2012-08-02 TYPO3 Neos alpha 1 2012-10-05 TYPO3 Neos alpha 2 2012-12-19 TYPO3 Neos alpha 3 2012-02-16 TYPO3 Neos alpha 4 2013-07-07 TYPO3 Neos alpha 5 2013-08-07 TYPO3 Neos alpha 6 2013-10-15 TYPO3 Neos alpha 7 2013-10-30 TYPO3 Neos beta 1 2013-11-12 TYPO3 Neos beta 2 2013-12-03 TYPO3 Neos 1.0 final 2013-12-10 TYPO3 Neos 1.0.1 2013-12-13

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 13 TYPO3 Neos - the Compendium The History of TYPO3 Neos: Die TYPO3 World LOBACHER.

The TYPO3 World - since October 2012

• Umbrella Brand TYPO3

• TYPO3 CMS (no distinct Logo) • TYPO3 Flow • TYPO3 Neos

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 14 TYPO3 Neos - the Compendium The History of TYPO3 Neos: Die TYPO3 World LOBACHER.

TYPO3 Neos: Positioning

• Since December 2013 two independent CMS are offered by TYPO3: • TYPO3 CMS 6.x (4.7, 6.0, 6.1, 6.2 LTS Beta) • TYPO3 Neos 1.0 • from a technology point of view they share NOTHING but the name and are as different as different can be • There are NO migration paths from one system to the other • TYPO3 Neos is NOT the successor of TYPO3 CMS, but a self-contained CMS with a different focus

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 15 LOBACHER.

The Architecture of TYPO3 Neos

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 16 TYPO3 Neos - the Compendium The Architecture of TYPO3 Neos - Backend LOBACHER.

The Architecture of TYPO3 Neos - Backend Fluid Modern Templating Engine ! TYPO3CR Content Repository ( JCR / Sling)

TypoScript TypoScript 2.0 - next Generation

Forms Form API & Form Builder

Expose Extensible admin interface

Eel Embedded Expression Language

FlowQuery

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 17 TYPO3 Neos - the Compendium The Architecture of TYPO3 Neos - Frontend LOBACHER.

The Architecture of TYPO3 Neos - Frontend

! EmberJS JavaScript Web Application Framework

Create.js Web Editing Interface

Aloha / Hallo HTML5 WYSIWYG Editor

VIE = viejs.org Semantic Interaction Framework

RequireJS JavaScript file and module loader

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 18 LOBACHER.

Installation of TYPO3 Neos

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 19 TYPO3 Neos - the Compendium Requirements of TYPO3 Neos LOBACHER.

Requirements of TYPO3 Neos ! • Webserver (recommended: Apache 2.x with activated mod_rewrite Module) • PHP 5.3.7 - 5.4.x (the bare minimum PHP 5.3.2 might cause problems) • following funktions must be activated and allowed in PHP: system(), shell_exec(), escapeshellcmd() und escapeshellarg() • .ini: memory_limit = 256M or higher • php.ini: xdebug.max_nesting_level = 500 (in case xdebug is used) • php.ini: add the following Options to the end of the file: detect_unicode = Off • php.ini: additionally Magic_Quotes must be deactivated: magic_quotes_gpc = Off • php.ini: the command line of Flow requires a timezone definition: date.timezone= "Europe/Berlin" (or applicable)

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 20 TYPO3 Neos - the Compendium Requirements of TYPO3 Neos LOBACHER.

Requirements of TYPO3 Neos ! • It is important that the CLI Version of PHP is at least version 5.3.7 as well (and has the appropriate and mentioned settings) - one can check the version with the following command

php --version

• MySQL 5.1.50 - 5.x.x (as an example - basically every Doctrine DBAL compatible database can be used)

• root access to the commandline / shell

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 21 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Directory Structure LOBACHER.

Directory Structure

• Directory structure where the installation is meant to occur.

/path/to/Webserver |-TYPO3-Neos |---Build |---... |---Web (Document Root)

• All Neos-Files are in the directory TYPO3-Neos (this will be added by „Composer“ in the next steps.) • There will be no distinction between Core and UserSpace (like TYPO3 CMS) • The Document Root is to be mapped to /path/to/Webserver/TYPO3- Neos/Web

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 22 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Composer LOBACHER.

Installation of TYPO3 Neos - Composer

• Installation is done via „Composer“ (Dependency Manager for PHP) - that‘s the shell access for

cd /pfad/zum/webserver/

curl -sS https://getcomposer.org/installer | php

• This creates the composer.phar file in the current directory • If one would like to use Composer system wide, it can be copied or moved (this will be assumed in the following) mv composer.phar /usr/local/bin/composer

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 23 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Composer LOBACHER.

Installation of TYPO3 Neos - Composer

• Download TYPO3 Neos via Composer (one single line!):

php /path/to/composer.phar create-project typo3/neos-base-distribution TYPO3-Neos

• This takes care of the Installation of TYPO3 Flow, Neos and necessary Modules (incl. 3rd Party like Doctrine 2, Aloha, ...) • Afterwards one gets directory named TYPO3-Neos, which holds the latest version of Neos • The installation of Composer under Windows is covered here: http://getcomposer.org/doc/00-intro.md#installation-windows

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 24 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - use archives LOBACHER.

[Alternative:] use archives

• the latest version is offered to download on sourceforge as zip, tar.gz and tar.bz2:

http://sourceforge.net/projects/typo3flow/files/ TYPO3%20Neos/1.0.1/ •

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 25 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - GIT Version LOBACHER.

[Alternative:] use git version of TYPO3 Neos

• cloning the latest version of TYPO3 Neos via git:

git clone git://git.typo3.org/Neos/Distributions/ Base.git TYPO3-Neos && cd TYPO3-Neos

subsequently these dependencies have to be loaded:

composer install --dev

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 26 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - rights & VirtualHost LOBACHER.

Installation of TYPO3 Neos - rights & VirtualHost

• This console command sets the filesystem rights: cd TYPO3-Neos sudo ./flow flow:core:setfilepermissions shelluser wwwuser wwwgroup

(additional Info: http://docs.typo3.org/flow/TYPO3FlowDocumentation/ TheDefinitiveGuide/PartII/Installation.html#file-permissions)

• shelluser That is the User you‘re logged in on the shell with - can be found out with whoami

• wwwuser The group the Webserver Process runs with (see file httpd.conf) - under Mac OS X e.g. _www

• wwwgroup The group the Webserver Process runs with (see file httpd.conf) - under Mac OS X e.g. _www

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 27 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - VirtualHost LOBACHER.

Installation of TYPO3 Neos - VirtualHost

• Virtual Host Entry (e.g. Apache) NameVirtualHost *:80 # if needed

DocumentRoot "/path/to/webserver/TYPO3-Neos/Web/"

# during development this line should be kept # commented out, because this changes the Context to # „Production“ - meaning: no Logging, with Caching, ... Setenv FLOW_CONTEXT Production ServerName neos.demo

• Entry in /etc/hosts (e.g.: C:\windows\system32\drivers\etc\hosts) 127.0.0.1 neos.demo

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 28 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Setup LOBACHER.

Installation of TYPO3 Neos - Setup

• Call the Setup routine http://neos.demo/setup/

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 29 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Setup LOBACHER.

Installation of TYPO3 Neos - Setup

• The Password is located in the file at the path shown below. (remember!) /path/to/webserver/TYPO3-Neos/Data/SetupPassword.txt

The file containing the password is deleted afterwards. In case of Oblivion, i.e. it is forgotten, the file

/path/to/webserver/TYPO3- Neos/Data/Persistent/ FileBasedSimpleKeyService /SetupKey

is to be deleted and setup called again.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 30 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Setup LOBACHER.

Installation of TYPO3 Neos - Setup ! • setup of the database • MySQL is preset • the driver can be changed by adjusting the file: Configuration/Settings. • If 127.0.0.1 as „DB Host“ does not work, try to enter localhost instead. • you can choose between using an existing database or create a new one

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 31 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Setup LOBACHER.

Installation of TYPO3 Neos - Setup ! • create an administrator account

• User Management provides the possibility for the creation of subsequent user

• that includes adding additional user data

• creation is also possible via console:

./flow typo3.neos:user:create username password firstname lastname

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 32 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Setup LOBACHER.

Installation of TYPO3 Neos - Setup ! • one can import a demo site (recommended)

• or start with a blank website

• as soon as something is entered into the form fields, a new site is created

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 33 TYPO3 Neos - the Compendium Installation of TYPO3 Neos - Setup LOBACHER.

Installation of TYPO3 Neos - Setup ! • Once the installation cycle succeeded, the corresponding advice appears

• You will find the documentation at

http://docs.typo3.org/neos/

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 34 TYPO3 Neos - the Compendium Installation of TYPO3 Neos LOBACHER.

Installation of TYPO3 Neos - Setup

The Frontend looks like the left- handed image, if the Demo-Site TYPO3.NeosDemoTypo3Org is imported ! If an empty site has been created, the following screen is shown

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 35 TYPO3 Neos - the Compendium Installation of TYPO3 Neos LOBACHER.

Installation of TYPO3 Neos - Setup ! Access to the Installation: ! • Frontend http://neos.demo/ ! • Backend http://neos.demo/neos/ ! • Setup http://neos.demo/setup/

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 36 LOBACHER.

Installation on a domainFACTORY Server

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 37 TYPO3 Neos - the Compendium Installation on a domainFACTORY Server LOBACHER.

Installation on a domainFACTORY Server ! domainFACTORY Server require a slightly modified Installation ! • Credits to: Christian Schwerdt (die Medienagenten oHG) ! • An english manual can also be found here:

https://github.com/cschwerdt/TYPO3-NEOS-Install

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 38 TYPO3 Neos - the Compendium Installation on a domainFACTORY Server LOBACHER.

Installation on a domainFACTORY Server ! • load Composer curl -s https://getcomposer.org/installer | /usr/local/bin/php5-53STABLE-CLI ! • load TYPO3 Neos 1.0: /usr/local/bin/php5-53LATEST-CLI composer.phar create-project --dev -- stability alpha typo3/neos-base-distribution TYPO3-Neos-1.0.0

• Inside the domainFACTORY-Settings the Domain has to be configured to point to the /Web directory.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 39 TYPO3 Neos - the Compendium Installation on a domainFACTORY Server LOBACHER.

Installation on a domainFACTORY Server ! • change the PHP-Path inside the Flow-CLI cd TYPO3-Neos-1.0 vi flow

The first line has to be changed from

#!/usr/bin/env php

to the following:

#!/usr/local/bin/php5-53STABLE-CLI

Save with

:!wq

or choose any plain text editor you‘re familiar with

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 40 TYPO3 Neos - the Compendium Installation on a domainFACTORY Server LOBACHER.

Installation on a domainFACTORY Server ! • adjusting Settings.yaml in Configuration/ cd Configuration/ cp Settings.yaml.example Settings.yaml vi Settings.yaml

//set database host db: 'mysql5.'

//uncomment core: & phpBinaryPathAndFilename //and change phpBinaryPathAndFilename to: core: phpBinaryPathAndFilename: '/usr/local/bin/php5-53STABLE-CLI'

save with:

:wq! !

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 41 TYPO3 Neos - the Compendium Installation on a domainFACTORY Server LOBACHER.

Installation on a domainFACTORY Server ! • adjusting Settings.yaml in Development cd Development/ cp Settings.yaml.example Settings.yaml vi Settings.yaml

//set dbname, dbuser, dbpassword: dbname: '' user: '' password: ''

save with:

:wq! !

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 42 TYPO3 Neos - the Compendium Installation on a domainFACTORY Server LOBACHER.

Installation on a domainFACTORY Server ! • Flow Help ./flow help

• migrate Database ./flow doctrine:migrate

• kickstart a Site Syntax: ./flow site:kickstart [PackageKey] [SiteName] ./flow site:kickstart Your.Demopage Your.Demopage

• list Sites ./flow site:list ! !

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 43 TYPO3 Neos - the Compendium Installation on a domainFACTORY Server LOBACHER.

Installation on a domainFACTORY Server ! • add Neos Backend User ./flow user:create

• add Admin Userrole ./flow user:addrole Administrator ! • Finished :-) !

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 44 LOBACHER.

Installation on a all-inkl.com Server

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 45 TYPO3 Neos - the Compendium Installation on a all-inkl.com Server LOBACHER.

Installation on a all-inkl.com Server ! On the servers of „ALL-INKL.COM - Neue Medien Münnich“ you have to follow a slightly different installation instruction.

• Credits to: Mario Janetzko (die Medienagenten oHG)

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 46 TYPO3 Neos - the Compendium Installation on a all-inkl.com Server LOBACHER.

Installation on a all-inkl.com Server ! • Prior to installation the following steps have to executed ! • open the file Bootstrap.php at /Packages/Framework/ TYPO3.Flow/Classes/TYPO3/Flow/Core/

• add the following after namespace TYPO3\Flow\Core;

ini_set('date.timezone','Europe/Berlin'); ini_set('memory_limit','256M');

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 47 TYPO3 Neos - the Compendium Installation on a all-inkl.com Server LOBACHER.

Installation on a all-inkl.com Server ! • comment out the lines 557 - 560 in the file Bootstrap.php

OLD:

if (version_compare(PHP_VERSION, '5.4', '<') && get_magic_quotes_gpc() === 1) { echo('Flow requires the PHP setting "magic_quotes_gpc" set to Off. (Error #1224003190)’); exit(1); }

NEW:

/* if (version_compare(PHP_VERSION, '5.4', '<') && get_magic_quotes_gpc() === 1) { echo('Flow requires the PHP setting "magic_quotes_gpc" set to Off. (Error #1224003190)’); exit(1); } */

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 48 TYPO3 Neos - the Compendium Installation on a all-inkl.com Server LOBACHER.

Installation on a all-inkl.com Server ! • add the following lines to the file Web/index.php starting at line 23:

… require($rootPath . 'Packages/Framework/TYPO3.Flow/Classes/TYPO3/Flow/Core/ Bootstrap.php');

putenv ("FLOW_REWRITEURLS=1"); putenv ("FLOW_CONTEXT=Production"); if (substr($_SERVER['HTTP_HOST'],0,4) === 'dev.') { putenv ("FLOW_CONTEXT=Development"); }

$context = getenv('FLOW_CONTEXT') ?: (getenv('REDIRECT_FLOW_CONTEXT') ?: 'Development'); …

• The installation can be started now!

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 49 LOBACHER.

Troubleshoot FAQ / Help

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 50 TYPO3 Neos - the Compendium Troubleshoot / FAQ / Help LOBACHER.

alternative methods of Installation and Support please note: some of the links might be in german! • TYPO3 Neos Vagrant Box https://github.com/tlayh/vagrant-typo3neos • TYPO3 Neos Installation on Mac OS X Snow Leopard and MAMP http://www.content-driven-ecommerce.de/typo3-neos-install/ • .git ignore File https://git.typo3.org/Neos/Distributions/Base.git/blob/ HEAD:/.gitignore • Launchr (test TYPO3 Neos online) https://launchr.com/ • Mittwald Hosting - 30 days trial TYPO3 Neos Account https://www.mittwald.de/neos-testen/ • Manual Installation by jweiland.net http://jweiland.net/typo3/neos/neos-installation/manuelle-neos- installation.html

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 51 TYPO3 Neos - the Compendium Troubleshoot / FAQ / Help LOBACHER.

problems that may arise during installation • In the PHP log or on the console while issuing ./flow help or on the frontend an error message which is similar to the following appears: • ...'"typo3eel" is not a valid package key... Workaround: use a patched Composer file: http://downloads.sourceforge.net/project/typo3flow/patched-1147-composer.phar

• There is an error message which is similar to the following: ...Class 'PHPUnit_Framework_Constraint' not found in... oder ...imagine... (something refers / hints to imagine) Solution: Deletion of the PackageStates file rm Configuration/PackageStates.php

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 52 LOBACHER.

Nginx Config for TYPO3 Neos

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 53 TYPO3 Neos - the Compendium Nginx Config for TYPO3 Neos LOBACHER.

Nginx Config for TYPO3 Neos ! • Credits to: • Christian Kuhn • Christian Müller • Anja Leichsenring

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 54 TYPO3 Neos - the Compendium Nginx Config for TYPO3 Neos LOBACHER.

Nginx Config for TYPO3 Neos ! • File /etc/nginx/sites-available/neos.demo (Domain assumed neos.demo) # Upstream to abstract backend connection(s) for php upstream neos.demo { server unix:/var/run/neos.demo_fpm.sock; } server { server_name neos.demo; root /path/to/webserver/TYPO3-Neos/Web; i n d e x i n d e x . p h p ; error_log /path/to/webserver/TYPO3-Neos/logs/error_log; access_log /path/to/webserver/TYPO3-Neos/logs/access_log; ## Disable .htaccess and other hidden files l o c a t i o n ~ / \ . { d e n y a l l ; a c c e s s _ l o g o f f ; l o g _ n o t _ f o u n d o f f ; } location = /favicon.ico { l o g _ n o t _ f o u n d o f f ; a c c e s s _ l o g o f f ; } location = /robots.txt { a l l o w a l l ; l o g _ n o t _ f o u n d o f f ; a c c e s s _ l o g o f f ; }

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 55 TYPO3 Neos - the Compendium Nginx Config for TYPO3 Neos LOBACHER.

Nginx Config for TYPO3 Neos ! • File /etc/nginx/sites-available/neos.demo (...continued...) location /_Resources/ { a c c e s s _ l o g o f f ; l o g _ n o t _ f o u n d o f f ; e x p i r e s m a x ; b r e a k ; } location /_Resources/Persistent/ { a c c e s s _ l o g o f f ; l o g _ n o t _ f o u n d o f f ; e x p i r e s m a x ; rewrite "(.{40})/.+\.(.+)" /_Resources/Persistent/$1.$2 break; rewrite "([a-z0-9]+/(.+/)?[a-f0-9]{40})/.+\.(.+)" /_Resources/Persistent/$1.$2 break; } # # # # stop rewriting by existing files | is instead of -> location / { rewrite ".*" /index.php last; } # use this if you want to run other PHP-Applications in TYPO3-Flow/Web directory # # # try_files $uri $uri/ /index.php?$args;

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 56 TYPO3 Neos - the Compendium Nginx Config for TYPO3 Neos LOBACHER.

Nginx Config for TYPO3 Neos ! • File /etc/nginx/sites-available/neos.demo (...last part...) location ~ \.php$ { fastcgi_index index.php; # # # # for FLOW3 <= 1.1.x only | see note #15 on http://forge.typo3.org/issues/8923 # # # # fastcgi_param FLOW3_CONTEXT Development; # fastcgi_param FLOW3_CONTEXT Production; # fastcgi_param FLOW3_REWRITEURLS 1; # # # # Make sure that you set the environment vars for new versions \ # of TYPO3-XXXXX(TYPO3-Neos) products properly # see note #15 on http://forge.typo3.org/issues/8923 ### fastcgi_param FLOW_CONTEXT Development; fastcgi_param FLOW_REWRITEURLS 1; fastcgi_split_path_info ^(.+\.php)(.*)$; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param PATH_INFO $fastcgi_path_info; fastcgi_pass neos.domain.tld; include /etc/nginx/fastcgi_params; } }

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 57 TYPO3 Neos - the Compendium Nginx Config for TYPO3 Neos LOBACHER.

Nginx Config for TYPO3 Neos ! • File /etc/php5/fpm/pool.d/neos.demo.pool.conf

[neos.demo] listen = /var/run/neos.demo.sock listen.owner = neos.demo listen.group = demo listen.mode = 0660 user = neos.demo group = demo pm = dynamic pm.max_children = 50 pm.start_servers = 5 pm.min_spare_servers = 3 pm.max_spare_servers = 10 pm.max_requests = 200 request_terminate_timeout = 360s chdir = / php_admin_value[session.save_path] = "/path/to/webserver/TYPO3-Neos/sessions" # During installation this might not be sufficient, cleaned it up afterwards. # Neos mentions it, add it, restart php-fpm, go on. Sufficient for operation. php_admin_value[open_basedir] = "/path/to/webserver/TYPO3-Neos/:/usr/share/:/usr/share/php:/tmp:/usr/local/ lib/php:/usr/bin/php"

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 58 TYPO3 Neos - the Compendium Nginx Config for TYPO3 Neos LOBACHER.

Nginx Config for TYPO3 Neos ! • File Configuration/Settings.yaml

TYPO3: Flow: persistence: backendOptions: dbname: ... user: ... password: ... host: 127.0.0.1 core: ! subRequestPhpIniPathAndFilename: /etc/php5/cli/php.ini

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 59 LOBACHER.

Upgrade of TYPO3 Neos

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 60 TYPO3 Neos - the Compendium Upgrade von TYPO3 Neos LOBACHER.

Upgrade von TYPO3 Neos ! lifting an existing 1.0 installation to the latest patch level can be achieved as follows: cd /pfad/zum/webserver/ composer update --no-dev "typo3/*" # flush Cache! ./flow flow:cache:flush --force ./flow doctrine:migrate

If necessary php composer.phar has to be used!

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 61 TYPO3 Neos - the Compendium Upgrade of TYPO3 Neos LOBACHER.

Upgrade of TYPO3 Neos ! If there is an existing Neos, it can be updated to a given version quite comfortable using Composer: ! cd /path/to/webserver/ composer require "typo3/neos:1.0.*" composer require "typo3/neos-nodetypes:1.0.*" composer require "typo3/neosdemotypo3org:1.0.*" composer require "typo3/neos-kickstarter:1.0.*" # flush Cache! ./flow flow:cache:flush --force ./flow doctrine:migrate

If necessary php composer.phar has to be used!

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 62 TYPO3 Neos - the Compendium Usage of Development Master LOBACHER.

Usage of Development Master ! If by all means one would like to use the latest (trunk in git lingo) TYPO3 Neos, one can switch to the Development Master cd /path/to/webserver/ composer update update database: ./flow doctrine:migrate

flush cache: ./flow flow:cache:flush --force

If necessary php composer.phar has to be used!

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 63 LOBACHER.

Virtual Machines

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 64 TYPO3 Neos - the Compendium Virtual Machines LOBACHER.

Virtual Machines ! A few projects are offering virtual machines for TYPO3 Neos (and Flow):

• Vagrant (TYPO3 Neos / Flow oder CMS has to be installed yourself) https://github.com/swiftlizard/VagrantTYPO3

• Vagrant (TYPO3 Neos / Flow oder CMS has to be installed yourself) https://github.com/mrimann/VagrantTYPO3Flow

• fully working TYPO3 Neos https://launchr.com/typo3-neos

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 65 LOBACHER.

Release Notes

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 66 TYPO3 Neos - the Compendium Release Notes LOBACHER.

Release Notes TYPO3 Neos 1.0.1 (2013-12-13) ! • [TASK] Update references in documentation • [BUGFIX] Handle inline loading of pages without metadata correctly • [BUGFIX] Use FQ TypoScript paths for lastVisitedNode functionality • [BUGFIX] Add a safeguard to the LIBXML_PARSEHUGE constant • [BUGFIX] Fix wrong type annotation that causes compilation problems • [BUGFIX] Fix built-in Menu TypoScript object template • [BUGFIX] Protypes don't use FQN • [BUGFIX] Correctly link the Neos logo with the NodeViewHelper ! • https://git.typo3.org/Packages/TYPO3.Neos.git/blob_plain/ e87653620afa44112fc8b32414c9d90d464b3b00:/Documentation/Appendixes/ ChangeLogs/101.rst

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 67 TYPO3 Neos - the Compendium Release Notes LOBACHER.

Release Notes TYPO3 Neos 1.0.2 (2014-03-04) - Part 1

TYPO3.Neos • [TASK] Update references in documentation • [BUGFIX] Secondary inspector is rendered outside viewport in FF • [BUGFIX] A better way of parsing the HTML of asynchronous page loads • [TASK] Optimize typical filter usages of EEL children operation • [BUGFIX] Default attributes property of menu TypoScript object • [BUGFIX] "node" used in label for create new dialog • [BUGFIX] Security policies in Neos are too strict • [BUGFIX] Link inceptor handling of local links • [BUGFIX] Node tree filter too wide in Firefox • [BUGFIX] Sites management module widget action button • [TASK] Improve usability of position menus in navigate component • [BUGFIX] Title missing for paste/new buttons in navigate component • [BUGFIX] Shortcut to siteroot has no active state • [TASK] Fix minor errors in documentation • [!!!][BUGFIX] Only accepts URLs with the configured URI suffix • [BUGFIX] YAML indention and typo in integrators cookbook • [TASK] Fix various CGL violations • [BUGFIX] Opacity of datetime editor inspector field • [TASK] Add missing grunt-trimtrailingspaces dependency

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 68 TYPO3 Neos - the Compendium Release Notes LOBACHER.

Release Notes TYPO3 Neos 1.0.2 (2014-03-04) - Part 2 • [FEATURE] Reworked MenuImplementation • [TASK] Minor coding fixes for users management module • [BUGFIX] Remove obsolete route that might break routing • [TASK] Fix Page documentation in TS reference • [BUGFIX] Correctly rename site root nodes • [BUGFIX] Menu section collapse arrow styling • [BUGFIX] Headline alignment is not persisted • [BUGFIX] Shortcut rendering is broken in combination with layout • [BUGFIX] Dateselector should do "previous" too

TYPO3.TYPO3CR ! • [BUGFIX] Node references do not respect context workspace • [BUGFIX] Prevent database error with too long index • [BUGFIX] materialize NodeData in removeProperty() • [TASK] Fix wrong hint in method docblock ! TYPO3.TypoScript • [BUGFIX] isEven & isOdd not supported in TYPO3.Neos:ContentCollection

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 69 LOBACHER.

Features of TYPO3 Neos

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 70 TYPO3 Neos - the Compendium Features of TYPO3 Neos LOBACHER.

Features of TYPO3 Neos

• most extensible Enterprise CMF - Content Management Framework • based on the stable TYPO3 Flow Framework, already available in Version 2.0 • easy und flexible Content Export/Import (until now only via command line) • Multi-Domain Support • state-of-the-art Technology und Paradigms under the hood (DDD, AOP, RequireJS, EmberJS, ...) • Intuitive User Interface • Wireframe Mode - Content-Editing without Template • web based Package Management

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 71 TYPO3 Neos - the Compendium Features of TYPO3 Neos LOBACHER.

Features of TYPO3 Neos

• In-place Content-Editing • own Content Elements (incl. In-place Content-Editing) easily possible • Integration of TYPO3 Flow Applications as Plugins (packages) • TypoScript2 / Eel / FlowQuery • Workspaces (currently no multi user capabilities) • Custom Single-Sign-On / Custom Authentification through custom plugins • Audit Logging • TYPO3 Surf for the automatic Deployment (Integration with CI Server like Jenkins)

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 72 TYPO3 Neos - the Compendium Features of TYPO3 Neos LOBACHER.

so far missing features ! • Web based Installer (currently needs command line with Root Access) • Multilingualism (Content & User Interface) • User / Roles without Admin Rights (Editors, well there is an„Editor User“, but so far it’s just a a „Non-Admin“) • User Rights / User Groups • ACLs (Access Control Lists) • Public Extensions (no Package Repository yet) • Shared Workspaces • Versioning (UI-Interface) • Non-Core-Features: News, connection to 3rd-Party-Systems, Slider, SSL, Google Analytics Integration, ... • REST

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 73 TYPO3 Neos - the Compendium Features of TYPO3 Neos LOBACHER.

so far missing features ! • Logs (User, Admin, ...) • SEO-Features (page properties: noindex, nofollow, keywords, description, canonical, ...) • proper RWD-Interface (Interface only works at approx. 1000px and bigger) • RWD-Rendering of Images (responsive web design) • Digital Asset Management (there’s no media browser) • Form Designer (currently one can only choose programmatically prepared forms) • Content Synchronization and Syndication • Admin Interface to edit arbitrary records • ...

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 74 LOBACHER.

Structure of the Neos user interface

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 75 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

Login

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 76 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

Publish Publish, possibility of User-Administration Structure of the Admin-Interface „auto publishing“ Logout and Settings Page Browser structural when clicking on the Operations Menu (pagetree) view arrow

Inspector content specific properties like page properties or the like

Preview Mode Display of how the page would look live

Preview Central e.g. display without design

Apply

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 77 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

selected element e.g. Headline, Content-Collection, Page, ... Properties Panel Properties context sensitive properties, e.g. page properties and the like

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 78 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

operations menu

Content switch between the different sites

Workspaces

Media Browser

User Management

Package Management

Sites Management

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 79 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

declaration administration of Workspaces of Publish Discard

selection of Node Type single changes

type of change

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 80 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

administration of Workspaces

Pages that contain modifications are marked orange

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 81 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

user administration View Edit Delete Role

add new user

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 82 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

user administration - new user

To add a new user simply provide username, password and personal data. Additionally the Role (Admin or Editor) is chosen.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 83 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

User Administration - editing

Here userdata can be edited and extended with a title or an alias. ! Additionally one can add an arbitrary amount of "electronic addresses" like Email addresses, Skype, etc. ! By chosing "primary" one selects the main address.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 84 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

User Administration - Info

The „Info“ Function gives an overview of all entered data.

A Click on „Delete“ opens a Lightbox, in which the requested action is confirmed and the user warned about the result.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 85 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

Freeze Deactivate Delete Package Administration & Unfreeze & Activate

select

actions on the selection

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 86 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

Site Administration Overview

Deactivate Edit Delete Status of this Site & Activate Add new Site

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 87 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

deactivate edit Domain Site Administration - Editing Domain

delete Domain

add Domain

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 88 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

Raw Content Mode - Display of the Elements without Design

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 89 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

Preview Central - alternative displays

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 90 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

insert (inside) Pagetree refresh

add new page delete the selected page edit page title

toggle visibility

copy page Cut

search in pagetree

double click to change filter the pagetree by Type page title (Page, Shortcut, …)

click on the page title

to view the page in the Drag&Drop preview to the right to move Page

91 (c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

structure tree

The structure tree lists all elements (visible and hidden) of the current page hierarchically.

The same Icons for functions like „New“, „Hide“, „Copy“ are available here as well.

A click on the Heading opens its properties in the inspector to the right and places the InPlace-Editor appropriately.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 92 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

Content-Funktionen add new Content cut copy Element after the Content Element Content Element selected „Insert“ appears as soon as one clicks „Copy“ or „Cut“

hide delete Content Element Content Element

93 (c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

add add add Link (format free) Clipboard Table Content Functions Paragraph Styles

self-explanatory? ;-)

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 94 TYPO3 Neos - the Compendium Features of TYPO3 Neos - Screenshots LOBACHER.

add a Content Element

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 95 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

Multi-Column Content Elements

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 96 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

choose forms

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 97 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

Media Browser Upload View

Tagging

tag a file by drag&drop it onto the tag

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 98 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

Media Browser

Meta Data

Actions

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 99 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

Media- Upload Crop Image Handling Browser

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 100 TYPO3 Neos - the Compendium Features von TYPO3 Neos - Screenshots LOBACHER.

Cropping (unobstrusive)

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 101 LOBACHER.

Internals of TYPO3 Neos

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 102 TYPO3 Neos - the Compendium TYPO3 Neos Internals: Node Structure LOBACHER.

Node Structure Site root ! • TYPO3CR Node Page • Node Name (serves as Identification)

• Node Type Content Section (e.g. Document, Folder, AbstractNode, Content, ContentCollection...) • Properties Content Element (dependent on NodeType)

Domain Model • easily extendible and easily configurable

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 103 TYPO3 Neos - the Compendium TYPO3 Neos Internals: Node Type LOBACHER.

Node Type ! • each TYPO3CR Node has a so-called Node Type

• Node Types are declared in each Package by defining them in the file Configuration/ NodeTypes.yaml

• Each Node Type can have one or more parent types. If specified, all properties and settings of the parent types are inherited

http://docs.typo3.org/neos/TYPO3NeosDocumentation/IntegratorGuide/ContentStructure.html#nodes-inside-the-typo3-content-repository

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 104 TYPO3 Neos - the Compendium TYPO3 Neos Internals: Node Type LOBACHER.

predefined Node Types: ! • TYPO3.Neos:Node This is the base type that should be extended by all Content-Types that are used in the Context of TYPO3 Neos. There are no properties whatsoever.

• TYPO3.Neos:Document An important differentiation is made between Nodes that act (and look) as a Page and „normal content“ like Text that is rendered on a page. Nodes that act like a page are called „Document Nodes“ in Neos which, for instance, have a unique and publicly visible URL in Neos. The default Page within Neos is implemented by the Node Type TYPO3.Neos.NodeTypes:Page which is directly extended from TYPO3.Neos:Document.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 105 TYPO3 Neos - the Compendium TYPO3 Neos Internals: Node Type LOBACHER.

predefined Node Types: ! • TYPO3.Neos:ContentCollection and TYPO3.Neos:Content Any content that acts as a page and resides in such a node is implemented through two different Node Types:

• TYPO3.Neos:ContentCollection type This Node Type serves structuring and usually does not contain any properties, but an ordered list of sub-nodes instead which are rendered inside this node. Currently one should not extend from this type when defining own node types. • TYPO3.Neos:Content This is the node type for all standard elements like „text“, „image“, „youtube“, ...

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 106 TYPO3 Neos - the Compendium TYPO3 Neos Internals: Node Zugriff LOBACHER.

Node Access ! • Access to the Nodes is happens through „NodePaths“ • Each Page is a node, so is every element on that page.

/sites/typo3org/home/subpage/main/text1

site root section pages content

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 107 TYPO3 Neos - the Compendium TYPO3 Neos Internals: TypoScript LOBACHER.

TypoScript ! • TypoScript is a hierarchic, object oriented and prototype based processing language • Is used by Neos for flexible rendering of content • Objects are e.g. Array, Collection, Case, Menu, Page, Template, Plugin, Value, ... • Objects have properties that „configure“ the object • TypoScript has access to the respective „Context“ (e.g. pagetree of the Object „menu“ oder page properties of the object „page“) • There are "processors" that can change the value of properties (similar to the stdWrap functions of TYPO3 CMS) ! (c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 108 TYPO3 Neos - the Compendium TYPO3 Neos Internals: TypoScript - Fluid Template LOBACHER.

TypoScript: Fluid Template {namespace neos=TYPO3\Neos\ViewHelpers} {namespace ts=TYPO3\TypoScript\ViewHelpers}

{content.main -> f:format.raw()}

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 109 TYPO3 Neos - the Compendium TYPO3 Neos Internals: TypoScript - Example - Part 1 LOBACHER.

TypoScript: Example - Part 1 include: NodeTypes/Carousel.ts2 namespace: TypoScript=TYPO3.TypoScript /** * Root TypoScript template for the Neos website */ page = Page { head { stylesheets.site = TypoScript:Template { templatePath = 'resource://TYPO3.NeosDemoTypo3Org/Private/Templates/Page/Default.html' sectionName = 'stylesheets' } ! metadata = TypoScript:Template { templatePath = 'resource://TYPO3.NeosDemoTypo3Org/Private/Templates/Page/Default.html' sectionName = 'metadata' } ! titleTag { // Overwrite the title tags content with a collection to create a breadcrumb content = TYPO3.TypoScript:Collection { // Retrieve all parent document nodes excluding the homepage collection = ${q(documentNode).add(q(documentNode).parents()).slice(0, -1).get()} itemName = 'node' iterationName = 'nodeIterator' // Implode node titles with a dash

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 110 TYPO3 Neos - the Compendium TYPO3 Neos Internals: TypoScript - Example - Part 2 LOBACHER.

TypoScript: Example - Part 2 ! // This query checks if the second level menu has items and sets an additional class for the body bodyTag.attributes.class = ${q(node).parents().count() >= 1 && q(node).children('[instanceof TYPO3.Neos:Document]').filter('[_hiddenInIndex=false]').count() > 0 ? 'has-subpages' : ''} ! body { templatePath = 'resource://TYPO3.NeosDemoTypo3Org/Private/Templates/Page/Default.html' sectionName = 'body' ! parts { mainMenu = Menu { entryLevel = 1 templatePath = 'resource://TYPO3.NeosDemoTypo3Org/Private/Templates/ TypoScriptObjects/MainMenu.html' maximumLevels = 3 } secondLevelMenu = Menu { entryLevel = 2 templatePath = 'resource://TYPO3.NeosDemoTypo3Org/Private/Templates/ TypoScriptObjects/SecondLevelMenu.html' maximumLevels = 1 }

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 111 TYPO3 Neos - the Compendium TYPO3 Neos Internals: TypoScript - Prozessoren LOBACHER.

TypoScript: Processors • Beispiel:

myObject = MyObject { property = 'Rocky' [email protected] = ${'My ' value + ' is the best!'} }

# results in 'My Rocky is the best!'

• can also be written as:

myObject = MyObject { property = 'some value' [email protected] { expression = ${'before ' + value + ' after'} @position = 'start' } }

• Processor are Eel Expressions or TypoScript Objects, which are applied to the value of the context. The current Object can be accessed via this.

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 112 TYPO3 Neos - the Compendium TYPO3 Neos Internals: Eel - Embedded Expression Language LOBACHER.

Eel - Embedded Expression Language • While TypoScript contains Assignments and Processors, with Eel one can form expressions in the style of myObject.foo = ${q(node).property('bar')} • The Embedded Expression Language (Eel) is a component to create Domain Specific Languages (DSL). • Eel provides a comprehensive Syntax to create arbitrary expressions, so the author of the DSL can focus on the semantics

${foo.bar} // Traversal ${foo.bar()} // Method call ${foo.bar().baz()} // Chained method call

${foo.bar("arg1", true, 42)} // Method call with arguments ${12 + 18.5} // Calculations are possible ${foo == bar} // ... and comparisons

${foo.bar(12+18.5, foo == bar)} // everything combined ${[foo, bar]} // Array Literal ${{foo: bar, baz: test}} // Object Literal

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 113 TYPO3 Neos - the Compendium TYPO3 Neos Internals: FlowQuery LOBACHER.

FlowQuery • FlowQuery is a kind of jQuery for TYPO3 Flow • FlowQuery provides a way to process content (which is a TYPO3CR Node in Neos) with Eel • There are operations in FlowQuery: • property access to the properties of a node • filter filter expressions in „Fizzle“ • children returns all children of a TYPO3CR Node • parents returns all parents of a TYPO3CR Node • additional operations: add, count, first, get, is, last, ...

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 114 TYPO3 Neos - the Compendium TYPO3 Neos Internals: FlowQuery - Examples LOBACHER.

FlowQuery - Examples • amount of comments = amount of child elements of the current node whose name is "comments", having a property "spam" set to "false" numberOfComments = ${q(node).children('comments').children("[spam = false]").count()} • breadcrumb menu = current page + all parent pages prototype(TYPO3.Neos:Breadcrumb) < prototype(TYPO3.TypoScript:Template) { templatePath = 'resource://TYPO3.Neos/Private/Templates/TypoScriptObjects/ BreadcrumbMenu.html' node = ${node} items = ${q(node).add(q(node).parents('[instanceof TYPO3.Neos:Document]'))} } {namespace neos=TYPO3\Neos\ViewHelpers}

f:format.raw()}> {item.label} < u l > < / u l > < / f : i f > < / l i > < / f : f o r >

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 232 TYPO3 Neos - the Compendium Getting started: add a Site - Analysis Of Root.Ts2 LOBACHER.

Analysis of Root.ts2 - Body section & Template - Menu • the TypoScript for the Prototype Menu: # TYPO3.Neos:Menu provides basic menu rendering # prototype(TYPO3.Neos:Menu) < prototype(TYPO3.TypoScript:Template) { @class = 'TYPO3\\Neos\\TypoScript\\MenuImplementation' templatePath = 'resource://TYPO3.Neos/Private/Templates/TypoScriptObjects/Menu.html' n o d e = $ { n o d e } items = ${this.items}

active.attributes = TYPO3.TypoScript:Attributes { c l a s s = ' a c t i v e ' } current.attributes = TYPO3.TypoScript:Attributes { c l a s s = ' c u r r e n t ' } normal.attributes = TYPO3.TypoScript:Attributes { c l a s s = ' n o r m a l ' } @exceptionHandler = 'TYPO3\\Neos\\TypoScript\\ExceptionHandlers\\NodeWrappingHandler' }

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 233 TYPO3 Neos - the Compendium Getting started: Site anlegen - Analyse Root.ts2 LOBACHER.

Analyse Root.ts2 - Body-Bereich & Template - Menu • this is how the class menu (in extracts) looks like: class MenuImplementation extends \TYPO3\TypoScript\TypoScriptObjects \TemplateImplementation { const MAXIMUM_LEVELS_LIMIT = 100; const STATE_NORMAL = 'normal'; const STATE_CURRENT = 'current'; const STATE_ACTIVE = 'active'; p r o t e c t e d $ i t e m s ; protected $currentNode; public function getEntryLevel() { return $this->tsValue('entryLevel'); } public function getMaximumLevels() { $maximumLevels = $this->tsValue('maximumLevels'); if ($maximumLevels > self::MAXIMUM_LEVELS_LIMIT) { $maximumLevels = self::MAXIMUM_LEVELS_LIMIT; } return $maximumLevels; } ...

(c) 2014 - Patrick Lobacher | TYPO3 Neos 1.0.2 - the Compendium | 2014-03-07 | www.lobacher.de 234 TYPO3 Neos - the Compendium Getting started: add a Site - Analysis Of Root.Ts2 LOBACHER.

Analysis of Root.ts2 - Body section & Template - Breadcrumb • responsbile for the rendering of the menu via breadcrumb = Breadcrumb is the TypoScript under TYPO3.Neos/Private/Templates/TypoScript/DefaultTypoScript.ts2 and hence the Template templatePath = 'resource://TYPO3.Neos/Private/Templates/TypoScriptObjects/ BreadcrumbMenu.html':

{namespace neos=TYPO3\Neos\ViewHelpers}