// Depop: zephyrfalcon
// version 0.1
// 28 May 2005
// Copyright (c) 2005, Adam Vandenberg
// Released under the GPL license
// http://www.gnu.org/copyleft/gpl.html
//
// --------------------------------------------------------------------
//
// This is a Greasemonkey user script.
//
// To install, you need Greasemonkey: http://greasemonkey.mozdev.org/
// Then restart Firefox and revisit this script.
//
// Under Tools, there will be a new menu item to "Install User Script".
// Accept the default configuration and install.
//
// To uninstall, go to Tools/Manage User Scripts,
// select "Depop: zephyrfalcon", and click Uninstall.
//
// ==UserScript==
// @name		Depop: zephyrfalcon
// @namespace	http://adamv.com/greases/
// @description 	Removes pop-up from Zephr Falcon / Efectos Especiales
// @include	http://zephyrfalcon.org/weblog2/*
// ==/UserScript==

(function(){
	var pattern = /javascript\:HaloScan\(\'(\d+)/;

	var links = document.getElementsByTagName("a")
	for (var i=0; i < links.length; i++){
		var link = links[i];
		var match = link.href.match(pattern);
		if (match){
			link.href = "http://www.haloscan.com/comments/zephyrfalcon/" + match[1] + "/";
			delete link.target;
		}
	}
})();
