I hereby claim:
- I am ePirat on github.
- I am epirat (https://keybase.io/epirat) on keybase.
- I have a public key whose fingerprint is 66DF 0B23 CE79 3C28 0922 62E1 3EBF 06BE 1FF9 645A
To claim this, I am signing this object:
#!/usr/bin/php | |
<?php | |
if (php_sapi_name() == "cli") { | |
// If this is executed via CLI, parse options and stuff | |
// Helper | |
function report_error($e) { | |
// Get the current script name | |
$our_name = (($v =strrchr(__FILE__, DIRECTORY_SEPARATOR)) == FALSE) | |
? __FILE__ |
I hereby claim:
To claim this, I am signing this object:
When speaking of the Icecast protocol here, actually it's just the HTTP protocol, and this document will explain further how source clients need to send data to Icecast.
Since Icecast version 2.4.0 there is support for the standard HTTP PUT
method.
The mountpoint to which to send the data is specified by the URL path.
<?php | |
function dirtyHeaderParser($headers, $strict = true){ | |
$arr = array(); | |
$s = strtok($headers, ':'); | |
while ($s){ | |
if ( ($s[0] === ' ') || ($s[0] === "\t") ){ | |
if (count($arr) != 0){ | |
$tail = strtok(''); | |
$tail = "{$s}:{$tail}"; |
var PageLinks = function(linkHeader) { | |
var ProfileRel = "https://tent.io/rels/profile"; | |
var final = []; | |
var links = linkHeader.split(","); | |
if (links.length < 2) | |
links[0] = linkHeader; | |
for (link in links) { | |
link = links[link]; | |
var segments = link.split(";"); | |
if (segments.length < 2) |
// ==UserScript== | |
// @name Google News Query Save | |
// @namespace ePirat | |
// @description Fixes that you have to re-enter the search term when you click "News" link | |
// @include http*://google.com/* | |
// @include http*://google.ae/* | |
// @include http*://google.com.af/* | |
// @include http*://google.com.ag/* | |
// @include http*://google.off.ai/* | |
// @include http*://google.am/* |
<?php | |
function PlaceWatermark($file, $text, $xxx, $yyy, $op, $outdir) { | |
require_once('fpdf.php'); | |
require_once('fpdi.php'); | |
$name = uniqid(); | |
$font_size = 5; | |
$ts=explode("\n",$text); | |
$width=0; | |
foreach ($ts as $k=>$string) { | |
$width=max($width,strlen($string)); |
Array.prototype.has = function(value) { | |
var i; | |
for (var i = 0, loopCnt = this.length; i < loopCnt; i++) { | |
if (this == value) { | |
return true; | |
} | |
} | |
return false; | |
}; |
-- by MacScripter User Nigel Garvey | |
on switchText(t, r, s) | |
set d to text item delimiters | |
set text item delimiters to s | |
set t to t's text items | |
set text item delimiters to r | |
tell t to set t to item 1 & ({""} & rest) | |
set text item delimiters to d | |
t | |
end switchText |