Javascript modifications