I have a javascript function to validate user's input in input or textarea field, I also want to apply these functions on the Iframe's textarea. Is it possible to run the parent's javascript on an iframe with another domain. If yes, how can I do it. Sorry for my newbie question. Thanks in advance
-
is your iframe on the same domain?Vicky Gonsalves– Vicky Gonsalves2013-10-23 07:13:30 +00:00Commented Oct 23, 2013 at 7:13
-
post some code so that we can checkVicky Gonsalves– Vicky Gonsalves2013-10-23 07:13:49 +00:00Commented Oct 23, 2013 at 7:13
-
developer.mozilla.org/en-US/docs/Web/JavaScript/…Abhitalks– Abhitalks2013-10-23 07:15:02 +00:00Commented Oct 23, 2013 at 7:15
-
possible duplicate of <iframe> javascript access parent DOM across domains?raam86– raam862013-10-23 07:18:00 +00:00Commented Oct 23, 2013 at 7:18
-
abhitalks has already posted a link explaining the Same-Origin Policy. In some situations there are some work-arounds though.Teemu– Teemu2013-10-23 07:18:01 +00:00Commented Oct 23, 2013 at 7:18
Add a comment
|
2 Answers
You can't do this as a result of the Same Origin Policy http://en.wikipedia.org/wiki/Same_origin_policy