AI makes generating code easier. Making sure it works as expected, that’s where testing comes in. Join Diego's workshop "TDD the Right Way" at SymfonyCon Warsaw next month and put that code to the test! 🚀 Join the workshop → live.symfony.com/2026-warsaw-...
SymfonyCasts
SymfonyCasts
@symfonycasts.com
Injecting Unicorns and Rainbows back into learning PHP // The official way to learn Symfony: http://SymfonyCasts.com
739 followers5 following337 posts
Rewind ⏪ Cosmic Coding with Symfony #20 Final Symfony intro video!!! We'll celebrate with MakerBundle & learn about all the things we can generate with a single command. symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #12 Want stronger passwords - and a way to reject any that have already leaked in a data breach? Symfony ships a constraint for each, and we'll bundle them into one reusable constraint of our own! symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #11 Need a change password form? Let's reuse the one the reset password maker already wrote for us, then ask for the current password too - with a very cool built-in constraint! symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #19 I want our Symfony app to be *incredible*. And so, we're going to use Turbo and instantly transform it into a single page app (SPA) experience. This is one of our most impactful 5 minute videos! symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #10 Need a forgot password flow? There's a maker for that! Let's generate the whole thing, log the user in automatically after a reset, and see how it avoids leaking who has an account! symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #18 We're going to make our new Symfony app much more awesome by introducing my absolute favorite JavaScript tool: Stimulus. With about 10 lines of code, we'll have an animated, closeable sidebar that *always* works. symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #17 We're well on our way to building a beautiful Symfony app and today, we finish making the design dynamic! But we're also writing code that's clean & understandable. And we'll add "smart model methods" towards this goal. symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #9 Let's swap the built-in switch_user role for a custom attribute, let a voter make the call, & see how to check the permissions of any user - not just the one logged in. And, now our admins can't impersonate each other! symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #16 Let's tighten up our growing Symfony app with an enum to track starship repair status! Enums are almost as much fun as space tutorials 🛸 symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #8 Let's give users the choice to log in with their email or username! We'll add unique usernames, update our login form, and teach Symfony how to find users by either one. symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #15 Short but sweet! In 2.5 minutes, we'll organize Twig code into a template partial and start breathing dynamic life into our design with a Twig for loop! symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #7 After logging in, users should return to the page they were on, not the homepage! Let's use Symfony's _target_path to send them right back where they left off, making the login experience a little smoother! symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #14 Our new Symfony site deserves to look *great*. Let's hook that up with Tailwind CSS courtesy of the excellent bundle from those nice folks over at Symfonycasts 😊. I *love* how much fun this is! symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #6 Need a super admin who can do (almost) anything? Let's build a custom voter that grants sweeping permissions across our app, while making sure important authentication checks still behave normally! symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #5 Ever notice how GitHub asks you to confirm your password before sensitive actions? Let's build that same "sudo mode" in Symfony, requiring full authentication with a smooth password confirmation flow! symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #13 We get to try out one of my *favorite* parts! Asset Mapper is *the* tool for building a modern CSS & JS frontend without the fuss of a build system. It's time to make our site shine! symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #12 We're making all sorts of pages in our new Symfony app. So for part 12, let's start linking them together! The secret is that every route already has an internal name and we can use it to generate URLs. symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #11 We can fine-tune the routes in our Symfony app in tons of cool ways: route {wildcards}, requirements, HTTP methods, etc! We'll use this to create another API endpoint and continue building our app with clean architecture. symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #4 Wrong password, unknown email, disabled account... your login form answers all three with "Invalid credentials." That's deliberate. Let's decide how much we actually want to give away. symfonycasts.com/screencast/s...
Symfony Cache Contracts have a sneaky little trick 👀 Use `beta: INF` to force-refresh a cached value without deleting the old one first - so other requests can keep using it while the fresh value is computed. See how it works 👇 symfonycasts.com/blog/symfony...
🔐 Symfony Security: Going Further #3 Disabling an account blocks the next login... but a user already browsing doesn't even notice. Let's show them the door mid-click. 👋 symfonycasts.com/screencast/s...
🔐 Symfony Security: Going Further #2 Deleting a user is forever. Sometimes you just want to switch them off. Let's teach our login to check more than the password. symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #10 Symfony lives & dies by service - which are tools! It's packed full of them. But we can - & will - constantly create our *own* services! Let's do that to centralize our code & learn more about how autowiring *really* works. symfonycasts.com/screencast/s...
🚀 New on the blog: our ideal GitHub Actions setup for Symfony apps! Tests, linting, PHPStan, code style, database/schema checks, Symfony-aware diagnostics, asset compilation, plus a scheduled Composer security audit. A solid CI baseline you can actually build from: symfonycasts.com/blog/ideal-g...
🚨 New Course 🚨 🔐 Symfony Security: Going Further #1 A 403 status code tells us we don't have access... but it also tells us the thing exists. Let's borrow the trick GitHub uses on private repositories 🖖 symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #9 Big chapter about... services! These are the backbone of everything in Symfony. We'll talk about the container, autowiring and where services come from. symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #8 How easy is it to create a JSON endpoint in Symfony? Let's find out! Then, we'll create a "model" class to organize our data and find out how Symfony's serializer system can even turn objects into JSON. symfonycasts.com/screencast/s...
Symfony has a great login feature: Visit a protected page → log in → automatically return to the page you wanted. Unless Turbo has other plans... 😅 Here's what happened - and the fix. youtu.be/2oBFtu1cN2c
Rewind ⏪ Cosmic Coding with Symfony #7 Symfony has some of THE best debugging tools of all the internet. With one command, let's pop the web debug toolbar and profiler into existence in our app! symfonycasts.com/screencast/s...
End-to-end tests with JS but no web server?! 🎭 Playwright-PHP + Symfony hands the request straight to your Symfony kernel - so you get container access, PHP exception catching, DAMA rollbacks and ParaTest. From a real browser. 🤯 symfonycasts.com/blog/playwri...
Rewind ⏪ Cosmic Coding with Symfony #6 Twig's template inheritance works exactly like OO inheritance (It was once implemented behind the scenes as OO inheritance!), we break our base template into as many parts as we want, then override those from the child. symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #5 I absolutely ❤️ Twig.We get to know the 3 Twig syntaxes, filters & more. Oh, and packs! Unrelated to Twig, packs are a way to install multiple packages at once to get everything you need for a robust setup. symfonycasts.com/screencast/s...
🔐 Symfony Security Basics #19 Let's finish by building a complete user registration flow! We'll generate the registration form, add validation, save our new user, log them in automatically, and finish with a discussion about user enumeration. symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #4 Fun fact: Symfony projects start as a *single* file: composer.json! So then where do the other files come from? Say hello to Symfony's unique recipes systems. We'll install PHP CS Fixer, skip configuration & use it immediately. symfonycasts.com/screencast/s...
🔐 Symfony Security Basics #18 Symfony dispatches events throughout the security process. Let's explore some of the most useful ones, then put one to work tracking each user's last login! symfonycasts.com/screencast/s...
Rewind ⏪ Cosmic Coding with Symfony #3 6 minutes: that's all we need to explain the first half of Symfony: route -> controller -> response. The song of the web! symfonycasts.com/screencast/s...
End-to-end tests with JS but no web server?! 🎭 Playwright-PHP + Symfony hands the request straight to your Symfony kernel - so you get container access, PHP exception catching, DAMA rollbacks and ParaTest. From a real browser. 🤯 symfonycasts.com/blog/playwri...
🔐 Symfony Security Basics #17 Let's protect our login form from brute-force attacks! We'll enable Symfony's login throttling, see what happens when we trip the limiter, then dig into its configuration and how it works. Delightful nerdery!
🔐 Symfony Security Basics #16 User impersonation is super useful... until you forget you're impersonating someone! Let's make it painfully obvious when we're switched to another user and add an easy way to exit.
Rewind ⏪ Cosmic Coding with Symfony #2 A new Symfony project is... only about 15 files 🤯! Let's get to know our tiny new app, meet the only 2 directories we care about & get PhpStorm set up & ready for coding. symfonycasts.com/screencast/s...
🔐 Symfony Security Basics #15 Need to debug a problem from a user's perspective? Let's enable Symfony's user impersonation feature so admins can temporarily switch to another user without ever knowing their password.
Rewind ⏪ Cosmic Coding with Symfony #1 Cosmic Coding with Symfony (fully compatible with Symfony 8). Let’s build something beautiful, modern & love the process! symfonycasts.com/screencast/s...
🔐 Symfony Security Basics #14 Hiding an action a user can't access is good UX, but it's not security! Let's enforce our voter permissions in the controller, then give admins the power to bypass them.
Doctrine lazy objects used to rely on generated proxy classes that extended your entities. PHP 8.4 makes them native. Same lazy-loading magic - fewer workarounds - and your entities can finally be "final". 🎉 See how lazy objects work 👉 youtu.be/X0HhrOnkGlc
🔐 Symfony Security Basics #13 Roles are great, but sometimes permissions need to be more precise. Let's create a custom voter to decide whether the current user can edit or delete a specific object.
Rewind ⏪ Doctrine Queries #16 We're wrapping up the update to our Doctrine Queries tutorial with a more complex GROUP BY query. We select objects *and* extra data all at once... to reduce our page queries down to 1! symfonycasts.com/screencast/d...
Rewind ⏪ Doctrine Queries #15 Ever run into an SQL function that Doctrine didn't support - like MySQL's RAND? Those may not work out-of-the-box (and b/c of a good reason), but they're easy to use thanks to the beberlei/DoctrineExtensions library! symfonycasts.com/screencast/d...
One of Symfony's * coolest * security features: 1) Users log in 2) Symfony checks their password hash. 3) Old algorithm? Rehash and save automatically 🔐 Automatic security upgrades over time! youtu.be/Bu8ZDbXAsq8
Rewind ⏪ Doctrine Queries #14 Using the WHERE IN () with Doctrine: super easy... once you see the right syntax (hint: the correct way is easier than normal SQL!) symfonycasts.com/screencast/d...