Chcę zastosować funkcje include tzn. Że po wpisaniu adresu strony kjk.ddl2.pl. wyświetli sie np index.php ale jeżeli klikne Dzial oferta to w pasku pokaze mi sie index.php?id=oferta. Jak to zrobić?
Próbowałem w pliku index.php dać
<? include ("include.php"); ?> a w odrebnym pliku include.php <?php
if(empty($_GET['id']) or $_GET['id']=="strona-glowna"){
include("files/index.html");
}
if($_GET['id']=="oferta"){
include("oferta.html");
}
if($_GET['id']=="realizacje"){
include("realizacje.html");
}
if($_GET['id']=="kontakt"){
include("files/kontakt.html");
}
?>w menu
<a href="?id=strona-glowna">Strona główna</a>
I nic nie daje. pliki w katalogu files są.
Pomożecie ?

Logowanie
Rejestracja
Pomoc

Cytuj
