So I needed to make a class of some sort in order to decompress ZIP files, that way when SnowCMS gets updated (later on...

) the system can download the ZIP, extract it, and put the files in the right place.
There was an issue, not all systems have the ZIP plugin enabled for PHP, so I needed to make my own... There was the option of PEAR classes, but the class was 118KB. 118KB just to extract a ZIP? I don't think so

I also thought of making my own ZIP extractor, but I haven't been able to find too much information about that, lol.
So I decided, why not make my own? And I did! I made a class which compresses and extracts what I call an SGZ (SnowCMS GZip, such a cool name, right?). I have compared it to ZIP's and tar.gz's, they are all about the same size

I have attached the class below, if you want to check it out. I will add how you use it (though you should be able to figure it out by looking at the documents) soon, but I will give a bit of information on how it is structured.
Firstly, SGZ is the first part of the file, just like with a ZIP, it is PK. Then the next 4 bytes contain the number of directories to create, for that length, there will be another 4 bytes which contain the length of the directories name, after that name, there could be another 4 bytes which contain another directory length, unless you have read the specified amount of folders

After that, you will basically have the same setup, but this time with files. So another 4 bytes which contain the number of files which will be extracted. Then, once again, for the amount of files, read 4 bytes which contain the files name length (which contains the path, of course, if any), read that, then another 4 bytes which contain the compressed datas length, read the data, gzinflate it, and put it where it needs to go.
Pretty simple really XD. I might change the structure a bit soon, and I might even change it completely. I was thinking of doing a tarball type setup, but without the tarball crap. With tarball it saves certain file attributes, which I know do have benefits, but when you just want to send multiple files in a single, compressed package, who cares? It certainly won't matter with SnowCMS updates.
Then I suppose there could be two available updates for systems, one which have Zlib enabled ("tarballed" and gzdeflate), and those that don't, so just "tarballed", which would definitely be bigger, but still allow updating without them having to do anything other than clicking "Update!"
