Write header.