a request going to your webserver usually hits index.php or .html and so on. with a standard webserver configuration the index file needs to be located in your webservers root directory which is, if you are using xampp, the htdocs/ directory. so basically you can only run one project with the standard configuration. if you have to run multiple projects you have to configure the vhosts for apache.
well what happens is that you are trying to hit "http://localhost:80/public/server/search.php" with your request and expect php to execute this file but in fact the only entrypoint to your application is the index file in your root directory.
so to clarify, all these links below are actually hitting the servers index.php and not any .php files in subdirectories:
there is a configuration file called .htaccess (apache specific) which takes care of alot of things, a few of them are passing parameters to the entrypoint and rewriting the actual url. (if configured)
so what you can do is... just hit your index.php which should be located in the htdocs/ directory instead of /public/server/search.php and return some values of your choice.
dont get confused by modern frameworks were the index.php is located in a subdirectory, its just a more secure approach and the entrypoint can be configured.
The main XAMPP configuration files are located as follows:
apache configuration files:
php configuration file:
mysql configuration file: