Replacing php4 object notation to php5.3