teraz mam problem z sprawdzeniem czy plik istnieje:
Kod
<?php
$txt = $_POST['text'];
$te = $_POST['tytul'];
$s = '/user/'. $te . '.txt';
if (!empty($txt) && !empty($te))
{
var_dump(file_exists($s));
if (file_exists($s))
{
echo 'Plik nie mogl zostac utworzony';
} else {
$fp = fopen('user/' . $te . '.txt', 'w');
$dane = $txt;
fwrite($fp, $dane);
fclose($fp);
echo "http://blabla.yyyyyy.pl/user/$te.txt";
}