0

Can someone help me to keep the focus on the input in the iframe that embeds from other page. I want to use it to input key to control the motor dc to my IoT project. In the original page autofocus just work fine, but on the main page when i wanna enter the value you have to click it first and the autofocus just not work.

My iframe script just like this

<iframe name="foo" id="foo" width="280" height="100px" frameborder="0" src="http://blabla" autofocus></iframe>

And in blabla page is only have one usually input like

<input type='text' name='foo' id='foo' size='10' onkeydown='myFunction(event)' autofocus>

i use Version 77.0.3865.90 Google chrome Thanks

0 Answers0