I hereby claim:
- I am lukechapman on github.
- I am lukechapman (https://keybase.io/lukechapman) on keybase.
- I have a public key ASDPSCT_sSU8DuDd1vP2ye5_PiupGDTDP8YjZ0pWqYXDjAo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
// urlize | |
// updated as per suggestion by Xeoncross (https://gist.github.com/Xeoncross) | |
function urlize($url){ | |
if (strpos($url,'//') === false) $url = 'http://'.$url; | |
return $url; | |
} | |
// e.g | |
$my_url = 'www.google.com'; |
function permify(str){ | |
return str.replace(/[^a-zA-Z 0-9]+/g,'').replace(/\s+/g, '-').toLowerCase(); | |
// e.g permify("This is an awesome place! (Really awesome!)"); | |
// returns "this-is-an-awesome-place-really-awesome" | |
} |