added encoding, gzip options