Updated code to match php 5.3 syntax