The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
.
google unix.com



UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
script to capture certain output fara_aris Shell Programming and Scripting 18 08-15-2008 12:07 AM
script to capture aboorkuma Shell Programming and Scripting 5 07-03-2008 02:14 AM
not able to capture STDOUT aks__ UNIX for Dummies Questions & Answers 5 04-25-2008 04:12 AM
Script Output Woes (stdout?) c0nn0r Shell Programming and Scripting 2 07-09-2006 06:22 PM
Capture output from interactive script MizzGail Shell Programming and Scripting 6 04-04-2002 06:24 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 11-10-2008
kittu1979 kittu1979 is offline
Registered User
  
 

Join Date: May 2008
Posts: 11
How to capture STDOut of script in a CGI script?

Hi Perl Experts,
I am invoking a shell script thru a perl script and the perl script is cgi script.I need to capture the STDOUT of the shell script in the html page where I am invoking the script .?The shell script takes couple of mintutes to complete its execution .Mean while my html page does not show any thing.I want to display the STDOUT of the shell script in the html page.

Thanks
  #2 (permalink)  
Old 11-10-2008
wempy's Avatar
wempy wempy is offline
Registered User
  
 

Join Date: Jun 2006
Location: Harpenden, UK
Posts: 208
if you are executing the external script by backticks then just capture the output into a variable, and print that variable.
system() does not return the external programs output, just it's exit code
exec() does the same as system, and never returns
use backticks.
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 01:45 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0