title: moving files around different sub domains
body: <p>I am currently working on a quite a big project for a client and one of the things that they want is to be able to create new isntances of their software on different sub domains and each using its own database, they want to be able to do this in the most automated way possible. A quick overview of the way a new isntace created is:</p>
  
  <ol>
  <li>A new sub domain is created by one of their administrators by going into thier 123-reg control panel</li>
  <li>A new database is created by one of their administrators by going into their 123-reg control panel</li>
  <li>They login to an centeral admin panel and fill in a form which then copies over a zip file of the software to the new sub domain and unzips it.</li>
  <li>The script then edits the database connection class with the database infromation supplied in the form.</li>
  <li>The script then checks the connection and creates the tables</li>
  <li>Finally the admin database is updated with the instances new information.</li>
  </ol>
  
  <p>The problem I am having is moving files around different sub domains. For instance the admin panel is at <code>admin.website.com</code> and as an example a new instance might be located at <code>instance.website.com</code> no matter what I try I cannot get a file to move to a different sub domain... Does anyone have a solutions to this? For anyone wondering the directory structure is like so:</p>
  
  <ul>
  <li>/public_html/admin/</li>
  <li>/public_html/instance/</li>
  <li>/public_html/instance_2/</li>
  </ul>
  
  <p>etc.</p>