title: Problems with JS Autocomplete. Doesnt trigger
body: <p>I have the following JSP</p>
  
  <pre><code>&lt;!-- Map section --&gt;
  
  &lt;div class="row"&gt;
      &lt;div class="col-md-9 col-sm-9 col-xs-9"&gt;
          &lt;div id="map" style="width: 100%; height: 500px"&gt;&lt;/div&gt;
      &lt;/div&gt;
  &lt;/div&gt;
  
  &lt;!-- Modal with form. Inside this modal form i have this input --&gt;
  
  
  &lt;input class="form-control" name="pickupLocation" id="txtPickUpLocation" type="text" required&gt;
  
  
  &lt;!-- Script Section inside JSP file --&gt;
  
  &lt;script&gt;
  var autocomplete;
  function initializate(){
      geocoder = new google.maps.Geocoder();
  
  
      //TEMPORARY SOLUTION: Set Manually coordinates (Guayaquil)
  
      setCoordinates(-2.159530, -79.894745);
      test();
  }
  function test(){
  
      var inputPlace = document.getElementById('txtPickUpLocation');
      autocomplete = new google.maps.places.Autocomplete(inputPlace);
  
      google.maps.event.addListener(autocomplete, 'place_changed',
      function() {
          var place = autocomplete.getPlace();
  
          console.log('Coordenadas obtenidas');
          var lat = place.geometry.location.lat();
          var lng = place.geometry.location.lng();
  
      });
  }
  
  function setCoordinates(lat, lng) {
          //Save the TMP coordinates to later, obtain ubication in string form.
          latitude = lat;
          longitude = lng;
  
          obtainUserPlaceLocation(latitude, longitude, function(result) {
              //After obtain the actual position of the user (Browser?), now we can create the map.
              initMap();
              //Then, search the taxi locations to show it
              obtainTaxisLocations();
          });
      }
  &lt;/script&gt;
  &lt;script type="text/javascript" src="http://maps.google.com/maps/api/js?key=API_VALID_KEY&amp;libraries=places&amp;callback=initializate"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>I have the following script. With the function <code>setCoordinates</code> I get my coordinate and I create the map with that position and with <code>test</code>function, set the listener when the user types to get the location. The map is shown, but when I show the modal and write in the input the autocomplete is not executed. I have worked with autocomplete before but I have never had problems. The truth is I do not know what the problem could be, and it's driving me crazy. Any help would be welcome, thank you very much</p>
  
  <p>EDIT: I add <code>setCoordinates</code> function. In this functions I call to <code>obtainUserPlaceLocation</code> to obtain the location (String format) with the lat, lng parameters, when this is finished I create the map and search taxis (web services using the string location obtained from lat,lng) to put on the map. Everything works, except autocomplete places input. </p>