TYPO3 Extbase, 3. Auflage (Deutsch)
TYPO3 Extbase, 3. Auflage (Deutsch)
Moderne Extension-Entwicklung mit Extbase und Fluid
Über das Buch
Extensions („Erweiterungen“) spielen eine zentrale Rolle bei der Entwicklung komplexer TYPO3 CMS Installationen. Entsprechend ist versiertes Know-how in der Programmierung dieser Erweiterungen eine Kernkompetenz von TYPO3 Entwicklern. Als Standard für die Umsetzung gelten heute das Extbase Framework und die Fluid Templating Engine.
Dieses Fachbuch gibt Einsteigern sowie Fortgeschrittenen solides Wissen an die Hand, um Projekte jeder Größe mit Extbase und Fluid zu planen, umzusetzen und langfristig effizient zu warten. Von den Grundlagen der objektorientierten Programmierung in PHP über die Prinzipien des Domain-driven Design (DDD) bis hin zum Model View Controller (MVC) Konzept werden sowohl theoretische Aspekte als auch praktische Lösungen erläutert. Nach einer leicht verständlichen Einführung in die Grundlagen, folgt eine Schritt-für-Schritt-Anleitung zur Entwicklung realer, komplexer Szenarien unter Verwendung von bewährten Methoden. Ein Kapitel ist dem Thema Sicherheitsstandards in TYPO3 Extensions gewidmet. Erfahren Sie mehr darüber, wie Sie wirksame Maßnahmen etablieren und typische Schwachstellen beim Erstellen von Erweiterungen vermeiden können.
Das Buch verschafft TYPO3 Entwicklern den Zugang zur anspruchsvollen Thematik und zeigt, wie sauberer Code nach modernen Standards und unter Beachtung moderner Programmierprinzipien für TYPO3 v9 LTS geschrieben wird.
Inhaltsverzeichnis
-
Vorwort
- Patricks Hintergrund
- Michaels Hintergrund
- Danksagung
- Piraterie
- Hinweise zur deutschen Ausgabe
-
1. Die Entstehungsgeschichte von Extbase und Fluid
- 1.1 Der Ursprung von TYPO3
- 1.2 Das Berlin Manifesto
- 1.3 Das neue PHP-Framework
- 1.4 Der Tod des Phoenix
- 1.5 Die Trennung
- 1.6 Extbase und Fluid
-
2. Grundlagen der PHP Programmierung
- 2.1 Objektorientierte Programmierung
- 2.2 Klassen und Objekte
-
2.3 Methoden
- 2.3.1 Der Pfeil-Operator (“Arrow Operator”)
- 2.3.2 Der Konstruktor (“Constructor”)
-
2.3.3 Zugriff mittels
$this
- 2.3.4 Funktionen mit Inhalten füllen
-
2.4 Vererbung von Klassen
-
2.4.1 Zugriff mittels
parent
- 2.4.2 Überprüfung der Klassenzugehörigkeit
-
2.4.1 Zugriff mittels
- 2.5 Abstrakte Klasse
- 2.6 Interfaces
-
2.7 Sichtbarkeit:
public
undprotected
- 2.7.1 Getter und Setter
- 2.8 Type Hints
- 2.9 Datentyp-Deklaration für Rückgabewerte
- 2.10 Strenge Typisierung (“Strict Types”)
- 2.11 Statische Zugriffe
- 2.12 Namespaces
-
2.13 Wichtige Entwurfs- und Architekturmuster
- 2.13.1 Singleton
- 2.13.2 Prototype
- 2.13.3 Dependency Injection
- 2.14 Annotations
-
2.15 Programmierstandards
- 2.15.1 PSR-1
- 2.15.2 PSR-2
- 2.15.3 Code-Kommentare
-
3. Domain-Driven Design
- 3.1 Infrastructure Ignorance
- 3.2 Vertikale Schichtarchitektur
-
3.3 Das Domänenmodell
- 3.3.1 Ubiquitous Language
- 3.3.2 Bausteine für das DDD
-
3.4 Strukturierung von DDD
- 3.4.1 Bounded Context
- 3.4.2 Context Map
- 3.4.3 Core Domain
- 3.4.4 Shared Kernel
- 3.4.5 Zusammenfassung
-
4. Vorbereitung
-
4.1 Installation von TYPO3
- 4.1.1 Systemanforderungen
- 4.1.2 Installation mit PHP Composer
- 4.1.3 Site Package
- 4.1.4 Development Application Context
-
4.2 Grundlagen von TYPO3-Extensions
- 4.2.1 Extension Keys
- 4.2.2 TYPO3 Extension Repository (TER)
- 4.2.3 TER Extensions und Composer
- 4.2.4 Weitere Methoden zur Veröffentlichung
- 4.2.5 Extensions, Plugins, Modules und Distributions
- 4.2.6 Hinter den Kulissen
- 4.2.7 Datei- und Verzeichnisstruktur
- 4.3 Entwicklungsumgebung
- 4.4 Zusammenfassung
-
4.1 Installation von TYPO3
-
5. Erstellen eines Domänenmodells
- 5.1 In diesem Buch verwendetes Domänenmodell
-
5.2 Grundkonzept
- 5.2.1 Das Glossar
- 5.2.2 Domain Model (“Domänenmodell”)
-
5.3 Der TYPO3 Extension Builder
- 5.3.1 Historie
- 5.3.2 So funktioniert der Extension Builder
- 5.3.3 Zielgruppe
- 5.3.4 Einschränkungen
- 5.3.5 Installation
- 5.3.6 Extension Eigenschaften (Properties)
- 5.3.7 Domain Model
- 5.3.8 Die Eigenschaften des Domänenmodells
- 5.3.9 Relationen im Domänenmodell
- 5.4 Aktivierung der Extension
- 5.5 Automatisches Laden von PHP-Klassen (“Autoloading”)
- 5.6 Zusammenfassung
-
6. Analyse der initialen Dateien
-
6.1 Vom Extension Builder erstellte Dateien
-
6.1.1 Dateien im Ordner
Classes/
-
6.1.2 Dateien in dem Ordner
Configuration/
-
6.1.3 Dateien im Ordner
Resources/
-
6.1.4 Dateien im Ordner
Tests/
- 6.1.5 Dateien im Stammverzeichnis
-
6.1.6 Datei
ext_tables.php
-
6.1.1 Dateien im Ordner
-
6.2 Zusätzliche Funktionalität des Extension Builders
- 6.2.1 Modifizieren des Models
-
6.3 TypoScript
constants
undsetup
- 6.4 Zusammenfassung
-
6.1 Vom Extension Builder erstellte Dateien
-
7. Der CRUD-Prozess
- 7.1 Model-View-Controller in Extbase
-
7.2 Erstellen eines Objekts (“Create”)
- 7.2.1 Erstellen einer “Action” im Controller
-
7.2.2 Erstellen des Templates für die
listAction()
- 7.2.3 Anmerkung: Template-Rendering
- 7.2.4 Statische Blogs erstellen
- 7.2.5 Blogs persistieren (speichern)
- 7.2.6 Wie Persistenz funktioniert
- 7.2.7 Die manuelle Speicherung durch den PersistenceManager
- 7.2.8 Eigene Action erstellen
- 7.2.9 Formular zum Anlegen eines Objekts
- 7.3 Lesen eines Objekts (“Read”)
- 7.4 Aktualisierung eines Objekts (“Update”)
-
7.5 Löschen eines Objekts (“Delete”)
- 7.5.1 Übung
-
7.6 Anpassung des visuellen Erscheinungsbildes
- 7.6.1 “Font Awesome” Icons
- 7.6.2 List View: Button rechts ausrichten
- 7.6.3 Button-Abstände
- 7.7 Zusammenfassung
-
8. Fluid Templating
- 8.1 Templates, Layouts und Partials
-
8.2 Ein globales Layout verwenden
- 8.2.1 Mehrfach-Abschnitte (“Sections”)
- 8.2.2 Optionale Abschnitte
-
8.3 Partials
- 8.3.1 Einfache Partials
- 8.3.2 Komplexe Partials
- 8.4 Zusammenfasung
-
9. Query Manager und Repositories
- 9.1 Repository-Klasse
- 9.2 Magische Funktionen
-
9.3 Standard-Struktur einer Abfrage
- 9.3.1 Anmerkung: Debugging
-
9.4 Abfragen anpassen
- 9.4.1 Ergebnismenge konkretisieren
- 9.4.2 Ergebnismenge beeinflussen
- 9.4.3 Logische Verknüpfung
- 9.4.4 Natives SQL
- 9.4.5 Abfrageeinstellungen (Query Settings)
- 9.5 Beispiel: Suche nach einem Schlüsselwort im Titel
- 9.6 Dynamische Suche im Repository
-
9.7 Anmerkung: Das
Request
-Objekt - 9.8 Zusammenfassung
-
10. TypoScript und FlexForm Konfiguration
-
10.1 TypoScript
- 10.1.1 Hauptschlüssel
- 10.1.2 Unterschlüssel
-
10.1.3 Option:
view
-
10.1.4 Option:
persistence
-
10.1.5 Option:
objects
-
10.1.6 Option:
features
-
10.1.7 Option:
mvc
-
10.1.8 Option:
settings
-
10.1.9 Option:
_LOCAL_LANG
-
10.1.10 Option:
_CSS_DEFAULT_STYLE
-
10.2 FlexForms
- 10.2.1 FlexForm Konfiguration
- 10.2.2 Zugriff auf die FlexForm-Konfiguration
- 10.2.3 Zugreifen auf Konfigurationen außerhalb eines Controllers
- 10.2.4 Switchable Controller Actions (SCA)
- 10.3 TypoScript für Backend-Module
- 10.4 Anpassungen für die nächsten Kapitel
- 10.5 Zusammenfassung
-
10.1 TypoScript
-
11. Validierung und Fehlerbehandlung
- 11.1 Der Punkt, an dem die Validierung stattfindet
-
11.2 Fehler anzeigen
- 11.2.1 ViewHelper: Validierungsergebnisse
- 11.3 Übersicht der Validierungsmöglichkeiten
-
11.4 Property-Validierung
- 11.4.1 Eingebaute Validatoren
- 11.4.2 Mehrere Validatoren
- 11.4.3 Eigene Validatoren
- 11.5 Objekt-Validierung (Object Validation)
- 11.6 Action-Validierung (Action Validation)
- 11.7 Validierungen explizit unterbinden
-
11.8 Flash-Messages
- 11.8.1 Flash-Messages generieren
- 11.8.2 Flash-Messages anzeigen
- 11.8.3 Flash-Message-Warteschlangen
- 11.8.4 Flash-Message-Warteschlangen in einem Controller
- 11.8.5 Praktische Übung
- 11.9 Zusammenfassung
-
12. ViewHelper
-
12.1 ViewHelper im Allgemeinen
- 12.1.1 Namespace
- 12.1.2 PHP-Klassendateien
- 12.2 ViewHelper im TYPO3 Core
- 12.3 ViewHelper von der Community
-
12.4 Eigene ViewHelper
- 12.4.1 Text-ViewHelper
- 12.4.2 TagBased-ViewHelper
- 12.4.3 Condition-ViewHelper
- 12.4.4 Widget-ViewHelper
-
12.5 Überprüfe dein Wissen
- 12.5.1 Übung: Der Gravatar ViewHelper
- 12.5.2 Übung: Das A-bis-Z Widget
-
12.6 Die Methoden
renderStatic()
undrender()
- 12.7 Zusammenfassung
-
12.1 ViewHelper im Allgemeinen
-
13. Relationen
- 13.1 Relationen im Domänenmodell
-
13.2 Das “Table Configuration Array” (TCA)
-
13.2.1 TCA:
ctrl
-
13.2.2 TCA:
interface
-
13.2.3 TCA:
types
-
13.2.4 TCA:
palettes
-
13.2.5 TCA:
columns
-
13.2.1 TCA:
-
13.3 Der CRUD Prozess von Blog-Beiträgen (“Posts”)
- 13.3.1 Vorbereitung
- 13.3.2 Beiträge erstellen (“create”)
- 13.3.3 Beiträge lesen (“read”)
- 13.3.4 Beiträge aktualisieren (“update”)
- 13.3.5 Beiträge löschen (“delete”)
-
13.4
m:n
-Relationen (Tags)- 13.4.1 Erstellen von Tags im Backend
- 13.4.2 Tags-Repository
-
13.4.3 Tags im
Post
-Controller auslesen - 13.4.4 Anpassungen von Templates und Partials
- 13.4.5 Tags in der Liste der Beiträge anzeigen
-
13.5
1:1
-Relationen (Autoren)- 13.5.1 Frontend-Benutzer und -Gruppen
-
13.5.2
Author
zufe_users
zuordnen - 13.5.3 Implementierung des Frontend-Teils
- 13.5.4 Automatische Zuweisung des Frontend-Benutzers
- 13.5.5 E-Mail-Adressen verschleiern
-
13.6 Kommentare als AJAX-Anfrage
- 13.6.1 Controller und Action
- 13.6.2 Ajax-Controller
- 13.6.3 Kommentare anzeigen
- 13.6.4 JavaScript
- 13.6.5 Der AJAX-Seitentyp in TypoScript
- 13.7 Zusammenfassung
-
14. Labels und Lokalisierung
- 14.1 Wozu werden Sprachdateien verwendet?
-
14.2 Sprachdateien
- 14.2.1 Platzhalter
- 14.2.2 Variablen
- 14.2.3 Aktualisierung alle Template-Dateien
- 14.3 Labels mittels TypoScript überschreiben
-
14.4 Sprache-Konfiguration
- 14.4.1 Sprache der Website
- 14.4.2 Website-Konfiguration
- 14.4.3 Übersetzungen von Seiten
- 14.4.4 Übersetzung von Inhaltselementen
-
14.5 Lokalisierte Sprachdatei
- 14.5.1 Labels mittels TypoScript überschreiben
- 14.6 Sprach-Labels in PHP
-
14.7 Lokalisierung von Domänenobjekten
- 14.7.1 Das “Table Configuration Array” (TCA)
- 14.7.2 Dateneinträge übersetzen
- 14.8 Zusammenfassung
-
15. Property Mapper und Type Converter
-
15.1 Der Property Mapper
- 15.1.1 Type Converter
- 15.1.2 Property Mapper Konfiguration
-
15.2 Datei-Upload-Funktionalität
- 15.2.1 Sicherheitsaspekte
- 15.2.2 Blog Controller
- 15.2.3 Upload FileReference Converter
- 15.2.4 Blog-Domänenmodell
- 15.2.5 TCA des Blog-Domänenmodells
-
15.2.6
FileReference
Domänenmodell - 15.2.7 TypoScript
- 15.2.8 Partials und Templates
- 15.2.9 FormUpload-ViewHelper
- 15.3 Testen der Datei-Upload-Funktion
- 15.4 Zusammenfassung
-
15.1 Der Property Mapper
-
16. Backend-Module
- 16.1 Anforderungsanalyse und Lösungskonzeption
-
16.2 Basiskomponenten
- 16.2.1 Registration
- 16.2.2 Sprachdatei
- 16.2.3 Abstract Backend Controller
-
16.3 Die erste Funktion: Liste der Kommentare
-
16.3.1 Der
Comment
-Controller - 16.3.2 Fluid-Templates
-
16.3.1 Der
-
16.4 Die zweite Funktion: das Dashboard
- 16.4.1 Modul-Registrierung
- 16.4.2 Erweiterung des Menüs
- 16.4.3 Der Dashboard-Controller
- 16.4.4 Fluid-Templates
- 16.4.5 Darstellung der Statistiken
- 16.4.6 RequireJS
- 16.4.7 AJAX im TYPO3 Backend
- 16.4.8 AJAX-Funktionalität zu JavaScript hinzufügen
- 16.4.9 Feinabstimmung und zusätzliche Hinweise
-
16.5 Die Styleguide Extension
- 16.5.1 Installation
- 16.5.2 Anwendung
- 16.6 Zusammenfassung
-
17. Aufräumen und Projektabschluss
- 17.1 Annotations
- 17.2 Der PSR-2 Coding Standard (“PHP CodeSniffer”)
- 17.3 DocBlocks (“phpDocumentor”)
- 17.4 Dokumentation
- 17.5 Zusammenfassung
-
18. Sicherheitsgrundlagen
- 18.1 Das TYPO3 Security Team
- 18.2 Sicherheit in TYPO3 Extensions
-
18.3 Die häufigste Sicherheitslücken
- 18.3.1 OWASP Top 10
- 18.3.2 Einschleusen von Schadcode
- 18.3.3 Cross-Site Scripting
- 18.3.4 Cross-Site Request Forgery
- 18.3.5 Fehlende Zugriffskontrolle
- 18.4 Weitere typische Sicherheitsrisiken
-
19. Was kommt als nächstes?
- 19.1 Offizielle TYPO3-Zertifizierungen
-
Anhang
- TYPO3 Versionshistorie
- Extension-Konfigurationsdatei
-
Referenzen und weiterführende Literatur
- Inoffizielle Websites
- PHP Sicherheit
- Glossar
- Änderungshistorie
- Anmerkungen
Die bedingungslose Leanpub, Kein Risiko, 100% zufrieden Garantie
Innerhalb von 60 Tagen ab Kauf kannst du dein Geld zu 100% zurückverlangen, bei jedem Leanpub-Kauf, in nur zwei Klicks. Wir bearbeiten die Erstattungen manuell, daher dauert es ein paar Tage, bis der Betrag ankommt.
Lese die kompletten Bedingungen.
80% Royalties. Earn $16 on a $20 book.
We pay 80% royalties. That's not a typo: you earn $16 on a $20 sale. If we sell 5000 non-refunded copies of your book or course for $20, you'll earn $80,000.
(Yes, some authors have already earned much more than that on Leanpub.)
In fact, authors have earned$12,307,240writing, publishing and selling on Leanpub.
Learn more about writing on Leanpub
Free Updates. DRM Free.
If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).
Most Leanpub books are available in PDF (for computers), EPUB (for phones, tablets, and Kindle). The formats that a book includes are shown at the top right corner of this page.
Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.
Learn more about Leanpub's ebook formats and where to read them
Top Books
OpenIntro Statistics
David Diez, Christopher Barr, Mine Cetinkaya-Rundel, and OpenIntroA complete foundation for Statistics, also serving as a foundation for Data Science.
Leanpub revenue supports OpenIntro (US-based nonprofit) so we can provide free desk copies to teachers interested in using OpenIntro Statistics in the classroom and expand the project to support free textbooks in other subjects.
More resources: openintro.org.
Personal Finance
Jason AndersonThis textbook provides an in-depth analysis on personal finance that is both practical and straightforward in its approach. It has been written in such a way that the readers can gain knowledge without getting overwhelmed by the technical terms. Suitable for both beginners and advanced learners.
Getting to Know IntelliJ IDEA
Trisha Gee and Helen ScottIf we treat our IDE as a text editor, we are doing ourselves a disservice. Using a combination of tutorials and a questions-and-answers approach, Getting to Know IntelliJ IDEA will help you find ways to use IntelliJ IDEA that enable you to work comfortably and productively as a professional developer.
C++20 - The Complete Guide
Nicolai M. JosuttisAll new language and library features of C++20 (for those who know previous C++ versions).
The book presents all new language and library features of C++20. Learn how this impacts day-to-day programming, to benefit in practice, to combine new features, and to avoid all new traps.
Buy early, pay less, free updates.
Other books:
Mastering STM32 - Second Edition
Carmine NovielloWith more than 1200 microcontrollers, STM32 is probably the most complete ARM Cortex-M platform on the market. This book aims to be the most complete guide around introducing the reader to this exciting MCU portfolio from ST Microelectronics and its official CubeHAL and STM32CubeIDE development environment.
R Programming for Data Science
Roger D. PengThis book brings the fundamentals of R programming to you, using the same material developed as part of the industry-leading Johns Hopkins Data Science Specialization. The skills taught in this book will lay the foundation for you to begin your journey learning data science. Printed copies of this book are available through Lulu.
Machine Learning Q and AI
Sebastian Raschka, PhDHave you recently completed a machine learning or deep learning course and wondered what to learn next? With 30 questions and answers on key concepts in machine learning and AI, this book provides bite-sized bits of knowledge for your journey to becoming a machine learning expert.
Stats One
William FooteThe Rails 7 Way
Obie Fernandez, Lucas Dohmen, and Tom Henrik AadlandThe Rails™ 7 Way is the comprehensive, authoritative reference guide for professionals delivering production-quality code using modern Ruby on Rails. It illuminates the entire Rails 7 API, its most powerful idioms, design approaches, and libraries. Building on the previous editions, this edition has been heavily refactored and updated.
Gradual Modularization for Ruby and Rails
Stephan HagemannGet yourself a new tool to manage your Rails application and your growing engineering organization! Prevent the ball-of-mud (and fix it!). Go for microservices or SOA if it makes sense not just because you don't have any other tool. Do all this through a low-overhead tool: packages. Enable better conversations to make practical changes today.
Top Bundles
- #1
Software Architecture
2 Books
"Software Architecture for Developers" is a practical and pragmatic guide to modern, lightweight software architecture, specifically aimed at developers. You'll learn:The essence of software architecture.Why the software architecture role should include coding, coaching and collaboration.The things that you really need to think about before... - #2
CCIE Service Provider Ultimate Study Bundle
2 Books
Piotr Jablonski, Lukasz Bromirski, and Nick Russo have joined forces to deliver the only CCIE Service Provider training resource you'll ever need. This bundle contains a detailed and challenging collection of workbook labs, plus an extensively detailed technical reference guide. All of us have earned the CCIE Service Provider certification... - #3
1500 QUIZ COMMENTATI (3 libri)
3 Books
Tre libri dei QUIZ MMG Commentati al prezzo di DUE! I QUIZ dei concorsi ufficiali di Medicina Generale relativi agli anni: 2000-2001-2003-2012-2013-2014-2015-2016-2017-2018-2019-2020-2021 +100 inediti Raccolti in unico bundle per aiutarvi nello studio e nella preparazione al concorso. All'interno di ogni libro i quiz sono stati suddivisi per... - #4
Pattern-Oriented Memory Forensics and Malware Detection
2 Books
This training bundle for security engineers and researchers, malware and memory forensics analysts includes two accelerated training courses for Windows memory dump analysis using WinDbg. It is also useful for technical support and escalation engineers who analyze memory dumps from complex software environments and need to check for possible... - #5
Practical FP in Scala + Functional event-driven architecture
2 Books
Practical FP in Scala (A hands-on approach) & Functional event-driven architecture, aka FEDA, (Powered by Scala 3), together as a bundle! The content of PFP in Scala is a requirement to understand FEDA so why not take advantage of this bundle!? - #6
Modern C++ Collection
3 Books
Get All about Modern C++C++ Standard Library, including C++20Concurrency with Modern C++, including C++20C++20Each book has about 200 complete code examples. Updates are included. When I update one of the books, you immediately get the updated bundle. You can expect significant updates to each new C++ standard (C++23, C++26, .. ) and also... - #7
Linux Administration Complet
4 Books
Ce lot comprend les quatre volumes du Guide Linux Administration :Linux Administration, Volume 1, Administration fondamentale : Guide pratique de préparation aux examens de certification LPIC 1, Linux Essentials, RHCSA et LFCS. Administration fondamentale. Introduction à Linux. Le Shell. Traitement du texte. Arborescence de fichiers. Sécurité... - #9
Development and Deployment of Multiplayer Online Games, Part ARCH. Architecture (Vol. I-III)
3 Books
What's the Big Idea? The idea behind this book is to summarize the body of knowledge that already exists on multiplayer games but is not available in one single place.And quite a fewof the issues discussed within this series (planned as three nine volumes ~300 pages each), while known in the industry, have not been published at all (except for... - #10
Growing Agile: The Complete Coach's Guide
7 Books
Growing Agile: Coach's Guide Series This bundle provides a collection of training and workshop plans for a variety of agile topics. The series is aimed at agile coaches, trainers and ScrumMasters who often find themselves needing to help teams understand agile concepts. Each book in the series provides the plans, slides, handouts and activity...