I'm using List.js to generate lists (obviously), however I'm having trouble creating links inside of the list items.
Here's my code so far --
<script>
var options = {
valueNames: [ 'title', 'description', 'lat', 'lng', 'user_sub', 'location', 'imageurl'],
item: '<li><h3 class="title"></h3><p class="description"></p><p class="location"></p><p class="user_sub"></p></li>'
};
var values = JSON.parse('{{ jsonout|safe }}');
var userList = new List('users', options, values);
</script>
That creates a nice list, however I want to join the lat and lng ValueNames together to create a list, normally I would do something like this (an example from Google Maps that I've used)
'<a href=http://www.google.com/maps/place/' + data.lat+ ',' + data.lng + '/@' + data.lat + ',' + data.lng +',6z target=_blank>Get Directions</a>'
However, since all the items are created in the HTML class section, this doesn't work. Any suggestions on how to make it work, or maybe its not an option with this plugin?