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

Popup windows in javascript and Perl

Status
Not open for further replies.

burningicarus

Programmer
Joined
Jan 30, 2006
Messages
1
Location
AU
Hi,

I'm constructing a page in Perl, and would like clicking on thumbnail images on the parent window to result in a daughter popup displaying the full size image.

I can achieve this using the following (messy) javascript.

However, for database management reasons, I like to find the equivalent code in Perl. After 5 days of hacking away at this, I'm not really getting anywhere. Any help would be great :)

$link = "<a href=\"javascript:$unique_javascript_name();\"><img src=\"popupButton4.jpg\"</a>";

$popup_script ="

<script>

var newwindow;
function $unique_javascript_name(url)
{

var generator=window.open(\'\',\'$unique_link_name\',\' scrollbars=yes resizable=yes\');
generator.document.write(\'<html><head><title>My Webpage! </title></head>$html_body2<img src = $picture></body></html>\');
generator.document.close();

}

</script>
 
Show what the final HTML output is. It's difficult to tell what's wrong from the small amount of script you've provided, and by seeing what your script produces, we can get a better idea what's wrong.

Lee
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top