title: Google maps Places API V3 autocomplete - select first option on enter (and have it stay that way)
body: <p>This question relates to the answer for this one: <a href="https://stackoverflow.com/questions/7865446/google-maps-places-api-v3-autocomplete-select-first-option-on-enter">Google maps Places API V3 autocomplete - select first option on enter</a>. Basically, it is to make the field use the first suggestion from the autocomplete list when the user presses enter. The answer for that question has a jsfiddle - <a href="http://jsfiddle.net/dodger/pbbhH/" rel="nofollow noreferrer">http://jsfiddle.net/dodger/pbbhH/</a> - which works except when the text field loses focus, the field value returns to the partially entered value. </p>
  
  <p>For example, a user clicks in the input field and types 'ox', the autocomplete box pops up with some suggestions, and the user presses enter. The map is then changed to show the location of the first item from the autocomplete box (with a marker), and the value of the input field is changed to the first item from the autocomplete box. The user then clicks somewhere outside the field and the value of the input field returns to 'ox'. </p>
  
  <p>I would like the value of the input field to stay as the first autocomplete suggestion.</p>