I am trying to populate an Email verification Number, to a webpage. Assuming I have the six-digit number as a string, is there a way to populate it using selenium in python?
Here is the link: https://testnet.phemex.com/login
The following is the html
<div>
<div class="wrap svelte-1ysrabk">
<div class="digits svelte-1ysrabk">
<div class="digit-box svelte-1ysrabk active"><span class="txt svelte-1ysrabk">1</span> <input type="number" maxlength="1" max="9" data-index="0" class="svelte-1ysrabk"></div>
<div class="digit-box svelte-1ysrabk"><span class="txt svelte-1ysrabk">1</span> <input type="number" maxlength="1" max="9" data-index="1" class="svelte-1ysrabk"></div>
<div class="digit-box svelte-1ysrabk"><span class="txt svelte-1ysrabk"></span> <input type="number" maxlength="1" max="9" data-index="2" class="svelte-1ysrabk"></div>
<div class="digit-box svelte-1ysrabk"><span class="txt svelte-1ysrabk"></span> <input type="number" maxlength="1" max="9" data-index="3" class="svelte-1ysrabk"></div>
<div class="digit-box svelte-1ysrabk"><span class="txt svelte-1ysrabk"></span> <input type="number" maxlength="1" max="9" data-index="4" class="svelte-1ysrabk"></div>
<div class="digit-box svelte-1ysrabk"><span class="txt svelte-1ysrabk"></span> <input type="number" maxlength="1" max="9" data-index="5" class="svelte-1ysrabk"></div>
</div>
<div class="explain svelte-1ysrabk"></div>
</div>
</div>
To see the field do the following steps:
- Go to https://testnet.phemex.com/
- Click Login
- In the next field click "Reset Password"
- Enter your email
- Click "Continue"
There are six digit-boxes with different data-indexes and I'm not sure how to populate them. Thanks for any potential help!
