index.php bug fix