I have the following code: Event.observe($('store_locator_form'), 'submit', function() { $('storelocator-results').style.visibility = 'visible'; storeLocator.search($('address').value, { radius: $('radius').value }); }); Code (markup): This is for a store locator script. I have it currently running off one field called "address" I need to add fields to the form and change the current address field to "city" and add "state" and "zip" How do I concatenate the fields city, state and zip into address? I have to put it all into one because the address is all in one field in the db and address is also being run through a script for googlemaps. I have tried many ways and have been unsuccessful. Thanks for any help!
you are using Prototype right? you can do it maybe like this: $('city').value + "someseparator" + $('state').value + "someseparator" + $('zip').value
Yes it is prototype. That is a possible solution but how do I attach it to be the var address? Thanks!
SWEET! Thank you. It worked no problem. I had the var part but wasn't getting this: storeLocator.search(finalAddress, { Code (markup):