|
A Simple Form Handler
Here's a very simple form handling CGI application running in Frontier.
To try it out, enter your name in this text field and click on OK:
Listing
Here's what the source looks like:
on formHandler (adrParams) |
 | local (htmltext = webServer.httpHeader ()) |
 | on add (s) |
 | htmltext = htmltext + s |
 | local (greeting = "Hello " + adrParams^.argtable.username) |
 | add ("<html>\r") |
 | add ("<head>\r") |
 | add ("<title>" + greeting + "</title>\r") |
 | add ("</head>\r") |
 | add ("<body>\r") |
 | add ("<h2>" + greeting + "</h2>\r") |
 | add ("</body>\r") |
 | add ("</html>\r") |
 | return (htmltext) |
|