I am a metal monkey!
Administrator Community Supporter?
Jedai Sword Master
Gender:
Posts: 5799
46391 credits Members referred : 3
« Reply #1 on: Apr 24, 2008, 06:48:39 am »
Using class variables is good only if you are going to reuse that data in many functions of the class. Otherwise it looks more like spending too much memory.
OMG!I am geek
Posts: 53
406 credits Members referred : 0
« Reply #2 on: Apr 24, 2008, 08:23:27 pm »
yeah the data is going to be used in about 3-4 functions currently, but is there a benefit for using one of them styles to store the data or the other?
Cyberpunk Wannabe
Posts: 34
208 credits Members referred : 0
« Reply #3 on: Apr 25, 2008, 10:31:29 am »
Use mysql_fetch_object if you want the whole set of column data to stick around as a group for processing now or later. Use mysql_result if you only want specific columns, or if you want to process the values in PHP (rather than in SQL) before constructing your object.
Trackback URI for this entry : http://www.webdigity.com/trackback.php?topic=7710