DEV Community

Elijah Zobenko
Elijah Zobenko

Posted on • Updated on

PHP-backend Roadmap

There are tons of tools in IT to ease programmers' workflow and make a product more efficient. But in the very beginning of honing PHP that might be such a puzzle to pick the right direction and instruments to learn first. A common solution for such problems now – roadmaps – visual sequences which answer the question "what to learn next?". Subject I'd like to discuss in the article – where to invest your time and efforts to learn PHP faster and become an in-demand backend programmer.

PHP & Git basics

To learn the programming language – just a beginning. And even here it's important to make the right steps. Don't aim to learn and memorize everything about PHP and simply focus on tools you'll be using 90% of the time. And of course, always apply gathered skills in practice.

img1

The next deserving attention thing after learning PHP – Git. You'll probably be using it on a daily basis regardless of your chosen programming language. In a nutshell, Git is a team cooperation tool, which allows you to save states of a code.

Composer and databases

Usage of external libraries is a great solution in most cases. Especially if they earned the community's trust. To use it efficiently you should learn the Composer – a packet manager to extremely ease the process of connecting and updating all your PHP dependencies.

PHP Backend Roadmap (7)

And finally, we got to the databases. There are so many solutions in the market so it's even hard to list and not to forget any. However, there are few leaders of the field, which I personally recommend to pick for your stack. For relational databases it's PostgreSQL, and for NoSQL – MongoDB. PDO will be useful for understanding how all the interaction between PHP and your data happens, and ORMs – will boost the effectiveness and security of that communication.

Working flow optimization

For any programmer, speed is one of the most important factors. And debugging speed affects it directly. There are two main solutions to get rid of seeded echo and var_dump from a code, but my advice is to use the first and more common – xDebug. It's not ever hard to connect and configure it but it will always be bringing benefits.

PHP Backend Roadmap (8)

But the quality of the code and its style may seem subjective things, but teamwork requires it really often. In the PSR-12 standard, you can find the list of recommendations on how to style it. That standard isn't the only existing one, but it's definitely the most common. To simplify following it you can use CodeSniffer. And in order to develop the habit of writing clean code, you can use Psalm, Phan, or PHPStan linters. There's no need to learn each – better to choose the one you like most. In my case it's Psalm.

What about HTML?

Talking about PHP there is less and less mentioning of Full-stack. Fields of work have long been divided and PHP has taken an honorable place at the backend. Therefore learning HTML isn't a requirement for us but rather an optimization. What is really important is to clearly understand how to implement interaction with the front-end. Essential things in this area for us are REST and JSON API. Web-browser might be replaced with Postman – an ultimate tool to debug API. Earning a habit of documenting interfaces using OpenAPI or Blueprint will save you from constant questions from colleagues and give you +10 to karma.

PHP Backend Roadmap (9)

Boosting up the project

The high response rate of the project is due not only to the servers but also to high-quality code. Sometimes to increase it, it's enough to reduce the number of requests to the database or to remember the result of heavy calculations. Caching mechanisms can help us in this. You will find interfaces for organizing them in the PSR-6 and PSR-16 standards. And choose the final caching mechanism depending on the project.

PHP Backend Roadmap (10)

Another common method of speeding up a project is to perform processing in the background. There are two categories of solutions here: task schedulers (Crontab) will be useful for performing mailings, recalculating tariffs, and other regular tasks. And message brokers will allow you to take heavy operations into the background and monitor their execution without slowing down the response to the user.

Testing and frameworks

Not all teams write tests for the code. This decision can be made on the basis of many factors. But understanding how to write the testable code is extremely important. Practicing with PHPUnit will help you gain knowledge in this area. And if you want to try other approaches, pay attention to Codeception.

PHP Backend Roadmap (11)

When a lot of tools have been studied, it's time to combine them into a coherent system. In order not to reinvent the wheel, pay attention to one of the popular frameworks. In them, you will find the best modern practices, as well as get used to high-quality architecture. I suggest making a choice from the two most popular options:

  • Symfony – strict and exacting, used mostly in highly loaded applications.
  • Laravel – the most common and popular today.

Profiling and monitoring

When your project is launched, it is important to monitor its "health". Are the servers coping? Is there a DDoS attack? Is there a fatal exception on the prod? Monitoring is a simple and useful tool that will give you answers to all these questions. You should start with logging. The PSR-3 standard describes the interface, and Monolog will save you from having to write your own logging service. Sentry will help you to be up to date with errors, Grafana will build beautiful graphs, and Graylog or ELK will simplify log search and incident investigation.

PHP Backend Roadmap (12)

However, there are cases that cannot be solved by simple monitoring. For example, if the application is abnormally slow in certain areas. Such incidents are most effectively solved with the help of profiling tools. You will not use them so often, but it is important to remember about their existence.

Of course, the PHP world is not limited to the listed tools and, after mastering them, there is still a lot to learn. But remember: at the beginning of your journey, you should focus on the main and most common things that you will meet in 80-90% of teams. All the listed programs and approaches were chosen according to this criterion. Save the roadmap, and check it in your educational adventure. And finally: success in studying and building a career.

Top comments (14)

Collapse
 
Sloan, the sloth mascot
Comment deleted
Collapse
 
peter279k profile image
peter279k

Thanks for your roadmap! But it seems that roadmap picture is missed and respond the 404 Not Found.

Could you fix that? Thanks.

Collapse
 
he110 profile image
Elijah Zobenko

Thank you for notifying me. My bad. Now should work fine.

Collapse
 
brillantravenasy profile image
Brillantravenasy
Collapse
 
allecosta profile image
Alexandre Costa

Thank you @he110

Collapse
 
wesllycode profile image
wesllycode

Muito obrigado pelo conteudo.
Thank you !

Collapse
 
llbbl profile image
Logan Lindquist

Nice job Elijah

Collapse
 
roadmaps profile image
Roadmaps master

Here is interactive roadmap for PHP developer: infinite.education/skillset/PHP_De...

Collapse
 
beapc profile image
Beatriz Candido

thanks for sharing

Collapse
 
aschwin profile image
Aschwin Wesselius

Thanks Elijah!

If anyone can find a similar one for the .NET framework or very specific for C# I more than happy to get informed about it.

Collapse
 
tahmidrana profile image
Tahmidur Rahman

Why are you suggesting postgres and not mysql? Most of the PHP framework support mysql better than Postgres.

Collapse
 
he110 profile image
Elijah Zobenko

MySQL is great and I personally use it more often than Postgres. It’s also more popular but on the other hand Postgres is more advanced and there are some fields (like banking) are forced to use it. Knowing Postgres will allow you to migrate to MySQL easily, but vice versa it would require an effort. That’s why I suggest it

Collapse
 
paulataylor profile image
PaulaTaylor

How to Become a PHP Developer? Tahajjud For Love Back

Collapse
 
misha_maestro profile image
Misha

Thank you