|
Hi Scott,
> the apache config tells the browser where to find the file, not > windows networking. You're right, sorry about that. One of your examples started the path with two leading slashes (//webdirectory/pdfs/mypdffilename.pdf), and that confused me, but you're right, unless it was accessed as a file: URI, this wouldn't be interpreted as Windows networking, since it's part of a relative link.
if I had a double slash somewhere, that was an error in my interpreting the code from memory, not what it actually did. I build the field that contains that path using cgi path elements from a control file and the pdf file name I created. the actual number of slashes was embedded in those fields.
However, it's still just a link to the document. A Location: header would do the same thing without Javascript.
I'm not familiar with the Location: header technique, but I'm not sure what you mean by it being just a link to the document. It's my assumption that he's creating these pdfs on the fly - based on selection criteria prompted from a browser. when the user hits the submit button, the cgi runs, generates the report and converts it to pdf. now the user needs to see it, so my solution automatically opens a browser window with the pdf file's path and name already embedded. So, the user presses submit, and the next thing he sees is the report pdf in a new window. how is that just a link to the pdf?
I thought Jim wanted to send the PDF/HTML document directly from his CGI program without providing a link to it. For example, if you wanted to use the program to secure the document, you wouldn't want there to be any way that a user can link directly to it, you'd want to require access to only be done through the program.
Ah, I think I see what you're saying - he wants them to download the document locally. well, that would be a different thing altogether.
What I don't understand, however, is why you'd write it to the IFS at all. But perhaps I'm dwelling too much on that point, and should be demonstrating the solution instead of dwelling on "why IFS".
I'm not sure I'm understand where you're going here. If all you are looking for is just a web inquiry, then writing the report results in HTML is certainly an option. But if you want to print the output, html reports are not printer friendly, pdfs are. So, I'm not aware of any way of generating a pdf from an RPG file without writing a spool file first. Is that what you're saying? that he can write directly from RPG to pdf format? Rick
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.