PDA

View Full Version : Zipping on command


Tyler
March 1st, 2006, 01:57
I've been trying to figure this out for the past hour or so, but no luck. Instead of posting my bad attempt and making me turn red, let's just say I'm clueless and didn't try it, okay? :lol:

For anyone who owns a vB, or downloaded it before, I need it to be exactly like that. I need it to write a random license number to all the files in a particular spot (the header), and then zip it, but only the PHP files contain the license - in the header.

Then it the file (of the gzip) will be hi_LICENSE#.zip (or .tar). as an example.

And then a cron (this is the part I can handle - I think! :lol: ) will come and clear out the download directory every half an hour.

Anyone have a very simple way to do a rough draft of it so I can build off of that? I've been trying with gzwrite, gzopen etc, but with no luck thus far.

Dan
March 1st, 2006, 20:44
http://phpaudit.com/ :)

Just disable safe_mode and use exec()

Tyler
March 1st, 2006, 20:55
I'm already footing a $300 bill, plus others, I really don't have the money to invest all that much ;)

Plus, I like the freedom of doing things myself and learning off of that.

Can you share about exec(), Dan? I've never did it as its disabled on a lot of servers...

Thanks :)