I am uploading a navigation bar called nav.html
and I would like to use PHP 7 to include
this file at the top of all my pages.
This code: <?php include '/home/u783318484/public_html/nav.html';?>
returns the error message,
Warning: include(/home/u783318484/public_html/nav.html)
: failed to open stream: No such file or directory in /home/u783318484/public_html/apply.php on line 24
Warning: include(): Failed opening '/home/u783318484/public_html/nav.html'
for inclusion (include_path='.:/opt/php-7.0/pear')
in /home/u783318484/public_html/apply.php on line 24
It works fine on my PC with Apache, but when I upload it to my website (hosted by Hostinger) it does this. The nav.html
is in the same folder as the other pages.