title: How to get the FTP path starting from the root of the user directory?
body: <p>I am using the WordPress method <code>$wp_filesystem-&gt;put_contents()</code> to write a file to the server. When I use an absolute path like the following no file will be put to that location:</p>
  
  <pre><code>/www/htdocs/w423fe4/wordpress/wp-content/plugins/file.zip
  </code></pre>
  
  <p>However when I change the path to start only after the user name (w423fe4) the file is indeed put to the server. So my question is is there any way to programmatically get the server path starting from the root of the user account in PHP? So basically what I like to get in the above case is this:</p>
  
  <pre><code>/wordpress/wp-content/plugins/file.zip
  </code></pre>
  
  <p>Or is this not possible because every server somehow has a different structure?</p>