| Subject: | Error at line: $xw = new... |  
| Summary: | Package rating comment |  
| Messages: | 4 |  
| Author: | Maykonn Welington Candido |  
| Date: | 2013-10-21 14:31:43 |  
| Update: | 2013-10-22 16:15:42 |  
|   |  
 
 | 
 | 
Maykonn Welington Candido rated this package as follows:
| Utility:  | Bad | 
| Consistency:  | Insufficient | 
| 
 | 
  Maykonn Welington Candido - 2013-10-21 14:31:44  
Error at line: $xw = new emptyObject(); 
Cause emptyObject not exists, not is provided by the package and not is a SPL* class. 
 
*http://php.net/manual/pt_BR/book.spl.php 
  
  Melanie Wehowski - 2013-10-22 11:38:59 -  In reply to message 1 from Maykonn Welington Candido 
What error do you get? 
The whole part is: 
 
if(class_exists('emptyObject')) 
 { 
   $xw = new emptyObject(); 
 }else{ 
        $xw = array(); 
        $xw = (object)$xw; 
      }  
 
So it should work? 
Can you post the error message? 
 
Yo could try to change to  
        $xw = array(); 
        $xw = (object)$xw; 
or  
$xw = new Object() 
  
  Maykonn Welington Candido - 2013-10-22 14:54:05 -  In reply to message 2 from Melanie Wehowski 
No error, sorry, but, this is not necessary, 'cause nobody has the emptyObject ok? 
 
if(class_exists('emptyObject')) 
{ 
    $xw = new emptyObject(); 
}else{ 
    $xw = array(); 
    $xw = (object)$xw; 
}  
 
So the necessary is only: 
$xw = array(); 
$xw = (object)$xw; 
 
It's not wrong, it's just an improvement. 
  
  Melanie Wehowski - 2013-10-22 16:15:42 -  In reply to message 3 from Maykonn Welington Candido 
Ok, your right! 
I will change it soon in the next update. 
Thank you! 
  
   |