Murlyn Posted June 14, 2008 Share Posted June 14, 2008 I am using the PEAR Spreadsheet_Excel_Writer class and the app that was working on an older server is not working on a server running PHP 5. Im trying to debug the problem and one thing I am seeing right off the bat is that when I do a print on the php 4 class it displays this: spreadsheet_excel_writer_worksheet Object but a print of the PHP 5 class shows this: Spreadsheet_Excel_Writer_Worksheet Object Now is this going to matter in the big scheme of things? or is the problem elsewhere? Quote Link to comment Share on other sites More sharing options...
keeB Posted June 14, 2008 Share Posted June 14, 2008 Problem is elsewhere. Please post the error message you're receiving from the interpreter. Edit: Btw, this belongs in 3rd party scripts, but since it's semi OOP related I won't tell you to go post it there. Quote Link to comment Share on other sites More sharing options...
Murlyn Posted June 16, 2008 Author Share Posted June 16, 2008 Problem is that it exports a blank page instead of an excel sheet. So I am not getting any errors, otherwise I might be able to track down the problem. Im grasping at straws of why this is not working at this point. It's a PEAR module so there are a lot of dependencies. Thankfully I have tracked the problem down to the spreadsheet writer class, but not having luck with figuring out where the problem lies at this point. Any ideas? I have attached the dump of the object, the old.txt is the one that works on a PHP 4.x server and then the new.txt is the one that does not work on the PHP 5.x server. [attachment deleted by admin] Quote Link to comment Share on other sites More sharing options...
Murlyn Posted June 16, 2008 Author Share Posted June 16, 2008 Ok I found one problem. A function is passing an object, but it's not being passed correctly on the PHP 5 server. $worksheet = new Spreadsheet_Excel_Writer_Worksheet($this->_BIFF_version, $name, $index, $this->_activesheet, $this->_firstsheet, $this->_str_total, $this->_str_unique, $this->_str_table, $this->_url_format, $this->_parser); function Spreadsheet_Excel_Writer_Worksheet($BIFF_version, $name, $index, &$activesheet, &$firstsheet, &$str_total, &$str_unique, &$str_table, &$url_format, &$parser) When I echo or print_r the $url_format or the $parser variables in PHP 4 it shows the object, but in PHP 5 it is not showing the object. The variable is actually blank... thoughts? Quote Link to comment Share on other sites More sharing options...
Murlyn Posted June 17, 2008 Author Share Posted June 17, 2008 I removed the & before the function vars, plus a couple other things and it looks like it fixed it. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.