egis egis - 5 months ago 9x
PHP Question

php object attribute with dot in name

I have mysql table with collumns like '', '' and etc.
After fetching that table data as object with

i get this (print_r of row):

stdClass Object
[id] => 2
[] => 2010-12-15
[] => some_name

how do I acces
and all other weirdly named object properties?

rik rik

Specify aliases in your SQL query like SELECT column AS nameWithoutDots ...
or access these properties with $object->{''}
or cast the object to array like this: $obj = (array)$obj; echo $obj[''].