I'd like to make a JavaScript script that'd generate numbers from 0000 to 9999, not randomly but that would try every number one by one, like 0000, 0001, 0002... and would press the submit button right after, the script should remain running after page refreshes.
Input box:
<input id="form_Number" name="form[Number]" required="required" class="form-control" value="" type="text" pattern="[0-9]*" data-kpxc-id="form_Number">
Submit button:
<button type="submit" id="form_submit" name="form[submit]" class="btn-primary btn">Submit</button>
It's for one primitive website that uses codes to login, it doesn't have a captcha too. Either way, it's supposed to try out every combination until it successfully logs in, like the script puts in these combinations and presses the button immediately, then if fails, page refreshes and script should remain running and put those combinations over and over. It's more for fun than for serious purposes. Also I have to be logged in on the site with actual user to access this input box.