Skip to content

Instantly share code, notes, and snippets.

View bradhe's full-sized avatar
👋
looking for friendship

Brad Heller bradhe

👋
looking for friendship
  • Berlin
View GitHub Profile
@bradhe
bradhe / reddit.com.js
Created April 2, 2012 07:28 — forked from built/reddit.com.js
An improvement for the Reddit killer
$(function() {
$('body').empty();
document.title = "REDDIT IS A WASTE OF TIME";
});
require 'uri/http'
# Blatently stolen from http://www.simonecarletti.com/blog/2009/04/validating-the-format-of-an-url-with-rails/
#
# Validates whether the value of the specified attribute matches the format of an URL,
# as defined by RFC 2396. See URI#parse for more information on URI decompositon and parsing.
#
# This method doesn't validate the existence of the domain, nor it validates the domain itself.
#
# Allowed values include http://foo.bar, http://www.foo.bar and even http://foo.