fix history.php