php 5.2 compatability updates