var query = (qu).split(' ').join('%');
if (query == '') {
dojo.byId('parcel_search_info').innerHTML = '<span style="color:#900;">You must enter a search value. Try again.</span>'
} else if (new String(query).length < 3) {
dojo.byId('parcel_search_info').innerHTML = '<span style="color:#900;">Searchs must contain at least 3 characters. Try again.</span>'
} else {
dojo.byId('parcel_search_info').innerHTML = '<img src="images/waiting.gif" /> Searching...';
var qt = new esri.tasks.QueryTask(config.parcelQueryUrl + '?token=' + config.app.token);
var q = new esri.tasks.Query();
q.returnGeometry = true;
q.outFields = config.parcelQueryOutFields;
q.where = "UPPER(PID) like '%" + query.toUpperCase() + "%' or UPPER(ADDRESS) like '%" + query.toUpperCase() + "%' or UPPER(OWNER) like '%" + query.toUpperCase() + "%'";
qt.execute(q, function(results) {
if (results.features.length == 0) {
dojo.byId('parcel_search_info').innerHTML = '<span style="color:#900;">Sorry, but your search did not return any parcels. Try again.</span>'
} else if (results.features.length > 120) {
dojo.byId('parcel_search_info').innerHTML = '<span style="color:#900;">Sorry, but your search returned too many parcels. Try again.</span>'
} else {
//build grid
}
})
}
[HTML]<h3>Enter Parcel ID (PID), address or owner</h3><form action="javascript:viewer.parcelSearch()"> <input id="parcel_search_value" dojoType="dijit.form.TextBox" placeholder="PID, address or owner" style="width:250px; font-size:14px;" /> <br /> <div dojoType="dijit.form.Button" iconClass="iconSearch" type="submit" style="margin-top:8px;">SEARCH</div></form><div id="parcel_search_info" style="margin-top:4px;"></div>[/HTML]This is a query, but the same principle. Other point of info options include a dialog, tooltip, js alert, etc. I saw a pretty cool one the other day that displayed info in the textbox itself with different colored text.