Of course not. Neither the explorer nor the browser can execute PHP.
PHP Code is executed by the server, therefore you have to request your script via http server. In case of Xampp it means, you have to request from "localhost" and you have to use the browser for this request.
All in all, start your browser and enter this link into the URL Line (actually you may also simply click on the following link):
http://localhost/function/function.phpLast but not least, read documentation about Webservers, about Apache, about DocumentRoot and how it all works together.