Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ASP JavaScript

Status
Not open for further replies.

jvande

MIS
Jun 6, 2001
115
US
I am calling the following favascript function to open a window. I have asp inside it to try to pass picture id to the new window. How do I go about this?
var newWind=window.open(&quot;image_upload.asp?PIctureID=<% =picID%>&quot;,&quot;display&quot;,&quot;width=550,height=100,screenX=&quot;+w+&quot;,screenY=&quot;+h);

Thanks,
Josh
 
I guess my problem is this. I am not passing any data so I tried the following code.

Main window:

function openWindow(test)


{
var newWind=window.open(&quot;image_upload.asp?PIctureID=&quot; + test&quot;,&quot;display&quot;,&quot;width=550,height=100,screenX=&quot;+w+&quot;,screenY=&quot;+h);
}

<% test = 1 %>
<INPUT TYPE=&quot;button&quot; VALUE=&quot;Replace Picture&quot; onClick=&quot;openWindow(test)&quot;>

Popup window code
<% objpictureid = Request(&quot;pictureid&quot;)
response.write objpictureid
%>

I am trying to get the popwindow to print 1 which is the value of temp.
Any ideas?

Thanks,
Josh



 
How bout

function openWindow(test){
var newWind=window.open(&quot;&quot;,&quot;display&quot;,&quot;width=550,height=100,screenX=&quot;+w+&quot;,screenY=&quot;+h);
newWind.document.write(&quot;<html><head></head><body>&quot;);
newWind.document.write(test);
newWind.document.write(&quot;</body></html>&quot;);
}

<% test = 1 %>
or
<% test = &quot;<img src=images/blah.gif>&quot; %> <insert witticism here>
codestorm
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top