09 May 2011

call php dr perl coding


contoh nye camni -
wat file test.pl
# cat test.pl
#!/usr/bin/perl
print "This is a perl script\n";
my $output = `php test.php`;
print "This is from PHP:\n$output\n";
print "Back to perl...\n";
exit 0;
next, the test.php script:
# cat test.php
<?php
echo "PHP generated this";
?>
Here's the output of running "test.pl":
# perl test.pl

This is a perl scriptThis is from PHP:
PHP generated this
Back to perl...

0 comments: