Skip to content

Instantly share code, notes, and snippets.

@MustafaMagdi
MustafaMagdi / Container.php
Last active October 20, 2025 10:11 — forked from tlikai/container.php
PHP Dependency Injection Container
<?php
/**
* Class Container
*/
class Container
{
/**
* @var array
*/
@manuelselbach
manuelselbach / README.md
Last active September 17, 2025 19:32
xdebug docker on macOS with PhpStorm

Use xdebug with docker on macOS and PhpStorm

To use xdebug with macOS and docker is quite, let´s call it tricky ;)

The following steps need to be proceed to get it working:

  1. use the config from the xdebug.ini wihtin your docker web container. Important: set remote_connect_back to off

UPDATE

@tralves
tralves / TestCase.php
Created July 7, 2016 22:10
Laravel Storage mock test helper
<?php
use Illuminate\Support\Facades\Config;
class TestCase extends Laravel\Lumen\Testing\TestCase
{
/**
* Create a mock of a Storage disk.
*
* Usage:
@chadrien
chadrien / README.md
Last active August 24, 2025 21:28
Debug PHP in Docker with PHPStorm and Xdebug

Debug your PHP in Docker with Intellij/PHPStorm and Xdebug

  1. For your local dev, create a Dockerfile that is based on your production image and simply install xdebug into it. Exemple:
FROM php:5

RUN yes | pecl install xdebug \
&amp;&amp; echo "zend_extension=$(find /usr/local/lib/php/extensions/ -name xdebug.so)" &gt; /usr/local/etc/php/conf.d/xdebug.ini \
@bellbind
bellbind / app.html
Created May 20, 2015 07:23
[electron]Use electron as a Web Server
<!doctype html>
<html><head><script src="app.js"></script></head><body></body></html>