Added PHP compatibility