![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| returning to the parent shell after invoking a script within a script | gurukottur | Shell Programming and Scripting | 5 | 09-26-2006 08:05 AM |
| Invoking Shell Script via php | bubeshj | Shell Programming and Scripting | 2 | 06-30-2006 07:09 AM |
| Invoking shell script from html/jsp page | bubeshj | Shell Programming and Scripting | 2 | 06-28-2006 02:53 PM |
| invoking one shell script from other | ajay xavier | Shell Programming and Scripting | 3 | 05-24-2006 04:39 AM |
| How to run unix commands in a new shell inside a shell script? | hkapil | Shell Programming and Scripting | 2 | 01-04-2006 06:56 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Hi,
I have an HTML form through which I get some text as input. i need to run a shell script say script.sh inside a perl-cgi script named main_cgi.sh on the form input. I want to write the contents of the form in a file and then perform some command line operations like grep, cat on the text and thn output the result as HTML. I am not able to find out what's gone wrong with the script. I am not able to write the text in the file and also the script.sh is not working. The scripts are as following - #!/bin/sh # main_cgi.sh eval `proccgi.sh $*` echo "Content-type: text/html" echo echo "<HTML>" echo "<BODY>" echo "<center>" echo "<H1>Results </H1>" echo "$FORM_seqinput" |tr '\015' '\012' >file_1 echo "<br><br><H3><fontcolor = #800000>" echo " 'cat file_1' " ./script.sh if test -s res.out then echo "<br><br><H2><fontcolor = #000080>" echo " 'cat res.out' " fi echo "</font></H3><br>" echo "</center>" echo "</BODY>" echo "</HTML>" #!/bin/sh # script.sh cat file_1 | wc -l >res.out I will be thankful for your suggestions. Smriti |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|