Issue

Not sure on how to configure your website to have the function to upload files

Symptoms

None

Cause

Lack of knowledge with PHP upload

Workaround

cpanelID – Cpanel Login ID
uploadfolder – Folder name where the file will be uploaded to.

Note:
Remember to give write permission to the uploadfolder.

if (isset($_POST[‘btnsubmit’]))
{
$target_path = “/home/cpanelID/public_html/uploadfolder/”;

$target_path = $target_path . basename( $_FILES[‘uploadedfile’][‘name’]);

if(move_uploaded_file($_FILES[‘uploadedfile’][‘tmp_name’], $target_path))
{
echo “The file “. basename( $_FILES[‘uploadedfile’][‘name’]). ” has been uploaded”;
}
else
{
echo “There was an error uploading the file, please try again!”;
}

}

echo $target_path;
?>







 











 


 



Additional Information

If you are unable to resolve the problem above, kindly issue a ticket to Support Team.