While you may use HTML and PHP to create our views, Symfony comes with Twig, a very powerful templating engine. Learn how Twig removes logic from the views and also allows you to inherit reusable elements on the view, such as a header or a footer. It also comes with some powerful tools such as filters and also allows us to include other templates.
- [Instructor] One of the most useful assets…about Symphony, and most frameworks for that matter,…is the ability to create a layout.…What do I mean by a layout?…Well, I mean dividing our design regions into files.…For example, header, footer, and main content window.…The idea is to get our views as clean as possible,…and to repeat as little code as we can.…So far, we already had a layout formed out for you,…but in our real life scenario,…we would at some point have to create…our own layout from scratch.…
I went ahead and removed everything…from the layout to create one from scratch.…Let's open our files for this exercise.…The first thing we're going to do…is create two missing routes on…the client's controller.…So, let's open the client's controller,…and add these missing routes.…So to modify, we'll just copy this from the…show index method, paste it on the show details method,…and change the view that we're going to render,…this case form, and let's do the same one…for the one below.…
Author
Released
3/30/2017- Installing Symfony
- Setting up the local environment
- Exploring the Symfony file structure
- Creating routes
- Sending parameters to a controller
- Using views
- Updating routes
- Creating templates with Twig
- Data modeling with Symfony
- Demo application deployment
Skill Level Intermediate
Duration
Views
Related Courses
-
PHP: Clean URLs on Apache Server
with David Powers1h 36m Intermediate -
PHP: Managing Persistent Sessions
with David Powers2h 41m Intermediate -
PHP: Creating Secure Websites
with Kevin Skoglund4h 15m Intermediate
-
Introduction
-
Welcome1m 2s
-
Using the exercise files1m 2s
-
Project overview1m 3s
-
What is Symfony?3m 30s
-
-
1. Get Started with Symfony
-
Install Symfony1m 33s
-
-
2. Controllers in Symfony
-
Create routes5m 52s
-
Use views3m 33s
-
3. Views in Symfony
-
Update routes1m 9s
-
Mock up data4m 17s
-
Use forms, part 13m 23s
-
Use forms, part 22m 49s
-
-
4. Data Modeling with Symfony
-
Introduction to Doctrine3m 32s
-
Structure the database3m 9s
-
Database relationships2m 39s
-
Insert data with Doctrine3m 45s
-
Select data with Doctrine3m 50s
-
Edit entities1m 16s
-
Work with relational data4m 22s
-
Debug the application3m 34s
-
-
5. Taking Symfony Further
-
Composer3m 30s
-
PHPUnit4m 14s
-
Log data2m 25s
-
Demo application deployment4m 17s
-
-
Conclusion
-
Next steps26s
-
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.
CancelTake notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.
Share this video
Embed this video
Video: Update routes