Specify file uploading path in php
<p>I am doing a project in PHP. I want to upload files to server. My PHP file is residing in  this folder: </p>

<p><code>http://www.example.com/ssl/</code></p>

<p>html code is</p>

<pre><code>    &lt;tr&gt; 
    &lt;td width="157" align="right"&gt;&lt;font class="text2" size="2" face="Arial, Helvetica, sans-serif"&gt;&lt;b&gt;Choose file:&lt;/b&gt;&lt;/font&gt;&lt;/td&gt;
    &lt;td width="337"&gt; 
    &lt;input type="file" name="Code_1" size="25" maxlength="100"&gt;
    &lt;/td&gt;
    &lt;/tr&gt;

&lt;input type="submit" name="Senden" value="Submit"&gt;
</code></pre>

<p>php code is</p>

<pre><code>if (isset($_POST["Senden"])) {
move_uploaded_file($_FILES["Code_1"]["tmp_name"],"uploads/" . $_FILES["Code_1"]["name"]);
echo "File uploaded";
}
}
else{
    echo "File not uploaded"
}
</code></pre>

<p>This code is working and file is uploaded to <a href="http://www.example.com/ssl/uploads/" rel="nofollow">http://www.example.com/ssl/uploads/</a></p>

<p>I want to upload files to:</p>

<p><code>http://www.example.com/uploads/</code>. </p>

<p>How can I do this? I dont know how to specify the path. I have used the absolute path, but it is not working. Can anyone help me?</p>

<p>Thanks in advance.</p>
