Quick question about ASP and Javascript

Results 1 to 3 of 3

Thread: Quick question about ASP and Javascript

  1. #1

    Default Quick question about ASP and Javascript

    hi guys.<BR><BR>I&#039m trying to pass a url string which has some asp generated variables in it to javascript onclick method.<BR><BR>when the person clicks the link, that information to be sent to javascript code in the head and open up a window that has no tool bar. Any ideas ?? <BR><BR>I figure that my javascript link would look kinda like this.<BR><BR>&#060;A href="javascript.popUp(&#039http://www.domain.com/page?name=&#060;%=whatever%&#062;&#039)<BR><BR>the n in the head i&#039m kinda confused. i think it would be something like <BR>function popUp(url) {<BR>props=window.open(url, &#039toolbars=0, scrollbars=0, width=300, height=0&#039);<BR>}<BR> what do you guys think ?? looks good ?

  2. #2
    stephen of ny Guest

    Default RE: Quick question about ASP and Javascript

    i&#039m just getting errors and the windows debugger opens up. so i tried typing the javascript code like this instead.<BR><BR>in the HEAD I have:<BR>function popUp(URL){<BR>var windowsprops = "height=500, width=500, location=no,"<BR>+ "scrollbars=no, menubars=no, toolbars=no,resizable=yes";<BR>popup= window.open(URL, "MenuPopup", windowprops);<BR>}<BR><BR>of course surrounded by script language ="javascript" and /script. and the html comment out tags.<BR><BR>In the body I have <BR>&#060;A HREF="Javascript:popUP(&#039asppage.asp?id=&#060;% =id%&#062;&#039)"&#062;click&#060;/a&#062;

  3. #3
    stephen of newyork Guest

    Default never mind i figured it out

    never mind i figured it out.you have the reference the entire url starting with http:// you can&#039t use relative urls in those type of javascript things<BR>But yes it does pass the asp info properly

Posting Permissions

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