If you don't need all the extras of LVL and you just want to load your PostGIS data into Leaflet, you should be able to use that PHP script that you referenced. That basically spits your data out of PostGIS into GeoJSON than can be consumed by Leaflet.
Once you have that working, just add that data to your GeoJSON layer with an AJAX call (I use jQuery) like so:
var myLayer = new L.geoJson(null, {
pointToLayer: function (feature, latlng) {
return L.marker(latlng, {
});
},
onEachFeature: function (feature, layer) {
if (feature.properties) {
layer.bindPopup(feature.properties.my_attribute);
}
}
});
$.getJSON("postgis_geojson.php", function (data) {
myLayer.addData(data);
});