Bug 673385: Dragging text into the QuickSearch field on index.cgi doesn't delete the help text in this field
r=dkl a=justdave git-svn-id: svn://10.0.0.236/trunk@265181 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
7ce4a294ec
commit
33572049bc
@ -1 +1 @@
|
|||||||
8864
|
8865
|
||||||
@ -17,41 +17,6 @@
|
|||||||
style_urls = [ 'skins/standard/index.css' ]
|
style_urls = [ 'skins/standard/index.css' ]
|
||||||
%]
|
%]
|
||||||
|
|
||||||
|
|
||||||
<script type="text/javascript">
|
|
||||||
<!--
|
|
||||||
function onLoadActions() {
|
|
||||||
quicksearchHelpText('quicksearch_main', 'show');
|
|
||||||
document.getElementById('quicksearch_top').focus();
|
|
||||||
}
|
|
||||||
var quicksearch_message = "Enter [% terms.abug %] # or some search terms";
|
|
||||||
|
|
||||||
function checkQuicksearch( form ) {
|
|
||||||
if (form.quicksearch.value == '' || form.quicksearch.value == quicksearch_message ) {
|
|
||||||
alert('Please enter one or more search terms first.');
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
function quicksearchHelpText(el_id, action){
|
|
||||||
var el = document.getElementById(el_id);
|
|
||||||
if ( action == "show") {
|
|
||||||
if( el.value == "" ) {
|
|
||||||
el.value = quicksearch_message
|
|
||||||
YAHOO.util.Dom.addClass(el, "quicksearch_help_text");
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
if( el.value == quicksearch_message ) {
|
|
||||||
el.value = "";
|
|
||||||
YAHOO.util.Dom.removeClass(el, "quicksearch_help_text");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
YAHOO.util.Event.onDOMReady(onLoadActions);
|
|
||||||
//-->
|
|
||||||
</script>
|
|
||||||
|
|
||||||
[% IF release %]
|
[% IF release %]
|
||||||
<div id="new_release">
|
<div id="new_release">
|
||||||
[% IF release.data %]
|
[% IF release.data %]
|
||||||
@ -128,11 +93,10 @@ YAHOO.util.Event.onDOMReady(onLoadActions);
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<form id="quicksearchForm" name="quicksearchForm" action="buglist.cgi"
|
<form id="quicksearchForm" name="quicksearchForm" action="buglist.cgi">
|
||||||
onsubmit="return checkQuicksearch(this);">
|
<input id="quicksearch_main" name="quicksearch" title="Quick Search"
|
||||||
<input id="quicksearch_main" type="text" name="quicksearch" title="Quick Search"
|
placeholder="Enter [% terms.abug %] # or some search terms"
|
||||||
onfocus="quicksearchHelpText(this.id, 'hide');"
|
autofocus required>
|
||||||
onblur="quicksearchHelpText(this.id, 'show');">
|
|
||||||
<input id="find" type="submit" value="Quick Search">
|
<input id="find" type="submit" value="Quick Search">
|
||||||
<a href="page.cgi?id=quicksearch.html" title="Quick Search help">[?]</a>
|
<a href="page.cgi?id=quicksearch.html" title="Quick Search help">[?]</a>
|
||||||
</form>
|
</form>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user