Fix PHP notices

Fix some PHP notices...

@joe #review #merge