To Execute this Example

LANSA

To Execute this Example
Uploading a File from Windows to iSeries IFSThe Things that Make Up this ExampleBefore You Execute Web Functions

Only before executing for the first time:

You can leave the C program SET181UPLO in the partition module library where it is restored during import or copy it to any library of your choice. In any case, you will have to add a couple of directives in your http configuration file.
  • Stop the IBM HTTP Server and run a LANSA for the WEB cleanup job.
  • Edit your web server configuration file (wrkhttpcfg <cfg name>). Add the following:
MAP /cgi-bin/set181uplo* /QSYS.LIB/<library where SET181UPLO resides>.LIB/SET181UPLO.PGM*
MAP /CGI-BIN/SET181UPLO* /QSYS.LIB/<library where SET181UPLO resides>.LIB/SET181UPLO.PGM*
EXEC /QSYS.LIB/<library where SET181UPLO resides>.LIB/*
MAP /tmp/*/tmp/*
Pass /tmp/*
  • Re-start your web server.
To execute:
Open a browser session.

In the address entry field of the browser type:

http://nnn.nnn.nnn.nnn:xx/CGI-BIN/LANSAWEB?PROCFUN+set_181+set181b+ppp
where

nnn.nnn.nnn.nnnis the IP address of the iSeries you are connecting to
xxis the port number where your web server has been configured to run. If your web server uses the default port 80, this parameter is not required.
ppp is the partition identifier of the partition where you imported the material

Click on the Browse button(s) to select the file(s) you would like to upload.

Specify a valid IFS subdirectory of the root directory you have specified in the data area S_181FUPLO. Refer to the Notes and Suggestions for more information.