Use js to support multiple buttons

WIP