eXept Software AG Logo

Smalltalk/X Webserver

Smalltalk Dynamic Web Pages - Source of WebDemoApp1-test4:

Home

Documentation
www.exept.de
Everywhere
for:
test4:aRequest
    "another dialog form

     Invoke via the browser as URL:
        host:port/<N>,test4:
     where <N> is the registered name of this service.
    "
    |replyPresenter|

    replyPresenter := aRequest replyPresenter.
    replyPresenter title:'Another Dialog form'.
    replyPresenter parametersAt:#secondHeadLine put:'Test4: Another Dialog form'.
    aRequest
        nextPutLine:'<h1>Enter values</h1>';
        nextPutLine:'This is a dialog test';
        nextPutAll:'The following forms contents is executed as unix command,';
        nextPutLine:'and the result presented in another page.<p>';
        nextPutLine:'For security reasons, only a very limited set of commands is allowed (such as "ls", "pwd" or "date").<p>';
        nextPutLine:'<FORM action="', (aRequest linkIdFor:self selector:#'test4Action:'), '" method=POST>';
        nextPutLine:'Script: <input name="scriptName" size=15 value="ls"></input><p>';
        nextPutLine:'Arg1: <input name="arg1" size=15 value="-l"></input><br>';
        nextPutLine:'Arg2: <input name="arg2" size=15 value=""></input><br>';
        nextPutLine:'Arg3: <input name="arg3" size=15 value=""></input><p>';
        nextPutLine:'Press <input type=submit value="Execute"></input> to execute the above as unix command ...<br><br>';
        nextPutLine:'</form>'.

    self addLinksForSource:#'test4:' previous:#'test3:' next:#'test5:' to:aRequest.

    "Modified: / 20-11-2017 / 20:09:33 / mawalch"

Edit (disabled)
Index


ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Sat, 21 Dec 2024 16:05:59 GMT