adding type="text/javascript"