Add embed event binding feature.

Had to move around a lot of things but the important changes are in 
lagoa_api.js and event_embed_demo.html.