How to fix Symfony HttpClient error Undefined constant "CURL_SSLVERSION_TLSv1_2"

How to fix DataTables Incorrect column count

You may be getting the following DataTables error when trying to initialize a table:

DataTables warning: table id=DataTables_Table_0 - Incorrect column count. For more information about this error, please see http://datatables.net/tn/18

It states that you have an incorrect column count, but that is not always the cause.

Example fixes are described in this post.

How to fix Unexpected item 'parameters › doctrine' in PHPStan doctrine extension

Today while I was configuring PHPStan with the phpstan-doctrine extension I stumbled upon the following error when running PHPStan:

Invalid configuration:
Unexpected item 'parameters › doctrine'.

How to fix Unable to find "Proxies\__CG__\App\Entity\*" entity identifier associated with the UnitOfWork

I was testing a Symfony command today and I got the following unexpected error

08:51:22 CRITICAL  [console] Error thrown while running command "app:* --env=prod". Message: "Unable to find "Proxies\__CG__\App\Entity\*" entity identifier associated with the UnitOfWork" ["exception" => Doctrine\ORM\EntityNotFoundException^ { …},"command" => "app:* --env=prod","message" => "Unable to find "Proxies\__CG__\App\Entity\*" entity identifier associated with the UnitOfWork"]

In EntityNotFoundException.php line 43:

  Unable to find "Proxies\__CG__\App\Entity\*" entity identifier associated with the UnitOfWork

How to inspect element in Chrome that toggles on hover or mouse enter event?

Using the Google Chrome debugger is a great way to quickly adjust some CSS variables before you bake them in your CSS/SCSS etc file.

It works great, and CSS has been less painful since the inception of such tools (I've used FireBug in Mozilla Firefox back in the day). 

But occasionally you may need to adjust elements that show or hide on hover, with CSS :hover, or JavaScript mouseenter/mouseleave, mouseover/mouseout events. This is where the pain begins.

But don't worry, I have a simple solution for you!

How to connect to remote MySQL using SSH tunnel

During local development, you may need to test something against your production or remote databases. There are a couple of things you can do to achieve this.

How to execute multi search msearch query in ElasticSearch with PHP

ElasticSearch gives you the ability to execute multiple queries in a single request by using the Multi-Search API

How to accept gzip with Symfony HTTP Client

Recently, I wrote an HTTP parser using Symfony HTTP client, and I wanted to save some bandwidth because I was using proxies.

One way to save bandwidth is to fetch compressed responses and then decompress them.

HTTP servers and clients use Gzip/deflate or Brotli.

Expose your local server with Cloudflare Tunnels for free

Have you ever needed to expose your local web server to the public Internet? There are a lot of tools out there that will help you do that. Most of them have free versions with limited features and full-featured paid versions.

In this post, I'll demonstrate totally free method to expose your local webserver that is totally free with HTTPS support - Cloudflare Tunnels.

Gitlab fails to pull image from docker repository

Today, when running CI for one of my projects, I got a pipeline error for my master branch. At first, I was a bit nervous because I'd already deployed these changes, but then, when I looked into the error itself, I was relieved, because it was not the tests that failed, but rather the downloading of the docker image.