Amazing PHP
10.1K subscribers
11 photos
84 links
Welcome to the Amazing PHP Channel! Here you can find a lot of interesting articles/news about PHP, frameworks, tools and development.

Support the channel: https://www.paypal.com/donate?hosted_button_id=FAYP5QJH5LVRL
Download Telegram
Software Complexity: Naming
Good writing is hard. But why? Because good writing is about good reading. We tend to focus on the former and forget the latter. We forget that code is written only once, but read many times.
Everything you need (and don't need) to know about PHP's type system
PHP is a dynamically typed scripting language and until the year of 2015 php had no support for statically declared types at all. One could cast to scalar types explicitly in the code, but declaring scalar types in methods and functions signatures wasn't a thing until PHP 7.0 with the Scalar Type Declarations and Return Type Declarations rfcs.
Enhancements to PHP code coverage in 2020
In 2003, with the release of Xdebug 1.2, Derick Rethans introduced the ability to collect code coverage data to the PHP ecosystem for the first time. In 2004, with the release of PHPUnit 2, Sebastian Bergmann made the first real use of this new power by allowing developers to evaluate the effectiveness of their test suites by generating coverage reports.
Clean Code (Robert C. Martin)
Noted software expert Robert C. Martin presents a revolutionary paradigm with "Clean Code: A Handbook of Agile Software Craftsmanship." Martin has teamed up with his colleagues from Object Mentor to distill their best agile practice of cleaning code "on the fly" into a book that will instill within you the values of a software craftsman and make you a better programmer--but only if you work at it.
Modernizing a Legacy PHP Application
Recently, I had the occasion to work on numerous legacy PHP applications. I spotted common anti-patterns that I had to fix. This article is not about rewriting an old PHP application to <insert shiny framework name here>, but about how to make it more maintainable and less of a hassle to work on.
​​Testing Microservices in PHP with Codeception
Not all PHP applications can be developed as a monolith.
An application grows, as well as the engineering team around it, and at some point, in order to keep things consistent, a decision is made to split the application into microservices.
Common Security Mistakes in Laravel Applications (book)
Most of the time security vulnerabilities are only the result of lack of awareness, not negligence. While we find that the majority of developers deeply care about security, sometimes they do not realize how a particular code pattern can lead to a vulnerability, so in the e-book, we decided to share most common security issues that we saw during many years of helping different startups to secure their Laravel applications. With every attack vector, we also will show best practices on how to protect your application from the attack. We hope you find the information useful for you and your dev team.
A decoupled PHP architecture inspired by the Clean Architecture
I feel like I should address that the architecture I’m about to present already existed when I arrived at Arquivei, almost two years ago and didn’t change much since. I didn’t create it, but I did learn a lot from it. Hopefully, you will too.
​​Turbocharged PHP Development with Xdebug, Docker & PHPStorm
A simple recipe for framework decoupling
If you want to write applications that are maintainable in the long run, you have to decouple from your framework, ORM, HTTP client, etc. because your application will outlive all of them.
​​Performance Impact of PHP Exceptions
Exceptions in programming languages provide a way for the application code to raise and handle exceptional situations, and PHP language is not an exception.
Refactoring PHP
Refactoring is the process of modifying and restructuring code without changing its functionality. When I first heard about it, I was like: Why would anyone do that? It took some years until I fully understood the concept and that the working code is not always good. So with refactoring, you can make working code better, and what better means is something developers will argue for hours. In the end, you have to define it for yourself.
​​SOLID in PHP
What is SOLID?
It is a set of principles to have good software design practices compiled by Uncle Bob.
​​Writing better Controllers
Controllers are a very important part of our software. In desktop apps, they coordinate the application, receiving, parsing and storing data, they perform the business logic and bidirectionally communicate with the view. However, when it comes to web applications they are the entrypoint, which means they play a different role than in desktop apps. In this post we’ll look at how writing controllers differently will lead our code to be more flexible, readable and easy to change.
How Static Methods Kill You Like Corona
It's September here, and many of friends walked their children to the school. Some for the first time in their life. Everyone is very cautious because it takes precisely 1 corona-infected child, parent, or teacher to spread to another person very effectively.
Running Laravel on DigitalOcean's App Platform
Today DigitalOcean App Platform entered general availability and they offer support for PHP/Laravel apps out of the box. Read on for a deep dive and explore the pros and cons of DigitalOcean's new app platform with me.
​​Profiling PHP Applications with Xdebug | Rawkode Live
In this episode, joined by Derick Rethans, we take a look at Xdebug and how it help you profile your PHP applications, allowing you to use a profiling front-end, like qcachegrind, to visualise your call graphs and dig into the bottlenecks of your applications.
Clean Code PHP
Software engineering principles, from Robert C. Martin's book Clean Code, adapted for PHP. This is not a style guide. It's a guide to producing readable, reusable, and refactorable software in PHP.

Not every principle herein has to be strictly followed, and even fewer will be universally agreed upon. These are guidelines and nothing more, but they are ones codified over many years of collective experience by the authors of Clean Code.
PHP 8.0.0 Release Candidate 2 available for testing
The PHP team is pleased to announce the ninth testing release of PHP 8.0.0, Release Candidate 2.
Have you heard about Serverspace.us? πŸ€”
Cloud works on innovative hyperconverged vStack platform based on superior Open Source technologies πŸ€“
Lightweight bhyve hypervisor and OS FreeBSD with simplified codebase help build new generation virtual machines.

Features:
πŸ‘Easiest sign-up - only thing that you need is email
🀝 Windows & Linux OS
🦾Based on the latest 2nd Gen Intel Scalable CPUs with 3.1 GHz frequency
⚑️ Fast-speed SSD's with awesome IOPS rate
βŒ›οΈΠ‘reate & Spin up in 40 seconds
πŸ”§24/7/365 Tech Human Support
πŸ“ˆNo fixed plans. Charges every 10 minutes

πŸ’°You can use coupon code: amazing_php and you will get 100% off the first payment.

https://bit.ly/359qAOE