Updated core.php