bonjour
je veux copier un fichier php qui est dans un autre dossier vers un dossier que je viens de créer avec la fonction mkdir.

j'utilise la fonction copy pour copier le fichier, sa marche mais il le copie pas dans le bon dossier.

voici mon code :

<h2>Ajouter un artiste CD</h2>

<form method="post" action="">
<h6><input type="hidden" name="action" value="go" /></h6>
<h6><input type="hidden" name="envoyer" value="poste" /></h6>
<table style="margin-left: auto;
margin-right: auto;">
<tr>
<td><h4>Ajouter un artiste :</h4>&nbsp;&nbsp;</td>
<td><input type="text" name="nom" id="idchamp" onclick="this.contact.nom.focus()" />
</td>
</tr>
<tr>
<td colspan="2" align="center"><input type="image" name="go" src="img/bouton.jpg" alt="" />
<?
if(isset($_POST["action"]) && ($_POST["action"] == "go"))
{
mkdir($_POST["nom"], 0777);// le fichier doit etre copier dans ce dossier
}
$file = "album/upload.php"; //ce fichier doit etre copier
$newfile = $_POST["nom"]; //dans ce dossier
if (!copy($file,getcwd()."/upload.php")){
echo "pas réusit....";
}

?> </td>
</tr>
</table>
</form>


merci