Hi, i'm new on this forum.
I need to get a url of an iframe from a form.
A parent php page with an iframe, in the iframe the user can navigate and when the user has found his page click a button on the php parent page that send a variable to another php page with the frame url.
It is possibile?
I think you want to use javascript to communicate across frames. even if you could use PHP, the user experience would not be that great... probably involve page refreshes.
If both the parent page and the iframe page are on the same domain, you can access functions in the parent from the iframe via JavaScript as:
Code:
window.parent.functionName()
If they are on different domains, it's possible, but gets quite a bit more convoluted (and I'm not sure I could explain it correctly without doing a lot of research first).
"Please give us a simple answer, so that we don't have to think, because if we think, we might find answers that don't fit the way we want the world to be."
~ Terry Pratchett in Nation
THE FRAME IS A WEBSITE, BETHINK GOOGLE, the user can navigate on the frame and when has found the following webpage click on the submit and send the variable $url that will contain the url of the webpage to geturl.php.
Last edited by marcolettieri; 10-11-2012 at 06:21 AM.
Bookmarks