I 'm beginer to js and coding and i trying build an web site with google map + places api, so when type "restaurant or bar or etc" to shw this business on map and on sidebar.
http://jsbin.com/ayugun/46/edit
All code works fine without sidebar code:
var side_bar_html = "<a href='javascript:google.maps.event.trigger(gmarkers["+parseInt(gmarkers.length-1)+"],\"click\");'>"+place.name+"</a><br>";
document.getElementById('side_bar').innerHTML += side_bar_html;
but I need to repair this code to make it workable. So when I type" restaurant or bars or etc." to show me on map and on #side_bar
WHere is error in my code for sidebar?
sorry for my englsih, is not very well, but I learn hard to learn english and coding.thanks