Skip to content
Hunter edited this page Aug 23, 2021 · 2 revisions

docker

docker pull webdevops/php-nginx

sudo docker run -d \
    --restart unless-stopped \
    --name postgres \
    -p 8880:80 \
    -v /data/phpapp:/app \
    webdevops/php-nginx

bcmath

bcdiv('1278478171634955306', pow(10, 18), 8);   // token balance to string

locale

setlocale(LC_ALL, "UTF8", "zh_TW.UTF-8");

force ipv4

$opts = ['socket' => ['bindto' => '0:0']];
$context = stream_context_create($opts);
$file = file_get_contents('http://this-website-supports-ipv4-only.com', false, $context);
Clone this wiki locally