After submitting a form, I get redirected to another form where I want to populate email field with the value from previous form. I have next url:
mysite.com/a/blog/?email=test%40email.com#form_20
How to make input with id="email" populated with test@email.com using javascript ?
UPDATE:
Thanks @MA-Maddin for helpful link: How to use JavaScript to fill a form on another page With this, I get email like: test%40email.com . I am wondering, how to combine
decodeURIComponent('%40')
with provided solution:
window.location.search.replace(/^\?email=/, '')
Thanks.