Req #80068 [NEW]: Feature request magic methods

From: Date: Mon, 07 Sep 2020 04:38:25 +0000
Subject: Req #80068 [NEW]: Feature request magic methods
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-228908@lists.php.net to get a copy of this message
From: peter dot quinn at optushome dot com dot au Operating system: PHP version: Irrelevant Package: Class/Object related Bug Type: Feature/Change Request Bug description:Feature request magic methods Description: ------------ A toNumeric(), toArray, toObject would be handy so can cast an object in different ways. Eg, If I had a object which had the queried result set from a database query within a private member, then could use toString() to display the current row as say a HTML version of it, use toArray to return the current row as an array, and use toObject to return the current row as an object. -- Edit bug report at https://bugs.php.net/bug.php?id=80068&edit=1 -- Fix committed: https://bugs.php.net/fix.php?id=80068&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=80068&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=80068&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=80068&r=needscript Try newer version: https://bugs.php.net/fix.php?id=80068&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=80068&r=support Expected behavior: https://bugs.php.net/fix.php?id=80068&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=80068&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=80068&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=80068&r=globals PHP version support discontinued: https://bugs.php.net/fix.php?id=80068&r=phptooold Daylight Savings: https://bugs.php.net/fix.php?id=80068&r=dst IIS Stability: https://bugs.php.net/fix.php?id=80068&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=80068&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=80068&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=80068&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=80068&r=mysqlcfg

« previous php.bugs (#228908) next »