The focus method will support in all browser.
Example :At first we have created a html page in which there are two text boxes and two buttons. Now, when user click on first button then focus is set to first text box and when the user click on second button then the focus will set to second text box.
Output from the program is as follows:
When you click on button "Click to Focus on first textbox" then focus will beset to the first text box as you can see in the below output:
And, when you click the button "Click to Focus on second textbox" the focus will set to the second text box as you can see the below output:
Rs. 20,000 US$ 300
Today: Rs. 10,000 US$150
Course Duration: 30 hrs
Posted on: July 4, 2013 If you enjoyed this post then why not add us on Google+? Add us to your Circles