It is a PHP problem.

You create your CleanData instance with:

$cln = new CleanData;

Then you try to run the method CleanObject with:

return $clean->CleanObject($info);

$clean is not an object instance ($cln is the instance).

--- In flexcoders@yahoogroups.com, "timgerr" <[EMAIL PROTECTED]> wrote:
>
> Does anyone know if this is a weborb or a php problem?
> 
> Thanks,
> timgerr
> 
> --- In flexcoders@yahoogroups.com, "timgerr" <tim.gallagher@> wrote:
> >
> > Hello all, I am using weborb and getting this error but I am not sure
> > it is a weborb problem.  I have a class CleanQueryClass.php
> > class CleanData {
> > public function CleanObject($obj) {
> >             
> >                     $n = new stdClass;
> >             foreach($obj as $var => $value) {
> >                             // Stripslashes
> >                             if (get_magic_quotes_gpc())
> >                             {
> >                                     $value = stripslashes($value);
> >                             }
> >                             // Quote if not integer
> >                             if (!is_numeric($value) || $value[0] == '0')
> >                             {
> >                                     $value = 
> > mysql_real_escape_string($value);
> >                             }
> >                             $n->$var = $value;
> >                     }
> >                             return $n;
> >             }
> > 
> > }
> > 
> > I call this class from another class UserAuthenicate.php:
> > class UserAuthenicate {
> >     public function HandShake(SB $info)
> >     {
> >             require_once('CleanQueryClass.php');
> >             $cln = new CleanData;
> >             return $clean->CleanObject($info);
> >     }
> > }
> > class SB{
> >     var $userName;
> >     var $password;
> >     var $status;
> >     
> > }
> > 
> > 
> > When I communicate to UserAuthenicate.php with a weborb remote object
> > I get an error in flex, server didnt respond (somthing like that) I
> > look in charles and I see this:
> > <b>Fatal error</b>:  Call to a member function CleanObject() on a
> > non-object in
> >
>
<b>C:\xampp\htdocs\weborb\Services\dnt\Authenicate\UserAuthenicate.php</b>
> > on line <b>12</b><br />
> > 
> > Can someone tell me what I am doing wrong?  I am passong an object to
> > the class method.
> > 
> > Thanks,
> > timgerr
> >
>


Reply via email to