DEV Community

Erhan Kılıç
Erhan Kılıç

Posted on


Php ZipMaster - Zip files and folders with php

Hello to everyone. This is my first article. If there are any mistakes, please do not look up.

Compressing files in PHP and creating a zip file is easy, but the situation changes when you include folders into the job. You may want to automatically back up the files on your server like me and you may want to have a solution for it. I have a vps with a lot of sites and I want these sites to be automatically backed up. My solution is to write a script in PHP creates a cronjob.

It is simple to use and you can use it as you like. Please do not hesitate if you want to improve.

Sample use;


include 'ZipMaster.php';

$zip = new ZipMaster\ZipMaster('backup/', 'test_folder');

You can reach the project here.

Latest comments (0)

Timeless DEV post...

Git Concepts I Wish I Knew Years Ago

The most used technology by developers is not Javascript.

It's not Python or HTML.

It hardly even gets mentioned in interviews or listed as a pre-requisite for jobs.

I'm talking about Git and version control of course.

One does not simply learn git