//clear the "Search..." from the search box on click/focus
function clearSearch() {
    if(document.getElementById("q").value == "Search...") {
        document.getElementById("q").value = "";
    }
}

//reset the search box if it is left empty on lost focus
function resetSearch() {
    if(document.getElementById("q").value == "") {
        document.getElementById("q").value = "Search...";
    }
}

//on load, set the handlers and add "Search..." to search box
//this will keep the box clean in non-JS-enabled browsers
window.onload = function () {
    q = document.getElementById("q");
    if(q) {
        if(q.value == "") {
            q.value = "Search...";
        }
        
        q.onfocus = clearSearch;
        q.onblur = resetSearch;
    }
}       