	function rhcatalog_callback(data){
		//alert ('hello from rhcatalog_callback');
		getByID('content').innerHTML = data.content;
		getByID('pager').innerHTML = data.pager;
	}
	function getByID(ID){
		if (document.getElementById){
			return document.getElementById(ID);
		}
		else if ((document.all) && (eval ('document.all.' + ID))){
			return eval ('document.all.' + ID);
		}
	}
	function pagerCallback(page, a){
		//alert ('pager callback called');
		a.target = 'json_frame';

		var old_path = a.pathname;
		a.pathname += 'search_core.php';
		if (old_path == a.pathname){
			//alert ('safari bug detected');

			a.href = a.pathname + 'search_core.php' + a.search
			//alert ('new a.href is ' + a.href);

		}
	}
	
	
//-----------------------------------------------------------------------------------------------------------
// tab click code



	
	
	//-----------------------------------------------------------------------------------------------------------
// other format button click code
	
	$(".other_formats li:has(a)").click(function() {
		window.location = $("a:first",this).attr("href");
	});

	
//-----------------------------------------------------------------------------------------------------------
// add the drop down on all search boxes
function addtachEvent(evt, daFunction, obj){
    (obj) || (obj = window);
    if (window.addEventListener){
        obj.addEventListener(evt, daFunction, false);
    }
    else if (window.attachEvent){
        obj.attachEvent( "on" + evt, daFunction);
    }
}
function get_suggest(){
   var head= document.getElementsByTagName('head')[0];
   var script= document.createElement('script');
   script.type= 'text/javascript';
   script.src= '/cgi-bin/suggest/searchsuggest.js';
   head.appendChild(script);
}
function ss_find_fields_callback(){
	var fields = document.getElementsByName("title_subtitle_auth")
	return fields;
}
get_suggest();



