I wrote a C++ program that sends an http GET request to a given host and receives the answer. My program does not support POST requests. I know that form parameters can be appended at the end of the path like so:
Normal link: http://finance.yahoo.com/q/hp
Link with form parameters: http://finance.yahoo.com/q/hp?s=SNIVX&b=1&a=00&c=1900
Receiving the answer to a request with the second link works fine so far. I tried the same on this website but it doesn't seem to accept the form parameters:
http://www.finanzen.net/historische-kurse/Linde?inTag1=1&inMonat1=1&inJahr1=2010&inTag2=30&inMonat2=1&inJahr2=2015&strBoerse=XETRA
I looked up the keys and values in the page source of that website. When I click the corresponding button on the website to submit the form it uses a POST request unlike the previous example which uses a GET request. With a normal GET request it just returns the page as if no form parameters were given.
I'm using http 1.0 and winsock for the client-server communication. My request is built like this:
sprintf(htmlRequest, "GET %s HTTP/1.0\r\nHost: %s\r\nConnection: close\r\n\r\n", file.c_str(), host.c_str());
Can I somehow submit form parameters on the second website without using a POST request? Do some websites only accept/ support form parameters from POST requests and not from GET requests?