The code below successfully open a blank new Window, the OpenWin function is
held in a separate file and I use it successfully to open windows elsewhere
on my site. However the window is completely blank and "about:blan k -
Microsoft Internet explorer" appears in it's title bar. The new window
corresponds to the sizes I enter in the OpenWin function, so this must be
working.
What I want is for a PDF file, based on the user's selection to be displayed
in this new window. Can anyone see from the code below why this is not
happening?
<table>
<tr>
<form name=Downloads method=POST action=Choice.a sp target=TestWin>
<td>
<Select size="3" Name=Download onchange=OpenWi n("TestWin",720 ,600)>
<option value="1">Downl oad1
<option value="2">Downl oad2
<option value="3">Downl oad3
<option value="4">Downl oad4
</Select>
</td>
</form>
</tr>
</table>
This is the body of Choice.asp, which is in the same directory as the
calling page above:
<body>
<%
Select Case Request("Downlo ad")
Case 1
Response.Redire ct ("Download1.pdf ")
Case 2
Response.Redire ct ("Download2.pdf ")
Case 3
Response.Redire ct ("Download3.pdf ")
Case 4
Response.Redire ct ("Download4.pdf ")
End select
%>
</body>
All the PDF are in the same directory.
When I manually enter a URL ....{path}/Choice.asp?Down load=1, then
Download1.pdf appears in the window.
Can anyone assist... this has been driving me crazy!!!!!
Comment