Skip to content

Instantly share code, notes, and snippets.

# CORS
Header always set Access-Control-Allow-Origin "*"
Header always set Access-Control-Allow-Headers "Content-Type, Authorization"
Header always set Access-Control-Request-Methods "POST, GET, OPTIONS"
@wonzbak
wonzbak / timeIt.php
Last active January 13, 2020 10:16
Get time elapse of a function
<?php
function timeIt(
callable $callable,
array $params = [],
int $maxLoop = 1000,
bool $returnValue = false
) {
$start = microtime(true);
<?php
declare(strict_types=1);
namespace Deezer\Legacy\Test\ActivationJourney;
use Prophecy\Prophet;
class MockHelper
{
@wonzbak
wonzbak / config.txt
Created October 16, 2021 15:36
Raspberry pi Config for WIMAXIT 7 hdmi screen
# Config for WIMAXIT 7
hdmi_force_edit_audio=1
max_usb_current=1
hdmi_force_hotplug=1
config_hdmi_boost=7
hdmi_group=2
hdmi_mode=87
hdmi_drive=2
display_rotate=0
hdmi_cvt 1024 600 60 6 0 0 0