Making a phpinfo page on your localhost

Under your localhost's home page (see article to find out what it might be if you don't know) create a new folder

phpinfo

In that folder create an index.php file with the content

<?php
  phpinfo();
?>

Or, just put the command phpinfo() somewhere in your existing home index.php file