I know there are GET and POST methods but I do not know how to apply them.
Understanding the semantics of HTTP
methods is essential for programming Web applications. I will try to explain the differences between GET and POST, but first you have to understand the following concepts:
Idempotente - Something that can be applied several times, always generating the same result. A simple example is the multiplication by 1. You can multiply any number by 1 as many times as you want it will always get the original number.
Secure - A request is considered secure if it does not change state on the Server
The GET method must be Indempotent and secure, ie whenever you can get a feature without changing state, the GET method is a good candidate.
The POST method is neither Indempotent nor secure, and can be used for example to change state in an object.
The DELETE method is Indempotent but is not secure, you can make a request to delete a resource as many times as you want the system to delete it only once, but change the state.
So if the request you are making to your test page is indempotent, secure, and you can use the query string to pass the data, you can use the GET
method to do this.
I do not know PHP but I think Santana gave an example of how to get data from the query string.