This file contains 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
/* | |
Title: Vanilla JavaScript to fix responsive SVGs in some versions of Safari. | |
What it does: Stops the problem I described here: http://stackoverflow.com/q/17158717/1147859 Reference URL of the issue: http://codepen.io/benfrain/full/fhyrD | |
It will work on all SVGs referenced inside objects as long as given the class .emb: | |
<object class="emb" data="img/cup.svg" type="image/svg+xml"></object> | |
And also any inline SVGs. |
This file contains 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/sh | |
# Output file for HTML5 video | |
# Requirements: ffmpeg .6+ with libvorbis, theora and libvpx | |
# ( Install via brew with `brew install ffmpeg --with-libvorbis --with-libvpx --with-theora` ) | |
# Usage: `./html5video.sh infile.mp4` | |
# Optional parameters: | |
# `./html5video.sh infile.mp4 -y` to force overwriting existing videos | |
# `./html5video.sh infile.mp4 -n 640x480` to force an output size |
This file contains 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 | |
function north_cast_api_data($content) { | |
if (is_numeric($content)) $content = intval($content); | |
else { | |
$unserialized_content = @unserialize($content); | |
// we got serialized content | |
if ($unserialized_content !== false) { | |
// make sure that integers are represented as such, instead of str | |
foreach ($unserialized_content as $fn => &$c) { |