Robię sobie stronkę w php, lecz mam problem gdy chcę połączyć wartości z adresu: lekcja.php?poziom=X?lekcja=Y? aby odczytać plik X_Y_info.txt
Napisałem więc:
Cytat
<?
$adres = "$stopien";
$adres .= "_";
$adres .= "$lekcja";
$adres .= "_info.txt";
$temat_plik=fopen($adres, "r"); <------------------------( to jest linia 59)
$temat=fread($temat_plik, filesize($adres));
fclose($temat_plik);
echo "$temat"; ?>
$adres = "$stopien";
$adres .= "_";
$adres .= "$lekcja";
$adres .= "_info.txt";
$temat_plik=fopen($adres, "r"); <------------------------( to jest linia 59)
$temat=fread($temat_plik, filesize($adres));
fclose($temat_plik);
echo "$temat"; ?>
Wyskakuje mi błąd:
Cytat
Warning: fopen("1?lekcja=1__info.txt", "r") - Invalid argument in c:\apache\htdocs\mapki\lekcja.php on line 59
Warning: stat failed for 1?lekcja=1__info.txt (errno=2 - No such file or directory) in c:\apache\htdocs\mapki\lekcja.php on line 60
Warning: Supplied argument is not a valid File-Handle resource in c:\apache\htdocs\mapki\lekcja.php on line 60
Warning: Supplied argument is not a valid File-Handle resource in c:\apache\htdocs\mapki\lekcja.php on line 61
Warning: stat failed for 1?lekcja=1__info.txt (errno=2 - No such file or directory) in c:\apache\htdocs\mapki\lekcja.php on line 60
Warning: Supplied argument is not a valid File-Handle resource in c:\apache\htdocs\mapki\lekcja.php on line 60
Warning: Supplied argument is not a valid File-Handle resource in c:\apache\htdocs\mapki\lekcja.php on line 61
Z góry dziękuję za szybką pomoc.
MeusH