Query Syntax => http://srt.bz/u/http://www.google.ca/search?hl=en&q=site:byrev.org
Query Result => URL:=http://srt.bz/41y
<?php
#~~~~~~ PHP function that converts a long url into short one using http://srt.bz
function srtbz($longurl) {
$longurl = 'http://srt.bz/u/'.$longurl;
$srtbz = file_get_contents($longurl);
if (preg_match('#URL:=(.*?)$#',$srtbz,$match)) { return $match[1]; }
}
#~~~~~~ Example of use of the above functions
$long_url = 'http://www.google.ca/search?hl=en&q=site:byrev.org';
if($short_url = srtbz($long_url)) {
echo $short_url;
} else {
echo 'flood';
}
?>
Anonymous users can shorten up to 1 link, at an interval of 3 seconds. Users, IPs or domains who use spam or illegal links will be banned!