Home >Backend Development >PHP Tutorial >Use PHP to set up web navigation_PHP tutorial
Description:
The principle of implementation is that the web page contains a specific page. In order to achieve navigation, you must add '?id=pagename' to display in your web page.
The code is as follows:
if($id=="home"){
include("yourhomepage.html");
}
elseif($id=="page"){
include("yourpage.html");
}
//If your browser does not connect to the specified page, or an error occurs in the connection page, the following page will be displayed.
else{
include("yourpage.html");
}
?>