Blog

Being confronted with the need to write tests during a project comes out of nowhere sometimes The beginning of a project starts fast, goes fast and slows down after a while because the code base grows bigger. Classes seem to be harder to read and the framework you usually love is trying to make you mad for being inflexible. Thats totally normal, because it becomes more complex is what you might think...
The journey to the PHP Developer Days in Dresden actually started in 2017 for me, when Holger Woltersdorf, one of the PHPDD organizers, asked me if our German Podcast PHPDevRadio wants to participate at the coming PHPDD in 2018. After I contacted the initiator of the podcast about the invitation, it became part of the conferences side events and led to an awesome and worthwhile time for myself. But what makes this...
Sooner or later you have no choice to use them in your code. It doesnt matter if it is PHP, Javascript, Go, C, Java or any other language, there will be one day where you have to check or manipulate a string that has such a complexity, that you would need a lot of ifelse blocks to cover a use case. This will be the point where you have to...
When PHP 7 was released at the end of 2015, it had a huge impact on the community. It came out with one of the most anticipated features we were waiting for scalar type hints. As if this wasnt big enough, return types were also added to this new major version and the possibility to make PHP handle these types even in a strict mode, similar to other typed languages. Even for...
It happened again at a conference While I looked at all the booths of the large amount of participating companies, many of them showed interest in hiring developers. How did they do it? By showing what kind of freetime activity they do as a company. At one booth, there was even a wall with lots of photos and postits containing hashtags like fun, team, soccer,...
It was October 28th, when a lot of mighty developers took their ideas and notebooks on a journey to Mannheim Germany to meet each other on a glorious PHP conference and share their stories of honour. Okay, while the date and the destination is correct, it wasnt an adventurous quest of heroes like in the old ages, but nevertheless the unkonf in 2017 was once again an event you would regret not...
Yes, another blog about Dependency Injection and how to put A as a dependency into B. Its so easy with the help of frameworks and DI containers to build a class structure and let them be automagically instantiated in your projects, so why creating another one? Because dependency doesnt end after the injection. What is Dependency Injection? There will be always a new generation of developers, so we have to cover...
This year, I wanted to participate as a speaker at an event and did send in my first CfP for the PHP track at FrOSCon. Because I wanted to visit this years FrOSCon during my vacation time anyway, this was a good chance to learn new things, improve myself as a speaker and share some of my knowledge with others. In the end, I got accepted and my journey to Bonn was...
Projects are growing over the years, code complexity can rise and the amount of classes in a OOP code base become more structured. For all the changes that happen in projects, developers are gladly using a Version Control System to track all the changes that are happening. Many of the open source projects are using Git and its advantages for their code, but I guess that this isnt any big news for you...
When it comes to ORMs in PHP, Doctrine is one of the most common libraries and for many developers the first choice for their projects. A Symfony Framework standard installation already has Doctrine as a dependency by default and it can be easily added to other frameworks like Laravel or Zend. While working with a simple CRUD, a developer doesnt even have to think about which database is actually behind the ORM, but...
Finding the right index to a SQL query is not only important for performance improvements, it is also relevant to reduce the memory on disc for every created index of every table of the projects databases. Sometimes there are multiple indices on one table, that can be covered with only one smart index, which can improve INSERTS too. The right index is a guarantee for fast reads without slowing down writes too much...
A new PHP project for a web application starts with some simple dependencies a webserver, maybe a database and of course PHP. For that, we need a good workstation, Apache or Nginx and as a database like usually MySQL. Surely some choose MariaDB or PostgreSQL, others a non relational database like MongoDB. Most of us started with LAMP or WAMP for the first time and switched later to a development...
When it comes to test doubles in unit tests, mock objects are the common way to replace a dependency in a tested unit. Most of us started to test PHP code with the testing framework PHPUnit that is shipped with its own mocking library. Even though it already offers a lot of possibilities to replace dependencies in unit tests, many other new innovative mocking libraries were released over the last years offering more...