Fixed issue with ids in PHP classes