IFrame and form inside - what happens?

T

Tom Szabo

I know, they are bad, so please dont't just tell me that I should not use
it...

So, assume I have a page MyPage.

MyPage has an IFrame in it with
'src=http://www.MyDomain.com/Test.php?id=24'

This page on the other hand has a form inside.

What should happen when the form submits?

TIA,

Tom
 
G

Grant Wagner

Tom said:
I know, they are bad, so please dont't just tell me that I should not use
it...

So, assume I have a page MyPage.

MyPage has an IFrame in it with
'src=http://www.MyDomain.com/Test.php?id=24'

This page on the other hand has a form inside.

What should happen when the form submits?

TIA,

Tom

How is this a JavaScript question? And what are "they" and why are "they
bad"?

Anyway, an -iframe- is just a window object, which has as -document- object
as a property, which has a -forms- collection.

If the form on the document in the window that is the iframe has no -target-
attribute and it's submitted, the results of the form submission will appear
in the window it started in (the iframe).
 
R

Randy Webb

Tom said:
I know, they are bad, so please dont't just tell me that I should not use
it...

Whats bad? What should you not use?

http://jibbering.com/faq/#FAQ2_3
Paragraph 2, Sentence 2.
<quote>
Use the Subject: of your post to indicate the type of problem you have,
but include the question *in the body as well*.
So, assume I have a page MyPage.

MyPage has an IFrame in it with
'src=http://www.MyDomain.com/Test.php?id=24'

This page on the other hand has a form inside.

What should happen when the form submits?

The data that is in the form is collected by the browser and sent to the
server. The server processes that data and sends the results back.

What does this have to do with Javascript? It is easily tested in less
time than it would have taken you to post the question.
 
T

Tom Szabo

Randy Webb said:
Whats bad? What should you not use?

http://jibbering.com/faq/#FAQ2_3
Paragraph 2, Sentence 2.
<quote>
Use the Subject: of your post to indicate the type of problem you have,
but include the question *in the body as well*.


The data that is in the form is collected by the browser and sent to the
server. The server processes that data and sends the results back.

What does this have to do with Javascript? It is easily tested in less
time than it would have taken you to post the question.

Sorry,

It was 4 am in the morning or about, so I was getting a little tired :-(

Also the BAD stuff came from the intention to avoid half a dozen replies
telling me that I should not use frames.

May be not this newsgroup, but I can often see people asking questions about
how to do this or that and the person who replies only occupied with pushing
his opinion through to the originator of the question, most often not having
a clue about the big picture

So this is what I wanted to avoid....

Regards,

Tom
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top