CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Need a Custom or Prewritten Perl Program?: I need a program that...:
Problem Passing CGI parameters to a Pop-up Window

 



victorlm
New User

Aug 13, 2009, 3:36 AM

Post #1 of 1 (2029 views)
Problem Passing CGI parameters to a Pop-up Window Can't Post

Hello

I have a perl cgi that calls another cgi to show it in a javascript pop up window passing a paramenter. The call to the popup is in a html tag<a> and i have this tag within a loop to print different links calling the pop up with a different values for the parameter .

My problem is when all the links are printed and I click on one of them, the value passed to the popup is always the last value. However if instead of showing the link in a pop up window i show it in another tab, gets the right value.

I've attached the code below:

foreach my $pattern(@patterns){
<script language='JavaScript'>
function newPopup(){

window.open('displayKB.cgi?id=$pattern',
'', 'width=225,height=200,left=900');
}
</script>

<a href='javascript:newPopup()'> LINK </a>
}

Any suggestion?

Thanks

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives