Get Root Directory Path of a PHP project
<p>I have this folder structure in my PHP project.
(this is as shown in eclips) </p>

<pre><code>-MySystem
    +Code
    +Data_Access
    -Public_HTML
        +css
        +js
        +Templates
    -resources
</code></pre>

<p>When I try this code</p>

<pre><code>echo $_SERVER['DOCUMENT_ROOT']
</code></pre>

<p>output is</p>

<blockquote>
  <p>D:/workspace</p>
</blockquote>

<p>How can I get the path to RootDirectory of the system (<code>MySystem</code>), without hardcoding the Folder Name?</p>
