What I've found out is that I can download a file and open it using an application. The window that pop's up must be used by the application ie: MS Word for an RTF. But when I save to file, it will in fact save, but I have an extraneous window. I did read someplace the window may need to pop up, but it could be a hidden window. This would be ok since I could track the hidden window and close it without the user ever seeing it. But I don't know how to do a hidden window either.<br><br>Here's what I have...<br><br><html><br><head><br>.<br>.<br>.<br></head><br><body><br>.<br>.<br>.<br><script language="JavaScript"><br><!--<br>var path;<br>var ext;<br>var win1;<br>var title = "Course Description";<br>var detail = "width=515,height=315,resize=no,scrollbars=no";<br><br>function dfn(pt,ttl,dtl)<br>{if(ext == ".rtf" ¦¦ ext == "c.rtf"

<br> {open(pt); //This is the line I'm having problems with.<br> win2 = pt.open;}<br> else<br> {win1=window.open(pt,ttl,dtl);}<br>}<br><br>//This function helps derive the variable with which I<br>// eventually concatenate with in the javascript URL below <br>//to form the URL from where I want to download.<br><br>function dothis()<br>{<br> {if (document.forms[0].elements.dowhat[0].checked == true)<br> {path="coursedesc/";<br> ext=".htm";}<br> else if (document.forms[0].elements.dowhat[1].checked == true)<br> {path="mastersyllabii/";<br> ext=".pdf";}<br> else if (document.forms[0].elements.dowhat[2].checked == true)<br> {path="coursesyllabii/";<br> ext="c.pdf";}<br> else if (document.forms[0].elements.dowhat[3].checked == true)<br> {path="mastersyllabii/";<br> ext=".rtf";}<br> else <br> {path="coursesyllabii/";<br> ext="c.rtf";}<br> }<br>return path,ext;<br>}<br>// --><br></script><br>.<br>.<br>.<br>Some HTML<br>.<br>.<br>.<br>The following are the radio buttons with which the user selects what he/she wants to do.<br><br><form method="post"><br> <table width="100%" border="0"><br> <tr><br> <td width="50%" valign="top"> <br> <p><font face="Arial, Helvetica, sans-serif" size="2" color="#004C00"> <u>View</u><br><br> <input type="radio" name="dowhat" onclick="form.dowhat.value='viewd';" value="viewd" checked><br> Course Description and Learning Outcomes<br><br> <input type="radio" name="dowhat" value="viewm" onClick="form.dowhat.value='viewm';"><br> Master Syllabus (Acrobat Reader Required)<br><br> <input type="radio" name="dowhat" value="viewc" onclick="form.dowhat.value='viewc';"><br> Course Syllabus (Acrobat Reader Required) <a href="<A HREF="
TARGET="_new">
src="images/getacro.gif" width="88" height="31" alt="Acrobat Reader" border="0" align="top"></a></font></p><br> </td><br> <td width="50%" valign="top"><font face="Arial, Helvetica, sans-serif" size="2" color="#004C00"> <u>Download</u><br><br> <input type="radio" name="dowhat" value="dwnldm" onclick="form.dowhat.value='dwnldm';"><br> Master Syllabus (RTF Format) <br><br> <input type="radio" name="dowhat" value="dwnldc" onclick="form.dowhat.value='dwnldc';"><br> Course Syllabus (RTF Format) <br><br> </font></td><br> </tr><br> </table><br></form><br><table><br>.<br>.<br>.<br> A bunch of table rows with javascript URL's<br> similar to the one below. What I am doing here is:<br> Checking to see if popup win1 exists, then closing it if it does.<br> Call function dothis() to generate the path and extension portions of the URL.<br> After returning from dothis(), I call function dfn() which calls the popup, views the pdf, or downloads the rtf based on user input (the radio buttons)<br>.<br>.<br>.<br><br><tr> <br> <td width="48%" height="24"> <br> <div align="left"><a href="javascript:;" onclick="javascript

(win1)?win1.close():x=1);dothis();(dfn(path+'m106'+ext,title,detail))"><br> <font face="Arial, Helvetica, sans-serif" size="2" color="#004C00">MET 106 Survey of Commercial HVAC Systems</font></a></div><br> </td><br> <td width="4%" height="24"> </td> (Blank Cell)<br> <td width="48%" height="24"> <br> Another javascript URL<br> </td><br> </tr><br>.<br>.<br>.<br>Rest of Table<br>.<br>.<br>.<br></table><br></body><br></html>