function loadResult(c,a,d,b){$(document).ready(function(){if(b){var e=PMA_ajaxShowMessage();$("#sqlqueryform").hide();$("#togglequerybox").hide();$("#table-info").show();$("#table-link").attr({href:"sql.php?"+d}).text(a);var f=c+" #sqlqueryresults";$("#browse-results").load(f,null,function(){$("html, body").animate({scrollTop:$("#browse-results").offset().top},1E3);PMA_ajaxRemoveMessage(e);window.parent.table=$("#table-link").text().trim();PMA_makegrid($("#table_results")[0],true,true,true,true)}).show()}else event.preventDefault()})}
function deleteResult(c,a,d){$(document).ready(function(){$("#table-info").hide();$("#browse-results").hide();$("#sqlqueryform").hide();$("#togglequerybox").hide();if(confirm(a))if(d){var b=PMA_ajaxShowMessage(PMA_messages.strDeleting,false);$("#sqlqueryform").html("");var e=c+" #result_query, #sqlqueryform";$("#browse-results").load(e,function(){document.getElementById("buttonGo").click();$("#togglequerybox").html(PMA_messages.strHideQueryBox);PMA_ajaxRemoveMessage(b);$("#browse-results").show();
$("#sqlqueryform").show();$("#togglequerybox").show()})}else event.preventDefault()})}
$(document).ready(function(){var c=PMA_getImage("s_tbl.png","",{id:"table-image"}).toString();$("#table-info").prepend(c).hide();$("#buttonGo").click(function(){$("#table-info").hide();$("#browse-results").hide();$("#sqlqueryform").hide();$("#togglequerybox").hide()});$('<div id="togglesearchresultsdiv"><a id="togglesearchresultlink"></a></div>').insertAfter("#searchresults").hide();$('<br class="clearfloat" />').insertAfter("#togglesearchresultsdiv").show();$("#togglesearchresultlink").html(PMA_messages.strHideSearchResults).bind("click",
function(){var a=$(this);$("#searchresults").slideToggle();a.text()==PMA_messages.strHideSearchResults?a.text(PMA_messages.strShowSearchResults):a.text(PMA_messages.strHideSearchResults);return false});$('<div id="togglesearchformdiv"><a id="togglesearchformlink"></a></div>').insertAfter("#db_search_form").hide();$("#togglequerybox").hide();$("#togglequerybox").bind("click",function(){var a=$(this);$("#sqlqueryform").slideToggle("medium");a.text()==PMA_messages.strHideQueryBox?a.text(PMA_messages.strShowQueryBox):
a.text(PMA_messages.strHideQueryBox);return false});$("#togglesearchformlink").html(PMA_messages.strShowSearchCriteria).bind("click",function(){var a=$(this);$("#db_search_form").slideToggle();a.text()==PMA_messages.strHideSearchCriteria?a.text(PMA_messages.strShowSearchCriteria):a.text(PMA_messages.strHideSearchCriteria);return false});$("#db_search_form.ajax").live("submit",function(a){a.preventDefault();var d=PMA_ajaxShowMessage(PMA_messages.strSearching,false);$form=$(this);PMA_prepareForAjaxRequest($form);
a=$form.serialize()+"&submit_search="+$("#buttonGo").val();$.post($form.attr("action"),a,function(b){if(typeof b=="string"){$("#searchresults").html(b);$("#togglesearchresultlink").text(PMA_messages.strHideSearchResults);$("#togglesearchresultsdiv").show();$("#searchresults").show();$("#db_search_form").slideToggle().hide();$("#togglesearchformlink").text(PMA_messages.strShowSearchCriteria);$("#togglesearchformdiv").show()}else $("#sqlqueryresults").html(b.message);PMA_ajaxRemoveMessage(d)})})},"top.frame_content");
