|
One is "dynamic" and one is static. But, since you're hardcoding the URL, they're both pretty similar in that sense. If the URL can change depending different circumstances, then the 2nd method would be the way to go. Brad On Mon, 28 Feb 2005 12:24:10 -0500 MWalter@xxxxxxxxxxxxxxx wrote: > Hello all, > > Can someone explain the difference between this: > > content-type: text/html > <html> > <body> > <script> > self.location="http://192.168.0.2/reports/sls585p.pdf" > </script> > </body> > </html> > > and this: > > /$init > content-type: text/html > <HTML> > <BODY> > <SCRIPT> > /$data > /%docname%/ > /$trailer > </SCRIPT> > </body> > </HTML> > > Using this program: > /copy qrpglesrc,hspecs > /copy qrpglesrc,hspecsbnd > Hdftactgrp(*no) actgrp(*new) > > /copy qrpglesrc,prototypeb > /copy qrpglesrc,usec > > dx S 10i 0 > DsavedQryString S 32767a varying > DhtmlOut S 1000a > DNL C const(x'15') > > /free > > > getHTMLIFS('/htmlTemplates/docopen.html'); > > > wrtSection('init'); > > htmlOut = 'self.location="http://192.168.0.2 > /reports/sls585p.pdf"'; > updHtmlVar('docname':%trim(htmlOut)); > > wrtSection('data'); > > > wrtSection('trailer'); > wrtSection('*fini'); > > *inlr = *On; > /end-free > > Thanks, > > Mark > > Mark D. Walter > Senior Programmer/Analyst > CCX, Inc. > mwalter@xxxxxxxxxx > http://www.ccxinc.com > > -- > This is the Web Enabling the AS400 / iSeries (WEB400) > mailing list > To post a message email: WEB400@xxxxxxxxxxxx > To subscribe, unsubscribe, or change list options, > visit: http://lists.midrange.com/mailman/listinfo/web400 > or email: WEB400-request@xxxxxxxxxxxx > Before posting, please take a moment to review the > archives > at http://archive.midrange.com/web400. > Bradley V. Stone BVS.Tools www.bvstools.com
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.