added popup.js functionality for more advanced users (i.e. some html5 knoweldge is necessary).