This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//TODO get URL from parameters and authenticate it with an expiring hash/timestamp | |
$url = 'http://traffic.libsyn.com/atpfm/atp95.mp3'; | |
// Forward these headers from original request | |
$requestHeaders = []; | |
if (isset($_SERVER['HTTP_USER_AGENT'])) $requestHeaders[] = 'User-Agent: ' . $_SERVER['HTTP_USER_AGENT']; | |
if (isset($_SERVER['HTTP_RANGE'])) $requestHeaders[] = 'Range: ' . $_SERVER['HTTP_RANGE']; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Fergus Staging Deploy Script | |
# Update git to staging | |
cd /var/www/fergus_internal_demo; | |
#!/bin/bash | |
function bgtext { | |
echo -e $(tput setab 24)" $1"$(tput sgr0); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public static function group_by(Array $objects, $group_by_property) | |
{ | |
$grouped_objects = []; | |
foreach($objects as $object) | |
{ | |
$property_value = $object->{$group_by_property}; | |