/*
 * vsem <a href="" rel="external"> nastavim target="_blank"
 * tim se dodrzi XHTML 1.0 strict a zaroven umozni otvirani
 * okazu v novym okne
 */
Event.onDOMReady(function() {
	var anchors = $$('a[rel="external"]');
	anchors.each(function(anchor) {
		anchor.target = "_blank";
	});
	var anchors = $$('a[rel="close"]');
	anchors.each(function(anchor) {
		anchor.observe('click', function(e) { window.close(); });
	});

	/*
	var inputs = $$('input');
	inputs.each(function(input) {
		input.observe('keydown', function(e) {
		        if (e.keyCode == 13) {
				input.up('form').submit();
				//return false;
			}
		});
	});
	*/
});

/*
 * funckce pro orez retezcu
 */
String.prototype.trim = function() {
	return this.replace(/^\s+|\s+$/g,'');
}
String.prototype.ltrim = function() {
	return this.replace(/^\s+/,'');
}
String.prototype.rtrim = function() {
	return this.replace(/\s+$/,'');
}

