adding output buffering and gzip