PHP to install files
<p>I am making a CMS and i would like to make a script that takes a folder like <code>update.zip</code> or something like that. 
what i want is to upload the folder and the code will unpack it then place the files in the location needed.
like.</p>

<pre><code>update.zip
        admin/class/newclass.php
        admin/class/newclass2.php
        admin/css/newlayout.css
        admin/css/newlayout.css
        lib/class/newclass.php
        lib/config/confignew.php
        lib/sql/newsql.php
        includes/name/index.php

site(www.name.com/)
        admin/
        lib/
        includes/
</code></pre>

<p>then i want it to take that then place the files in the zip into the folders that match up and create new folders if not there and replace a file if it exists already.
Does anyone know how i would go about doing it. if you have ideas please help or if you have a PHP Class already i can use that would be nice too. </p>
