http://localhost:8080/yourphpscriptpage.php will put it in the browser if the following is correct:
1. you have the file yourphpscriptpage.php in your xampp/htdocs directory.
2. you have changed the default port from 80 to 8080
Things that won't happen:
Clicking on yourphpscriptpage.php will not load it in the browser as it is a language that has to be parsed by a server.
You can, in windows, associate a web browser with the php file extension just as you can with a htm/html file but all you will see is the raw code just like if you associate it with a text editor. HTML can be rendered in a web browser as that is what it does best but script languages like php, perl and C etc. need to be parsed then rendered in a browser.
in any case if I have the php in my C:/Documents Would I then use Http:/localhost/C/Documents/phpinfo.php if that were the file I wanted to open?
You can have your files like the above where ever you want so long as you tell Apache (XAMPP) where they are by changing the document root in the httpd.conf file or creating a virtual host with the document root set in that section of the xampp/apache/conf/httpd.conf or xammp/apache/conf/extra/httpd_vhost.conf
What ever you do you must be aware that nothing on your PC has a brain of it's own. It needs to be instructed to do what ever it has to do. So if you have your server on the K: drive then you need to tell the software via the conf files that this is in fact where my files are. If they are elsewhere then tell the configuration file their locations.
Once you have mastered this aspect then when you type a default address in your browser your browser will know exactly where to go to get them. Without this knowledge the browser is a dumb as a brick wall.
In my opinion you should uninstall XAMPP completely. Reinstall to the default locations and get all thing working out of the box so you can then see how it works and what you need to do to customise it for your own needs. Jumping in with changes before you have a grasp of what things do is open to your having (k)nightmares
.
Localhost is a server host name and 127.0.0.1 is the IP address of that host name. Both are the same thing and are only on your own PC machine often referred to as the loopback address. When you go intranet or Internet your IP and server host name will change completely but the localhost will always be on your own PC.
If you include php code inside a html file then the server will expext the extension to be .php not .html otherwise as I mentioned earlier it will not get parsed and will show as raw php code.
The apache server's render engine reacts to the file extension to do it's rendering. It will have a heart attack if the extension is not relevant to the code it contains.
Reading mySQL for Dummies will not do much for your understanding of php but a google search will give you the desired results for learning php.
The xampp/apache/conf/httpd.conf files look after the server.
The php.ini file in xampp/apache/bin directory looks after the php configurations.
The xampp/mysql/bin/my.cnf looks after the mysql needs.
You obviously need to do some reading but I hope this post will enlighten you somewhat and at least get your php files rendered into you web browser.
Good luck.