I am developing a Firefox extension which need to change some values on a specific <div>.
I try to inject this into the DOM by tying this into the URL bar:
javascript:document.getElementById('c4d9b2819218742680841961_input').innerHTML = 'foo'
The value do change but then the whole page become blank quickly expect the <div>.
How can I avoid this? Thanks.
It is acting on the return value for of your code. Wrapping it in a void() will suppress this. This should work>
javascript:void(document.getElementById('c4d9b2819218742680841961_input').innerHTML = 'foo')
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With