php func to convert html to array