#!/u001/dev/edw/common/ul/bin/perl #---------------------------------------------------- # Author: Saurav Rout #---------------------------------------------------- use Time::Local; use Date::Calc qw(Delta_DHMS); use CGI qw(:standard); use Scalar::Util qw(looks_like_number); use CGI::Carp qw/fatalsToBrowser warningsToBrowser/; my $q = new CGI; my $appname = $q->param('App_name'); my $email = $q->param('Email_id'); my $table = $q->param('Table_name'); open(OUT, ">/tmp/table_list.lst") or die "Couldn't open output file: $ +!"; print OUT $table."\n"; close(OUT); my $cmd = '/u001/dev/edw/common/ul/cgi-bin/car/code_gen.ksh $appname / +tmp/tablelist.lst "$email"'; $result = `code_gen.ksh $appname /tmp/table_list.lst "$email"`; print header; print start_html("Results"); print<<"end_of_html"; <html> <body> <h2>Thank You for using this tool. Your code is on its way to the emai +l id specifed in the previous page.$appname, $email</h2> <h2>Open the JIL file, edit the calendar related values (Date & time), + then upload/move it to unix for futher usage.</h2> <p> Let me know if you see any scope of enhancement in this tool. -S +aurav Rout(Saurav.S.Rout\@google.com) </p> </body> </html> end_of_html print end_html;
In reply to Running a Shell Program from CGI page by sauravrout
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |