diff options
Diffstat (limited to 'quicksearch.js')
-rw-r--r-- | quicksearch.js | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/quicksearch.js b/quicksearch.js index 7778d3598..e8834a722 100644 --- a/quicksearch.js +++ b/quicksearch.js @@ -46,8 +46,11 @@ function do_shift(l) { } function go_to (url) { - document.location.href = url; - //window.open(url, "other" ); + if (sidebar == 1) { + load_relative_url(url); + } else { + document.location.href = url; + } } function map(l, f) { @@ -600,8 +603,7 @@ function unique_id () { return (new Date()).getTime(); } -function ShowURL(mode) { - var input = document.f.id.value; +function ShowURL(mode,input) { var searchURL = make_query_URL(bugzilla+"buglist.cgi", input, false); if (searchURL != no_result) { var pieces = searchURL.replace(/[\?]/g,"\n?").replace(/[\&]/g,"\n&"); @@ -684,7 +686,7 @@ function Search(url, input, searchLong) { // derived from http://www.cs.hmc.edu/~jruderma/s/bugz.html // QuickSearch combines lookup-by-bug-number and search -// in a single textbox. It's name must be document.f.id . +// in a single textbox. // // type nothing: // --> go to bugzilla front page @@ -696,10 +698,8 @@ function Search(url, input, searchLong) { // --> search summary, product, component, keywords, status whiteboard // (and URL if it's an IP address, a host.name, or an absolute://URL) -function QuickSearch () +function QuickSearch (input) { - var input = document.f.id.value; - //remove leading and trailing whitespace input = input.replace(/^[\s]+/,"").replace(/[\s]+$/,""); @@ -726,9 +726,7 @@ function QuickSearch () return; } -function LoadQuery() { - var input = document.f.id.value; - +function LoadQuery(input) { //remove leading and trailing whitespace input = input.replace(/^[\s]+/,"").replace(/[\s]+$/,""); |