0

The web app i'm creating uses jquery lights out and has an html iframe to an internal form. Whoever uses this app will have to press the submit button. Is there a way i can link a free area of space surrounding the submit button, so any clicks within that space call the jquery functions in my code?

I'd like to do this so submitting the form automatically closes the lights out messagebox, rather than app users seeing what happens in the iframe after they submit the form.

Thanks! -Diego

DiegoC
  • 1
  • 1
  • You might want to refine your question to get (more) answers. Perhaps link to the plugin(?) used. As present, it's not quite clear what you're about. – Jawa Apr 27 '10 at 16:17
  • Is the iframe on the same domain or not? Can you edit the html of the iframed page? – Benbob Aug 02 '10 at 05:24

1 Answers1

0

My suggestion is to put an iframe of a page from your own site on the iframed form page. Via url parameters you can submit data to the parent window because this second iframe is on the same domain.

Here is a really bad diagram of how the concept works.

```````````````````````````
|  parent window     <-data <<<<
|                                ^
| |====x-domain security====|    ^
| |  Your form page iframe  |    ^
| |  [submit]               |    ^
| |                         |    ^
| |  |````````````````````  |    ^
| |  |helper iframe  data->>>>>>  

Of course this means you would need access to the html of the external site.

See the top answer on this question for details. Resizing an iframe based on content

It sounds like the same problem except you are manipulating jquery lights out instead of the height.

Community
  • 1
  • 1
Benbob
  • 13,876
  • 18
  • 79
  • 114