I've been using the php include function for my navbar for my website. It works well but.... My HTML says
<?php include 'include/navbar.html'; ?>
Now if I have a HTML page in /techpages/toptech.html so I would like to change my php include to <?php include 'http://example.com/include/navbar.html'; ?>. The problem is I get heaps of errors then.
Can someone help me? Can someone answer one of these questions?
- How can I make the PHP include function work with a full URL?
- HTML has
../to go into the parent folder. Is there a CSS equivilant?
Any help would be much appreciated.
../does not belong toHTML,PHPor any other language; it's a feature of the filesystem. Of course CSS supports it.