/* main.js */
$(function(){if($("#submit_btn").length>0)
$("#submit_btn").button();if($("#searchbox").length>0){$("#searchbox").autocomplete({source:"/autocomplete",minLength:3,open:function(event,ui){$("ul.ui-autocomplete").css("z-index",100);},select:function(event,ui){document.location.href=ui.item.url;}});}
if(document.location.href.match(/\?site_id=/)){var line=/site_id=(.*)$/.exec(document.location.href);$('a').each(function(index){var url=$(this).attr("href");if(url){if(!(url.match(/^http/)||url.match(/delete/)||url.match(/edit/)||url.match(/\/categories$/)||url.match(/#/)))
$(this).attr("href",(url+"?site_id="+line[1]));}});}});function setAscending(hiddenElementId,poplistId){debugger;var asc=Ext.get(poplistId);if(asc!=null){Ext.get(hiddenElementId).dom.value=asc.dom.value;}}
