Comment on Tutorial - Execute system commands in a Java Program By Rajan



Comment Added by : Prats

Comment Added at : 2013-02-02 17:33:40

Comment on Tutorial : Execute system commands in a Java Program By Rajan
FILE:- lpton.pl......
...........................................................
#!/opt/lampp/bin/perl
# Parallel port CGI script
#
# Send HTTP headers
print "Content-type: text/html\n\n";
#print "Content-type: text/html\n\n";
#print "Content-type: text/html\n\n";
# Output web page data

print "Parallel port controlled";
print "<a href=\"/Test/index2.html\">Go back to controlling page</a>";

system('/usr/sbin/test 0xff');
.................................................................
This is a script for executing a c program(test) under /usr/sbin/ directory. This script works absolutely fine when this file lpton.pl is executed through command line. But when i try to execute the same file(lpton.pl) through a web server (lampp) only the print statement is getting displayed on browser but the c program is not getting executed....plzz do help me with it......


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. You should show how to implement a custom sorting
View Tutorial          By: AngleWyrm at 2012-12-13 19:35:30

2. i am new to java plz give any sample and simple ja
View Tutorial          By: sham at 2012-03-20 02:30:20

3. thanks,Gud job
View Tutorial          By: junaid sheikh at 2012-11-21 16:24:27

4. i thnk exampleThread example is wrong - like billg
View Tutorial          By: oldman at 2011-09-24 12:32:33

5. i need help in java
View Tutorial          By: arjun tanwar at 2010-02-17 20:58:55

6. How to download any file when a button is in .jsp
View Tutorial          By: Gopesh at 2012-04-13 09:35:11

7. I am new to this concept..It is really very useful
View Tutorial          By: karthiga at 2013-01-02 11:20:38

8. really good
View Tutorial          By: ammu at 2009-11-04 05:07:14

9. Hi,

Are you getting any specific er

View Tutorial          By: Norman Chap at 2008-12-04 02:42:47

10. The example is awesome i found it most useful amon
View Tutorial          By: sabir pasha at 2009-01-20 05:11:34