foreach else added and numbers parse fixed