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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

javascript & ASP

Status
Not open for further replies.

jvande

MIS
Jun 6, 2001
115
0
0
US
I have a window that calls a popup window. Here is the javascript for the openwindow function.


function openWindow()

{var newWind=window.open(&quot;image_upload.asp?PIctureID=<% Response.Write picID %>
&quot;,&quot;display&quot;,&quot;width=550,height=100,screenX=&quot;+w+&quot;,screenY=&quot;+h);

Now you can see that I am trying to pass picID with asp <% Response.Write picID %>. But this doesn't work. How do I pass PicID to this new window. Also once I close that popup window is there a way to force my main window to refresh?

Thanks Guys
Josh
 
hi,

i think this will work and check it out. actually response.write method is just write into the explorer. cant assign like u did.

function openWindow()
{
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);

windowname.refresh() - is there. use that
 
hi,

i think this will work and check it out. actually response.write method is just write into the explorer. cant assign like u did.

function openWindow()
{
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);

windowname.refresh() - is there. use that

by
lenin
lenin_28@yahoo.com
 
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


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top