Orgs php notice

Some PHP notices... please review.