code: private String normalizePreviousQueryJS() {
  
          StringBuffer result = new StringBuffer();
          result.append("<script type=\"text/javascript\">\n");
          result.append("  function normalizeQueryValue() {\n");
          result.append("    var searchform = document.forms['EDITOR'];\n");
          result.append("    var query = searchform.elements['query.0'].value;\n");
          result.append("    query = decodeURI(query);\n");
          result.append("    searchform.elements['query.0'].value = query;\n");
          result.append("    return true;\n");
          result.append("  }\n");
          result.append("  normalizeQueryValue();\n");
          result.append("</script>\n");
          return result.toString();
      }
docs: Normalizes the JavaScript for the previous search query.<p>
  
  @return the normalized JavaScript