Courses
/
PHP Fundamentals
/
Your first PHP application
Your first PHP application
Build a complete CLI weather application, combining all learned concepts into a practical project.

Let's put everything we've learned into practice by building a simple command-line weather application. This project will combine many concepts we've covered: Composer, classes, modern PHP features, and working with external APIs.

What We're Building

We'll create a CLI app that shows the current weather for any city. When finished, you can run it like this:

php weather.php Vienna

The project includes:

  • Using Composer for dependency management

  • Working with external packages

  • Creating and using classes

  • Making API requests

  • Modern PHP syntax

This simple app demonstrates how different PHP features work together in a real project. It's a perfect stepping stone before diving into Laravel.

Want to explore the code? Check out the complete project on GitHub:

https://github.com/laravel/php-fundamentals-weather-app