Moved php in index.php to a seperate php file