Learn from sources
       Member TSTESCSEQ in CGIDEV2 / QRPGLESRC

       *=====================================================================
       *  RPG ILE MODULE CGIDEV2/TSTESCSEQ
       *
       *  After compiling this RPG MODULE,
       *  create the related program with the following command:
       *
       *  CRTPGM CGIDEV2/TSTESCSEQ MODULE(CGIDEV2/TSTESCSEQ)
       *         ACTGRP(TSTESCSEQ) AUT(*USE)
       *
       *  To execute this program,
       *  enter the following in your WEB browser command line:
       *    http://.../cgidev2p/tstescseq.pgm
       *
       *=====================================================================
       /copy CGIDEV2/qrpglesrc,hspecs
       /copy CGIDEV2/qrpglesrc,hspecsbnd
       /copy CGIDEV2/qrpglesrc,prototypeb
       /copy CGIDEV2/qrpglesrc,usec
       /copy CGIDEV2/qrpglesrc,variables3
       *
      D xrequest        s             10
      D xinput          s             50
       *
      D inpString       s          32767    varying
      D outString       s          32767    varying
       *
      D extHtml         s            500
       * Indicators for GetHtmlIfsMult subprocedure
      D IfsMultIndicators...
      d                 ds
      D  NoErrors                       n
      D  NameTooLong                    n
      D  NotAccessible                  n
      D  NoFilesUsable                  n
      D  DupSections                    n
      D  FileIsEmpty                    n
       * Receive and parse input
       /copy CGIDEV2/qrpglesrc,prolog3
      C                   eval      xrequest =zhbgetvarupper('xrequest')
      C                   eval      xinput   =zhbgetvar('xinput')
       * Load external html
      C                   eval      extHtml=
      C                             '/CgidevExtHtml/tstescseq.html'
      C                   eval      IfsMultIndicators = getHtmlIfsMult(
      C                             %trim(exthtml):'«as400»')
       *
      C                   if        xrequest=' ' and
      C                             xinput=' '
      C                   eval      xrequest='TEST'
      C                   eval      xinput='Van der Meer'
      C                   endif
       *
      C                   eval      inpString=xinput
      C                   eval      outString=UrlEscSeq(inpString)
      C                   callp     updhtmlvar('xinput':xinput)
      C                   callp     updhtmlvar('xoutput':outString)
       *
      C                   callp     wrtsection('top *fini')
      C                   return
0.015 sec.s