Tag Archive > javascript

How to access element values inside an iframe using Javascript?

Here’s another helpful post for beginners in how to access element values inside an iframe.

var txt = window.frames["iframeName"].document.forms["formName"].elements["elementName"].value;

Tip:  To avoid confusion, your page elements should have the same Id and Name.
I hope this helps!

Continue reading

, ,