3 <script type="text/javascript" src="cql.js"></script>
4 <script type="text/javascript">
5 var cp = new CQLParser();
7 function parseInput(query) {
10 document.getElementById("output").value = cp.toXCQL();
11 document.getElementById("output2").value = cp.toString();;
12 //re-parse fq to see the o/i matches
14 document.getElementById("output3").value = fq;
16 document.getElementById("output4").value = cp.toString();
18 document.getElementById("output").value = e.message;
19 document.getElementById("output2").value = e.message;
24 <title>CQL parser</title>
28 <form name="test" onsubmit="parseInput(this.q.value); return false;">
30 <input type="text" name="q" size="160" onkeyup="parseInput(this.value); return false;"></input>
36 <textarea id="output" rows="80" cols="80"></textarea>
37 <textarea id="output2" rows="80" cols="80"></textarea>
38 <textarea id="output3" rows="80" cols="80"></textarea>
39 <textarea id="output4" rows="80" cols="80"></textarea>