kwokhao
01-09-2003, 06:12 AM
Hi all,
Need some help here. It might be be a simple one after all :)
I have a page with 2 frame, let's call them MenuFrame and ContentFrame.
Next i have 2 buttons on the MenuFrame, when clicked, will pass a value to a cgi script that will determine which picture to be display and display it on the ContentFrame.
Codes on MenuFrame html:
<form action="cgi-bin/searchPicture.cgi" method="post">
<input type=image name=Button1 src="images/Button.jpg" width="20" height="20" border="0">
<input type="hidden" name="Picture" value="Pic-001">
</form>
<form action="cgi-bin/searchPicture.cgi" method="post">
<input type=image name=Button2 src="images/Button.jpg" width="20" height="20" border="0">
<input type="hidden" name="Picture" value="Pic-002">
</form>
There's no problem with the cgi script, it searches the correct picture. What happen is that the picture is displayed on the MenuFrame instead of the ContentFrame. Bcos the cgi script is been called from the MenuFrame.
Is there a way to correct this? Perhaps a way to target the ContentFrame in the form action codes?
Something like this:
<form action="cgi-bin/searchPicture.cgi" method="post" target="ContentFrame" >
regards :)
Need some help here. It might be be a simple one after all :)
I have a page with 2 frame, let's call them MenuFrame and ContentFrame.
Next i have 2 buttons on the MenuFrame, when clicked, will pass a value to a cgi script that will determine which picture to be display and display it on the ContentFrame.
Codes on MenuFrame html:
<form action="cgi-bin/searchPicture.cgi" method="post">
<input type=image name=Button1 src="images/Button.jpg" width="20" height="20" border="0">
<input type="hidden" name="Picture" value="Pic-001">
</form>
<form action="cgi-bin/searchPicture.cgi" method="post">
<input type=image name=Button2 src="images/Button.jpg" width="20" height="20" border="0">
<input type="hidden" name="Picture" value="Pic-002">
</form>
There's no problem with the cgi script, it searches the correct picture. What happen is that the picture is displayed on the MenuFrame instead of the ContentFrame. Bcos the cgi script is been called from the MenuFrame.
Is there a way to correct this? Perhaps a way to target the ContentFrame in the form action codes?
Something like this:
<form action="cgi-bin/searchPicture.cgi" method="post" target="ContentFrame" >
regards :)