Results 1 to 3 of 3

Thread: 2 IFrames -Iframe1 btn onclick load iframe2 src & pass iframe1 txtbox val as param

  1. #1
    Join Date
    Dec 2007
    Posts
    88
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Question 2 IFrames -Iframe1 btn onclick load iframe2 src & pass iframe1 txtbox val as param

    Hi, I need help please.

    I need to create a textbox with a report url in an iframe below.
    Onclick of button create IFrame and pass textbox value into parameter of iframe src.

    I'm not to sure how to do this, i think some javascript is needed as I want the button to check the textbox is not blank value first and then create iframe and pass textbox value as parameter.

    Does anyone have another method where there are 2 iframes:
    Having the textbox & button in first frame - then Onclick check textbox not blank and load second iframe - load and pass textbox value as parameter.

    [code:]
    <form id="form1">
    <table><tr>

    <input type="text" text="Keyword" id="keyword" value="">
    <input type="button" text="filter" id="filter" onclick="
    <IFRAME id="frame1" src="http://srv08-za199/BI&rs:Command=Render&Key="+filter.value+"></IFRAME>"

    </tr>
    [/code]

    Please Assist!

  2. #2
    Join Date
    May 2007
    Location
    Boston,ma
    Posts
    2,127
    Thanks
    173
    Thanked 207 Times in 205 Posts

    Default

    You could try this last post down by Dr Nick http://www.dynamicdrive.com/forums/s...ad.php?t=37370. Its a basic idea not exactly what your looking for but somewhat.

  3. #3
    Join Date
    Dec 2007
    Posts
    88
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default Thank You

    Thank You - Working!

    [code:]
    <tr>
    <input type="text" text="Keyword" id="keyword" value="">
    <input type="button" text="filter" id="filter" onClick="(document.getElementById('keyword').value=='') ? alert('Enter a Keyword!'); document.getElementById('frame1').src='http://srv08-za199/BI&rs:Command=Render&Key='+document.getElementById('keyword').value;">
    </tr>
    <tr>
    <IFRAME id="frame1" src="blank.htm">iframe_placeholder_value</IFRAME>

    </tr>
    [/code:]

Bookmarks

Posting Permissions

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