Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    Senior Coder
    Join Date
    Aug 2002
    Location
    Kansas City, Kansas
    Posts
    1,518
    Thanks
    0
    Thanked 2 Times in 2 Posts

    Passing form data to an iframe

    I was wondering how i could pass the data entered into a from to and iframe. A simple example will suffice and i will try to edit it to my taste.

  • #2
    Regular Coder
    Join Date
    Sep 2002
    Location
    Louisiana
    Posts
    576
    Thanks
    0
    Thanked 0 Times in 0 Posts
    there are many ways, give it an id

    <iframe ... id="id"></iframe>
    <script>
    document.getElementById("id").inputname.value = document.inputname.value

    or frames

    <iframe ... name="ifrm"></iframe>
    parent.frames["ifrm"].document.inputname.value = document.inputname.value;

    that assumes the name of two input names.

  • #3
    Senior Coder
    Join Date
    Aug 2002
    Location
    Kansas City, Kansas
    Posts
    1,518
    Thanks
    0
    Thanked 2 Times in 2 Posts
    lol i didnt know it was that simple, ill give that a shot.

  • #4
    Senior Coder
    Join Date
    Aug 2002
    Location
    Kansas City, Kansas
    Posts
    1,518
    Thanks
    0
    Thanked 2 Times in 2 Posts
    wat if i want to get data from the main page to display in my iframe?


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •