JavaScript challenges web application