Implement Javascript voting