title: Generate xml file from Laravel template
body: <p>I have a <a href="http://laravel.com/" rel="nofollow">Laravel</a> template and I want to generate an XML file depending on it.</p>
  
  <p>For example, the structure has a name, XPath and type. So the XML should look like this: </p>
  
  <pre><code>&lt;name&gt;
  &lt;/name&gt;
  &lt;type&gt;
  &lt;/type&gt;
  &lt;xpath&gt;
  &lt;/xpath&gt;
  </code></pre>
  
  <p>Of course I am looking for something more complex that can deal with relationships.</p>
  
  <p>Is there any tool for that?</p>
  
  <p>I am using MySQL, so maybe there is a tool for that, too? Or maybe a PHP script?</p>
  
  <p>I already tried to search and all I have found is a tool to generate HTML forms from XSD and general XML from XSD.</p>
  
  <h3>Update </h3>
  
  <p>The tables and their columns are:</p>
  
  <ol>
  <li><code>xml_document</code> table with columns: <code>id</code></li>
  <li><code>general_information</code> table with columns: <code>id</code>, <code>xml_document_id</code>, <code>domain</code>, <code>start_url</code> and `category </li>
  <li><code>master_information</code> table with columns: <code>id</code>, <code>xml_document_id</code>, <code>container</code>, and <code>next_page</code></li>
  <li><code>master_attribute</code> table with columns: <code>id</code>, <code>master_information_id</code>, <code>name</code>, <code>xpath</code>, and <code>type</code></li>
  <li><code>details_attribute</code> table with columns: <code>id</code>, <code>xml_document_id</code>, and <code>type</code></li>
  </ol>
  
  <p>As you may notice, the relationships between:</p>
  
  <ol>
  <li>xml_document and master_information is one to one.</li>
  <li>xml_document and general_information is one to one.</li>
  <li>xml_document and details_attribute is one to many.</li>
  <li>master_information and master_attribute is one to many</li>
  </ol>