/*
Autor: Cruz Rosales
Fecha: 20080505-1140
Contacto: crosalesc@gmail.com
~by__ _  __  |^|_  __  _ __ _ __  _   _ _ __   __
 / _ ` | _  \  __| _  \ '__| '_  \ | | | '_  \´  \
| (_)  | __ /  |_| ___/ |  | | | | |_| | | | | | |
 \ __,_|\___|\___|\___|_|  |_| |_|\___/|_| |_| |_|crc<>
*/
Event.observe(document, 'dom:loaded', function() {
	var a = $$('#marcadores td a');
	if ('number' == typeof(a.length) && 0 < a.length) {
		for (var i = 0; i < a.length; i++) {
			switch (a[i].href) {
				case 'http://del.icio.us/':
					a[i].href = a[i].href + 'post?url=' + encodeURIComponent(document.location) + '&title=' + document.title;
					break;
				case 'http://digg.com/':
					a[i].href = a[i].href + 'submit?phase=2&url=' + encodeURIComponent(document.location) + '&title=' + document.title;
					break;
				case 'http://www.facebook.com/':
					a[i].href = a[i].href + 'sharer.php?u=' + encodeURIComponent(document.location) + '&t=' + document.title;
					break;
				case 'http://reddit.com/':
					a[i].href = a[i].href + 'submit?url=' + encodeURIComponent(document.location) + '&title=' + document.title;
					break;
				default:
			}
		}
	}
});
