milliken has asked for the wisdom of the Perl Monks concerning the following question:
I have written a Perl CGI script that takes a search string from the user, searches for the string in an index file of documents, and returns an HTML page of results. The posted results are links to matching documents, and the user is to be given a choice of which of these documents he wants to retrieve. Clicking on a link should popup the Open Document window that offers the user the choice of opening the document with the appropriate application, or else Saving the document. The problem is that when the links are posted on the results page, no action takes place when the user clicks on a link. BUT - if I save the generated page source into a file and then open that file, it works just fine.
Here is a sample of the generated HTML code:
<TD align=left><a href="file:/net/server/Docs/doc03.pdf">pdf</a></TD>
Here is the HTML code that invokes the Perl CGI script:
<FORM ACTION="/cgi-bin/swin_search.cgi" METHOD=POST> <B>Search string:</B> <INPUT type=text NAME=Query1 SIZE=35 MAXLENGTH=100> <BR><BR> <INPUT type=submit value=" RETRIEVE SEARCH RESULTS "> <INPUT type=reset value=" CLEAR "> </FORM>
And if it's of any use, here are the opening lines of the Perl script:
require 5.003; use CGI qw( :standard :html3 );
Thanks for any eye-opening pointers.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Can't get Open Document popup window to appear
by Corion (Patriarch) on Sep 22, 2011 at 20:00 UTC | |
by milliken (Initiate) on Sep 23, 2011 at 17:42 UTC | |
by Corion (Patriarch) on Sep 23, 2011 at 18:30 UTC | |
by milliken (Initiate) on Sep 23, 2011 at 21:29 UTC | |
by Corion (Patriarch) on Sep 23, 2011 at 21:59 UTC |