Temos pavadinimas: WordPress, Shopify ir PHPFusion programuotojų bendruomenė :: Skriptas

Parašė Peacemaker· 2009 Spa. 3 20:10:19
#2

Kodo dalis -

<?PHP

$filename = "output.txt"; #Must CHMOD to 666
$text = $_POST['theformfieldname']; # Form must use POST. if it uses GET, use the line below:
#$text = $_GET['theformfieldname']; #POST is the preferred method

$fp = fopen ($filename, "w"); # w = write to the file only, create file if it does not exist, discard existing contents
if ($fp) {
fwrite ($fp, $text);
fclose ($fp);
echo ("File written");
}
else {
echo ("File was not written");
}

?>




Kaip padaryti viską iš eilės, yra rašoma čia: http://www.tizag.com/phpT/forms.php

Redagavo Peacemaker· 2009 Spa. 3 20:10:22