Skip to content

Instantly share code, notes, and snippets.

View pawtwa's full-sized avatar

Paweł Twardziak pawtwa

View GitHub Profile
@pawtwa
pawtwa / slim-4.php
Last active May 23, 2021 15:55 — forked from codler/gist:3906826
Support HTTP Header Range, mp4, php.php/mp4.mp4
<?php
# Nginx don't have PATH_INFO
if (!isset($_SERVER['PATH_INFO'])) {
$_SERVER['PATH_INFO'] = substr($_SERVER["ORIG_SCRIPT_FILENAME"], strlen($_SERVER["SCRIPT_FILENAME"]));
}
$request = substr($_SERVER['PATH_INFO'], 1);
$file = $request;
$fp = @fopen($file, 'rb');
@pawtwa
pawtwa / angular-7-deploy-gh-pages.json
Created March 4, 2019 20:02
Angular 7 Deploy with GH-PAGES
{
"scripts": {
"deploy": "ng build --base-href=\"/repo-name/\" && gh-pages -d dist/proj-name"
}
}