Let's add some code lines to make our search more intuitive:
Add the following lines on app/views/pages/locations.html, between the highlighted code:
<div class="row"> <div class="col s3"> ... </div> <div class="col s9"> <form action="/nearme" method="POST"> ... </div> </div>
Add the following function, at the end of locations.html right after the {% endfor %} loop:
// get all the pan-to-marker class var els = document.querySelectorAll(".pan-to-marker"); // looping over all list elements for (vari = 0, len = els.length; i<len; i++) { els[i].addEventListener("click", function(e){ e.preventDefault(); // Use -1 for index because loop.index from swig starts on 1 var attr...