in reply to CGI running local shell scripts

Way to completely sidestep the issue, people. minixman, ignore those pedantic wretches who never really attempted to answer your question. To rebuke their points, it is fine to hardcode HTML with here documents in small cases like this if you want to. For larger projects, use the tools they suggested. In answer to your question, the simplest way to do this would be to grab the command param, then wrap it in qx//, assigned to a variable, then print this variable in your here document. A better way would be to have a set of subroutines that handle allowed user commands, parsing out relevant information and adding formatting tags as appropriate to your wants prior to printing.

Replies are listed 'Best First'.
Re: Re: CGI running local shell scripts
by minixman (Beadle) on Jul 17, 2003 at 13:24 UTC
    Thanks for the information
    i have put the command into a variable like

    $runcomand = `vmstat 5`;
    then tried to print the output, just via print but it does not print it