First let me tell you that ESRI Tech support ofr the Javascript API is fantastic. they are really making an effort to make it work for everyone.
that being said, here is my geocode locator code. I also have use a US one range for my locator with one field "Street:" the problem is that the sample uses a field called "Address:" which is also the name of their variable in the JavaScript for the user entry box. So I get confused very easy. 🙂
after the close of the init{} part this is what i have.
function locate() {
map.graphics.clear();
var add = dojo.byId("address").value.split(",");
var address = { Street: add[0] };
locator.addressToLocations(address,["Loc_name"]);
}
function showResults(candidates) {
var candidate;
var symbol = new esri.symbol.SimpleMarkerSymbol();
var infoTemplate = new esri.InfoTemplate("Location", "Street: ${address}<br />Score: ${score}<br />Side: ${side}");
_____the code moves on here but that's all i changed______
you can see where i put the "Street:" field in replacement of the Sample's "Address:"
I hope that works, i am not a programmer either. but i have to play one at work.
-Micah