Ewart,
Then perhaps the following is a possible scenario.
Present the user with a web page on which they enter a DB2 file name.
The user submits this page which is able to invoke a call to a program to generates a csv file from the DB2 file.
The name of the generated file (random or otherwise) is then returned to the user as a static link on the response page.
The user clicks the link which causes the browser to download the csv file at which point the browser offers the choice to either open or save the file.
The could be a nightly job which subsequently clears the download folder.

Peter

-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx] On Behalf Of ewart.desouza@xxxxxxxxxxx
Sent: Saturday, 19 June 2010 4:04 p.m.
To: Web Enabling the AS400 / iSeries
Cc: 'Web Enabling the AS400 / iSeries'; web400-bounces@xxxxxxxxxxxx
Subject: Re: [WEB400] PHP to download any iSeries file in XL format to the local directory

Hello Peter,

The idea is to use the Zend setup which connects to the iSeries. So the
user will be asked to enter the file & library names, which will then be
converted into a CSV file (using a CL program) now that file should be
downloaded to their local PC - which is the issue (hopefully there is a
way).

Thanks & best regards
Ewart



Peter Connell

From:
Peter Connell <Peter.Connell@xxxxxxxxxxxxxxxxx>


To:
"'Web Enabling the AS400 / iSeries'" <web400@xxxxxxxxxxxx>


Cc:



Date:
06/19/2010 09:14 AM


Subject:
Re: [WEB400] PHP to download any iSeries file in XL format to the
local directory



Ewart,
Generating a csv file (column headings included) for import from an IFS
folder can be achieved with just a couple of lines in a CL program.
Allowing files in a folder to be served directly via the web is also
straight forward Apache rule.
The more important issue is how the web user is provided with the link for
a specific csv file that has just been generated from a DB2 file and
whether access to files in the folder is intended to be restricted.
How would you intend to initiate a process which generates the file to be
downloaded?
If you have a mechanism for sending an email from the CL program that
generates the file then you could embed the link to the file in the email.

Peter


-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx] On
Behalf Of ewart.desouza@xxxxxxxxxxx
Sent: Saturday, 19 June 2010 3:02 p.m.
To: Web Enabling the AS400 / iSeries
Cc: web400-bounces@xxxxxxxxxxxx
Subject: Re: [WEB400] PHP to download any iSeries file in XL format to the
local directory

Hello Brian,

These are for ad-hoc requirements i.e. output of queries that the users
can download on their own through a web interface. It should go to their
directory so we need to give them the provision to select the path. To
make things easier even opening the XL will do so that they can save it
wherever they want using standard XL..

Even a CL program that can send the XL file to their local PC
('localhost') & to a fixed folded ('Temp') will do. I'll have to search
the net for that or try out on my own.

Thanks & best regards
Ewart


BMay

From:
BMay@xxxxxxxxx


To:
Web Enabling the AS400 / iSeries <web400@xxxxxxxxxxxx>


Cc:



Date:
06/18/2010 07:15 PM


Subject:
Re: [WEB400] PHP to download any iSeries file in XL format to the local
directory



Is this an automated process, or is it something the user requests via a
website, or maybe requested from a 5250 program?

Does it really need to go to a directory on the end user PC or should it
just open up in excel automatically?

Brian May
Project Lead
Management Information Systems
Garan, Incorporated
Starkville, Mississippi



ewart.desouza@xxxxxxxxxxx
Sent by: web400-bounces@xxxxxxxxxxxx
06/17/2010 09:37 PM
Please respond to
Web Enabling the AS400 / iSeries <web400@xxxxxxxxxxxx>


To
Web Enabling the AS400 / iSeries <web400@xxxxxxxxxxxx>
cc
web400-bounces@xxxxxxxxxxxx
Subject
Re: [WEB400] PHP to download any iSeries file in XL format to the local
directory






Thanks Kelly & the rest who responded,

I do the conversion into XL on the iSeries itself which means I only need
to copy the file from the IFS to the local PC. Since I'm new to PHP this
will be my first project.

I wouldn't want to get started on a 'fading' Net.Data just for this -
which is why I prefer PHP.

Thanks & best regards
Ewart




Kelly Cookson

From:
Kelly Cookson <KCookson@xxxxxxxxxxxx>


To:
Web Enabling the AS400 / iSeries <web400@xxxxxxxxxxxx>


Cc:



Date:
06/18/2010 01:14 AM


Subject:
Re: [WEB400] PHP to download any iSeries file in XL format to the local
directory



If you search the Internet, you can find PHP classes and packages that are



used to create Excel files. Here are a few examples:

http://phpexcel.codeplex.com/
http://sourceforge.net/projects/psxlsgen/
http://www.codediesel.com/php/creating-excel-documents-in-php/
http://www.mt-soft.com.ar/2007/12/21/xls-php-class/

I'm not endorsing any of the above, and you should search for yourself to
see if something looks better for your needs.

I also don't know if all the classes and packages will work in a
Zend-on-i5 environment. They should. But I haven't tested any of them.

You should be able to develop a PHP utility that combines your own PHP
code with a PHP Excel package to read a DB2 table, get the column
headings, and produce an Excel file.

Kelly Cookson
Senior Programmer/Analyst
Dot Foods, Inc.
217-773-4486 x12676
www.dotfoods.com

-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx] On
Behalf Of ewart.desouza@xxxxxxxxxxx
Sent: Thursday, 17 June 2010 5:42 p.m.
To: web400-bounces@xxxxxxxxxxxx; web400@xxxxxxxxxxxx
Subject: [WEB400] PHP to download any iSeries file in XL format to the
local directory

Hello All,

Do you know if anyone has create a utility in PHP to download any iSeries
file in XL format to a local directory ??

We usually do this in XL itself but only the field names & not the field
headings appear. Some users do not have this facility which is why I was
planning on developing a web based PHP utility.

Thanks & best regards
Ewart
This e-mail is confidential and it is intended only for the addressees.
Any review, dissemination, distribution, or copying of this message by
persons or entities other than the intended recipient is prohibited. If
you have received this e-mail in error, kindly notify us immediately by
telephone or e-mail and delete the message from your system. The sender
does not accept liability for any errors or omissions in the contents of
this message which may arise as a result of the e-mail transmission.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.