Date: | Mon, 29 Aug 2005 12:28:49 -0400 |
From: | "Craig N. Caroon" <ccaroon [...] fastmail.fm> |
To: | bug-php-interpreter [...] rt.cpan.org |
Subject: | PHP::Interpreter bug? |
I have installed PHP::Interpreter. It passed all of the test after I
compiled it. However it is behaving oddly. I have attached 2 files. One
is a perl file called CityTest.pl and the other is a php class call City
in a file called city.php.
Run the CityTest.pl file and read the comments in it for details.
thanks,
-craig
--
Craig N. Caroon
Senior Developer
McClatchy Interactive
(919) 861-1253 (office)
(919) 622-5362 (cell)
ccaroon@mcclatchyinteractive.com
http://www.mcclatchyinteractive.com
#!/nm/sw/perl/bin/perl
use strict;
use PHP::Interpreter;
my $php = PHP::Interpreter->new();
$php->include_once("city.php");
my $city = $php->instantiate("City","Raleigh", "NC");
# Both of these calls return 'NC' or whatever the last param to instantiate() is.
print STDERR $city->getName(), "\n";
print STDERR $city->getState(), "\n";
# This call Seg Faults
$city->setName('Charlotte');
Message body not shown because it is not plain text.