Web lists-archives.com

Re: [PHP] Missing something ...




On 28/12/15 19:03, David Harkness wrote:
>> On 27/12/15 16:52, Aziz Saleh wrote:
>>> > > What does get_class_methods give you? Does it list those functions part
>> > of
>>> > > of the list?
>> >
>> > Good point ...
>> > Fatal error: Call to undefined method GedcomRecord::get_class_methods()
> 
> get_class_methods [1] is a global function--not a method. Pass it the name
> of the class to inspect.
> 
>     print_r(get_class_methods('GedcomRecord'));
> 
> Note that I passed 'GedcomRecord' instead of 'Person' because that's what
> PHP says you have in the error message. You're trying to call
> GedcomRecord::getChildFamilies(). If Person::getInstance() returned a
> Person instance, the error message would read
> 
>     Fatal error: Call to undefined method Person::getChildFamilies()

Actually the problem was a little easier to solve after I realised that
'GedcomRecord' class HAD been created. Turns out the PDO query which
SHOULD have provided the switch to select Person class was padding the
result with spaces. Not found out yet why THAT is broken, but an extra
'trim' and everything started working again. Have other faults that have
also been identified as PDO related, so currently restoring the ADOdb
version which is live on the production sites. Some of these
'improvements' in PHP are simply a complete waste of time :(

-- 
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk
Rainbow Digital Media - http://rainbowdigitalmedia.co.uk

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php