function chgPage(page)
{
	$('page').value = page;
	$('filter').submit();
}
String.prototype.trim=function()  
{
    return this.replace(/(^\s*)|(\s*$)/g, "");  
}
function addOption(selectId, txt, val)
{
    $(selectId).options.add(new Option(txt, val));
}
function removeOptions(selectId)
{
	for (i=$(selectId).options.length-1; i>=0; i--) {
		$(selectId).options.remove(i);
	}
}
function addOptions(selectId, opts)
{
	for(var v in opts){
		$(selectId).options.add(new Option(opts[v], v));
	}
}
function addBookmark(){
	var _title=document.title;
	var _url=document.location.href;
	if (window.sidebar) {
		window.sidebar.addPanel(_title, _url,"");
	} else if( document.all ) {
		window.external.AddFavorite( _url, _title);
	} else if( window.opera && window.print ) {
		return true;
	}
}