Agenda 2.3: The developers day
Developers learn fastest by building. This day goes from a Git installation to a first extension, touching the parts of Exponential a developer meets in the first week of a project: the content model, templates, overrides, the console and extensions.
At a glance
| Course | Workshops and bootcamps |
| Module | Module 2: One-day agendas |
| Duration | 6 hours of sessions (9:00 to 16:30 with breaks and lunch) |
| Level | Intermediate |
| Audience | PHP developers, 4 to 12 learners |
| Prerequisites | PHP, Git and Composer on each laptop; a GitHub account for the optional last block |
Learning objectives
At the end of the day, learners can:
- set up an installation from Git clones on a branch of their own;
- define a content class and create content with it;
- find which template draws a page and change it with an override they can undo;
- list the console commands and create, enable and see a first extension.
The agenda
| Time | Block | Uses | Checkpoint |
|---|---|---|---|
| 9:00 | Welcome; Git installation (60 min) | Develop with Git, Getting the code, One installation per learner | Site served from a clone on branch training |
| 10:00 | The content model (30 min) | The content model and editing content, Teaching the core concepts | Object, node, version explained |
| 10:30 | Break (15 min) | ||
| 10:45 | A content class "Event" (60 min) | The content model and editing content | An Event created |
| 11:45 | Lunch (45 min) | ||
| 12:30 | Templates, debug and an override (80 min) | Templates and design | Override visible, then removed |
| 13:50 | Break (10 min) | ||
| 14:00 | The console (30 min) | The console install, 7.1 | php bin/php/console list read |
| 14:30 | A first extension with the RAD tools (60 min) | RAD tools, Extensions | Extension counted in Setup > RAD |
| 15:30 | Optional: a documentation fix as a pull request; wrap-up (60 min) | Develop with Git | A pull request link, or a prepared commit |
| 16:30 | End |
Cut items, in order: the pull request block; the console block (fold into the extension block).
Trainer's notes
- The clone is big (the whole history). Prepare clones in advance on slow networks.
- Overrides: use the click path of the Template Editor first, then show the file it wrote
(
settings/siteaccess/<siteaccess>/override.ini.append.php). - Extensions: after enabling, run
php bin/php/ezpgenerateautoloads.php -eand clear the caches, as the RAD tools page says. - After the day, point to the full Developers course and the Extension development book.
Hands-on exercise: the capstone of the day
- Create a content class "Event" with a title, a date and a text.
- Create two events.
- Make an override so that the full view of one event shows an extra line, check it, then remove the override.
- Generate an extension with a RAD wizard, enable it, regenerate the autoloads, clear the caches and see it in the extension point survey.
Expected result
- Two events exist; the override showed and was removed in one click.
- The new extension is listed in Setup > RAD > Extension point survey.
Quiz (end of day)
- Which command lists every console command?
- Where does the Template Editor write an override rule?
- What must you run after enabling a new extension with classes?
- Why work on a branch of your own in the clone?
Answers
php bin/php/console list.settings/siteaccess/<siteaccess>/override.ini.append.php(Templates and design).php bin/php/ezpgenerateautoloads.php -e, then clear the caches (RAD tools).- Updates never overwrite your own commits, and you can send changes back as pull requests.
Further reading
Related pages
- Module 2: One-day agendas
- Workshops and bootcamps: course overview
- Trainers: start here
- Free documentation: this page is free to copy, translate and improve under the GNU FDL 1.3.
Become an Exponential Partner
Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.