Sorry for bringing js into the mix.... Just trying to debug something for someone. Can anyone tell me if there's a quick and dirty way to stop this function producing and popup window? Just want the page to be created in the current browser:
Thanks! Damien ------------------------------------------------------------------------ --------------------------------- var havePopup = false; var popup; function showPack(packName, packSubDir) { if (!havePopup || popup.closed) { // Open new popup popup = window.open('', '', 'toolbar=0,status=0,width=620,height=540'); havePopup = true; } // Open popup for writing popup.document.open("text/html", "replace"); // Write HTML popup.document.write( '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">' + '<HTML lang=en xml:lang="en" xmlns="http://www.w3.org/1999/xhtml">' + '<HEAD>' + '<TITLE>Slide pack: ' + packName + '</TITLE>' + '<LINK href="../includes/css/ns4styles.css" type=text/css rel=stylesheet>' + '<LINK media=print href="styles/print.css" type=text/css rel=stylesheet>' + '<STYLE type=text/css media=all>@import url(styles/styles.css );</STYLE>' + '<SCRIPT language="JavaScript1.3" src="scripts/notices.js"></SCRIPT>' + '<SCRIPT language="JavaScript1.3" src="' + packSubDir + '/slides.js"></SCRIPT>' + '<SCRIPT language="JavaScript1.3" src="scripts/slide_show.js"></SCRIPT>' + '</HEAD>' + '<BODY onload="initialise()" onUnload="closeQuestionPopup()" ' + ' vlink="#333399" alink="#333399" ' + ' link="#333399" onkeydown="keyCapture(window.event);">' + '<TABLE cellSpacing=0 cellPadding=2 width=600 border=0 align="center">' + '<TBODY>' + ' <TR><TD colspan="3" align="center">' + ' <IMG name="slide" alt="Slide" src="" border="0"/>' + ' </TD></TR>' + ' <TR><TD colspan="3" align="center"><FONT size="-3" color="#333399">' + ' <DIV id="Notice"></DIV>' + ' </FONT></TD></TR>' + ' <TR align="center">' + ' <TD align="left" width="25%"><DIV id="goBackward"></DIV></TD>' + ' <TD align="center" width="50%"><FONT color="#333399">' + ' <DIV id="slideNo"></DIV></FONT></TD>' + ' <TD align="right" width="25%"><DIV id="goForward"></DIV></TD>' + ' </TR>' + ' <TR><TD colspan="3" align="center">' + ' <IMG name="logo" alt="Logo" border=0/></TD><TR>' + ' <TR>' + ' <TD align="center"><DIV id="question"></DIV></TD>' + ' <TD align="center"><A href="javascript: closeThisPopup()">' + ' <FONT size="-2">Close window</FONT></A></TD>' + ' <TD align="center"><A href="javascript: self.print()">' + ' <FONT size="-2">Print</FONT></A></TD>' + ' <TR>' + '</TBODY>' + '</TABLE>' + '</BODY>' + '</HTML>' ); // Close popup for writing so first slide of new pack is displayed popup.document.close(); } function closePopup() { // If the popup is open then close it if (havePopup && !popup.closed) { popup.close(); havePopup = false; } } function initialise() { for (i = 0; i < packs.length; i++) { // Set the option text document.forms["packSelect"].elements["packs"].options[i] = new Option(packs[i][0]); // Set the option value to the array index document.forms["packSelect"].elements["packs"].options[i].value = i; } } function newPack() { // Get the index of the selected option var idx = document.forms["packSelect"].elements["packs"].selectedIndex; // Determine the new subdirectory to use and the number of slides var val = document.forms["packSelect"].elements["packs"].options[idx].value; var packName = packs[val][0]; var packSubDir = "packs/" + packs[val][1]; // Open a popup window if necessary showPack(packName, packSubDir); } The original of this email was scanned for viruses by the Government Secure Intranet (GSi) virus scanning service supplied exclusively by Energis in partnership with MessageLabs. On leaving the GSi this email was certified virus-free -- These lists are syncronised with the CFDeveloper forum at http://forum.cfdeveloper.co.uk/ Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/ CFDeveloper Sponsors and contributors:- *Hosting and support provided by CFMXhosting.co.uk* :: *ActivePDF provided by activepdf.com* *Forums provided by fusetalk.com* :: *ProWorkFlow provided by proworkflow.com* *Tutorials provided by helmguru.com* :: *Lists hosted by gradwell.com* To unsubscribe, e-mail: [EMAIL PROTECTED]