PHPExcel not working php 5.2 AppServ -
i using php 5.2.6 in appserv on windows machine , phpexcel not seem work , produces no errors. have error_reporting set e_all.
on linux machine using php 5.6 , using vagrant/homestead same code works fine.
here code: http://pastebin.com/6djc8gap
i added echos see dies, , seems die on line 9. had thought maybe issue php 5.2 , :: referencing, tried using call_user_func, works on php 5.6 not work on php 5.2
http://php.net/manual/en/function.call-user-func.php
<?php namespace foobar; class foo { static public function test() { print "hello world!\n"; } } call_user_func(__namespace__ .'\foo::test'); // of php 5.3.0 call_user_func(array(__namespace__ .'\foo', 'test')); // of php 5.3.0 ?>
per page:
quote:
in php v5.2, /can/ use call_user_func(array($this, 'parent::some_function')).
if don't have custom __autoload() function, go.
if have custom __autoload(), need make `parent' aware. like:
rationale: php 5.2 surprisingly tries autoload class named 'parent'. however, if don't in __autoload() 'parent' class, it'll work fine.
Comments
Post a Comment