I have used em tags to write some text on an image. I want to provide some kind of functionality such that when a user types in text box this text comes over image. I have doubt which event listener should I add to text box so that as soon as change the content of text box it can change the content of image too. I just need to know can this be done with event listener or something more is needed. I know how to change text in image but could not find out how should i update this image text dynamically. Hope am clear with question
Here is another alternative way to use pure javascript.
Add onkeyup in textbox and call a function that you have provided.
<input type="text" id="tbMain" onkeyup="keyup();">
When press the key up its will call function keyup()
See more at here.
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