Send headers before writing data.