Dear Gunnar:

Following your instruction, I ran my cgi under
internet browser Mozzilla and at terminal. However, it
output correctly for terminal(it automatically open vi
editor and open the file "test.pl), but some error
occurred for browser. The following is my result of
the browser.

Thanks a lot, you are really helpful.


Justin

Sequence Generating Page

Using Phrep and Phrap
Author:Justin Zhang. Contact: [EMAIL PROTECTED]

Select the browser button to choose a chromatographic
file to upload. When you press the Process File
button, the sequence will be shown below.
Enter the file to process:
count linescount wordscount characters

main page"test.pl" [readonly]
6L, 95C#!/usr/bin/perl -w print "Content-Type:
text/html\n\n"; print "this is phrap testing file";
~ ~ ~ ~ ~ ~
~ ~ ~ ~ ~ ~
~ ~ ~ ~ ~
Vim: Error reading input, exiting...
Vim: Finished. 
Software error:

'vi test.pl' failed: 256 at
/var/www/cgi-bin/jun06_uploadFile.cgi line 78.

For help, please send mail to the webmaster
([EMAIL PROTECTED]), giving this error message and the
time and date of the error. 

Note: forwarded message attached.



        
                
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
http://promotions.yahoo.com/new_mail 
--- Begin Message --- Xiangli Zhang wrote:
I want to call an application in cgi file, the application runs
when i run the cgi file at terminal (which outputs several files),
but the application called  is not executed in the web browser,
since no files are generated.

<snip>

You should test if the commands were successful!

system(" perl test1.pl");

This is a better way to run another Perl program:

    eval "require 'test1.pl'" or die "Couldn't require test1.pl: $@";

system("phrap fasta1");

system("vi test.pl");

system("phrap fasta1") == 0 or die "'phrap fasta1' failed: $?"; system("vi test.pl") == 0 or die "'vi test.pl' failed: $?";

Please test the above, and let us know if it helped you figure out the
reason why no files are generated when you run the program via CGI.

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




--- End Message ---
-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>

Reply via email to