I'm trying to get this script working, but unfortunately nothing to do...I also think there is a better way to do that, but dunno which?So I want that on an opened page the button remains as it was on hover, so I created a class that looks like the button hover and said the php to apply this class if the current pagename corrispond to the "this button" link.\[code\]$currentpath = basename(__FILE__);\[/code\]is setted on each page before I include header.phpThank you!PHP and HTML:\[code\]<?php$ordinazioniofferte = "/ita/ordinazioniofferte.php";$prezzi = "/ita/prezzi.php";$azienda = "/ita/azienda.php";$sudinoi = "/ita/sudinoi.php";$stazioni = "/ita/stazioni.php";$prodotti = "/ita/prodotti.php";$tecnoecologia = "/ita/tecnoecologia.php";$contatti = "/ita/contatti.php";?><div id="button"> <ul> <li><a href=http://stackoverflow.com/questions/14490011/<?=$ordinazioniofferte?> class="<?php if($currentpath == basename($ordinazioniofferte)){echo("buttonon");} ?>">Ordinazioni - Offerte</a></li> <li><a href=http://stackoverflow.com/questions/14490011/<?=$prezzi?> class="<?php if($currentpath == basename($prezzi)){echo("buttonselected");} ?>">Prezzi</a></li> <li><a href=http://stackoverflow.com/questions/14490011/<?=$azienda?> class="<?php if($currentpath == basename($azienda)){echo("buttonselected");} ?>">Azienda</a></li> <li><a href=http://stackoverflow.com/questions/14490011/<?=$sudinoi?> class="<?php if($currentpath == basename($sudinoi)){echo("buttonselected");} ?>">Su Di Noi</a></li> <li><a href=http://stackoverflow.com/questions/14490011/<?=$stazioni?> class="<?php if($currentpath == basename($stazioni)){echo("buttonselected");} ?>">Stazioni Di Servizio</a></li> <li><a href=http://stackoverflow.com/questions/14490011/<?=$prodotti?> class="<?php if($currentpath == basename($prodotti)){echo("buttonselected");} ?>">Prodotti</a></li> <li><a href=http://stackoverflow.com/questions/14490011/<?=$tecnoecologia?> class="<?php if($currentpath == basename($tecnoecologia)){echo("buttonselected");} ?>">TecnoEcologia</a></li> <li><a href=http://stackoverflow.com/questions/14490011/<?=$contatti?> class="<?php if($currentpath == basename($contatti)){echo("buttonselected");} ?>">Contatti</a></li> </ul> </div> \[/code\]The CSS:\[code\]#button ul { margin: 0; padding: 0; list-style-type: none; text-align: center; background-color: #F00;} #button ul li { display: inline; } #button ul li a { display:inline-block; color:#FFF; font-family:Calibri; font-size:18px; font-weight:bold; padding:4px 15px 4px 15px; text-decoration:none; font-variant:small-caps;} #button ul li a:hover { background-color:#F00; color:#02346F; padding:4px 15px 4px 15px; font-size:18px; font-weight:bolder;}.buttonon { background-color:#F00; display:inline-block; font-family:Calibri; font-size:18px; font-weight:bold; text-decoration:none; font-variant:small-caps; color:#02346F; padding:4px 15px 4px 15px; font-size:18px; font-weight:bolder;}\[/code\]EDIT: I added a definition for $currentpath.