How to control LED using Arduino as a webclient? [solved]

Thanks a lot for your reply zoomkat. I tried your code and it worked by receiving the HTTP header information, but I still don't understand how to interact with the variable in the webserver, and that is where my real problem is. :frowning:
So, the idea is that the wifi Shield connects to the webserver(which it does), and just waits until someone presses the button on the website which is hosted in the webserver. At that moment, the value of the variable changes. Since the wifi shield is permanently connected and waiting for incoming data, it receives the variable name and a value for that variable. According to this, the Arduino turns on or off a LED, and replies back to the webserver information, so that in case somebody else goes to the website knows the status of the LED.
Therefore, I think my rpoblem is I don't know how to write the commands for this to work out. I have used the GET and POST commands trying to access the variable created in the PHP segmente that takes cares of, but I get nothing, and the same goes on how to send information to the webserver in order to change the value of the variable.
Again, any help will be greatly appreciated! :slight_smile: