Bonjour,
voila: j'ai créé un formulaire qui m'affiche dans la <TextArea> le fichier.txt,
que l'on peut modifier puis réécrire dans le fichier.txt.
mon problème est que dans ce fichier j'ai des balises (<p><b> <div>...),
et quand le fichier.txt s'affiche dans le formulaire on voit ces balises (ce qui n'est pas le plus embêtant),
et lorsque on envoie le formulaire , le script php recode ces balises (genre; <p class"roman-titre">)
ce qui est plus embêtant,
Voici mon formulaire et le script php:
<p>Roman : <br />
<form method="post" action="admin.php?page=modif¶m=romanmodifie">
<input type="hidden" name="kind" id="kind" value="roman.txt"/>
<input type="hidden" name="where" value="admin.php?page=modif¶m=romanform"/>
<textarea name="changement" id="changement" cols=47 rows=8 >
<?php include"roman.txt"; ?>
</textarea>
<input type="submit" value="Envoyer"/>
</form></p>
-----------------------------------------------------------
<?php
$kind=htmlentities($_POST['kind']);
$changement=htmlentities($_POST['changement']);
$where=htmlentities($_POST['where']);
$file = fopen("$kind","w");
fwrite($file,$changement);
fclose($file);
header ("Location: $where");
?>
Voilà, si quelqu'un peu m'aider...
Salut
Annadrill