Updated php functions (Godaddy ready)