There is likely more than one way of doing something like this. The most straightforward is probably to change the header file to something like this:
<?php
if (!defined('HOME_LINK_CLASS')) {
define('HOME_LINK_CLASS', 'active');
}
?><nav id="navmenu">
<ul>
<li><a href="index.php" class="<?php echo HOME_LINK_CLASS;?>">Home</a></li>
<li><a href="about.php">About</a></li>
<li><a href="portfolio.php">Portfolio</a></li>
<li><a href="contact.php">Contact</a></li>
</ul>
</nav>
Now, if you want the class to be (say) "inactive" on a particular page, you can add this line before the include
command on that page:
define('HOME_LINK_CLASS', 'inactive');