PHP: can't figure this out

Gooberlx2

Lifer
May 4, 2001
15,381
6
91
I'm making a dynamic zip file see here for people to download using, and everything works fine until the actual file download where ".php" keeps getting added on to the end of the file.

header("Content-type: application/octet-stream");
header("Content-disposition: attachment; filename=images.zip");
echo $zipfile -> file();

everytime I click to download the file it's named as images.zip.php. If I rename the extension after download everything is fine....but it's an annoyance. Any ideas?
 

Gooberlx2

Lifer
May 4, 2001
15,381
6
91
nevermind i just changed application/octet-stream to application/zip.....I didn't think I should have to do that though....oh well