Skip to content

Instantly share code, notes, and snippets.

View mauriciofierrom's full-sized avatar
💻
Bit by bit

Mauricio Fierro mauriciofierrom

💻
Bit by bit
View GitHub Profile
@mauriciofierrom
mauriciofierrom / vote.rb
Created August 14, 2012 11:32
This little code logs in to Wowlatinoamerica's web site and then votes on every page automatically. It also checks for an internet connection 20 times before shutting down because I set it to run on boot in my machine.
require 'rubygems'
require 'mechanize'
require 'open-uri'
def internet_connection?
begin
true if open("http://www.google.com")
rescue
false
end
@mauriciofierrom
mauriciofierrom / class.wp-publication-archive.php
Created August 22, 2012 01:56
Plugin Wordpress Publication Archive Españolizado
<?php
class WP_Publication_Archive {
public static $mimetypes = array(
'application/pdf' => 'pdf',
'application/postscript' => 'pdf',
'application/zip' => 'zip',
'audio/basic' => 'audio',
'audio/mp4' => 'audio',