View the source of this content.
Let's get the whole "linebreak" thing out of the way. The next paragraph contains two phrases separated by a single newline character:
Roses are red Violets are blue
View the source of this content.
Let's get the whole "linebreak" thing out of the way. The next paragraph contains two phrases separated by a single newline character:
Roses are red Violets are blue
/** | |
* A collection of functions responsible for performing translations between | |
* longitude/latitude coordinates and points on a 1/1 square | |
* (which you could then map to pixelspace) | |
* | |
* @author leebyron | |
*/ | |
/** | |
* lon double x coordinate in radians [-PI,PI) |
/* Scrub a video based on mouseX. */ | |
import processing.video.*; | |
Movie myMovie; | |
void setup() { | |
size(640, 480, P2D); | |
background(0); | |
// Load the video and pause it | |
myMovie = new Movie(this, "station.mov"); | |
myMovie.pause(); |
#301 Redirects for .htaccess | |
#Redirect a single page: | |
Redirect 301 /pagename.php http://www.domain.com/pagename.html | |
#Redirect an entire site: | |
Redirect 301 / http://www.domain.com/ | |
#Redirect an entire site to a sub folder | |
Redirect 301 / http://www.domain.com/subfolder/ |
var uploader = (function(){ | |
var r = Resumable({ | |
target: '/upload/stream', | |
chunkSize: 1*1024*1024, | |
query: { | |
serie_id: {{ $serie->id }} | |
} | |
}), |
Default set up for git deploy web-server on debian box [for a laravel site but also pretty generic]
There a good guide (for ubuntu) here
apt-get update && apt-get upgrade
angular.module('my.cordova.plugins', ['ionic']) | |
// for media plugin : http://plugins.cordova.io/#/package/org.apache.cordova.media | |
.factory('MediaSrv', function($q, $ionicPlatform, $window){ | |
var service = { | |
loadMedia: loadMedia, | |
getStatusMessage: getStatusMessage, | |
getErrorMessage: getErrorMessage | |
}; |
#!/usr/bin/php | |
<?php | |
$files = shell_exec('git diff-index --name-only --cached --diff-filter=ACMR HEAD | grep "\.php$"'); | |
$files = explode("\n", trim($files)); | |
$exitCode = 0; | |
foreach ($files as $file) { | |
if (empty($file)) { |
<?php | |
function convert($size) | |
{ | |
$unit=array('b','kb','mb','gb','tb','pb'); | |
return @round($size/pow(1024,($i=floor(log($size,1024)))),2).' '.$unit[$i]; | |
} | |
convert(memory_get_usage()); |