I am able to get the web page but i cannot get the ?id=
String webRequestII()
{
String startCommmand = "AT+CIPSTART=0,\"TCP\",\"somesite.com\",80\r\n\r\n";
String getCommand = "GET /query?id=2 HTTP/1.1\r\nHost: ";
getCommand += "google.com";
getCommand += ":80\r\n\r\n";
String sendCommand = "AT+CIPSEND=0," + String(getCommand.length()) + "\r\n";
sendData(startCommmand, 1000);
sendData(sendCommand, 1000);
sendData( getCommand, 1000);
}
And when that is done I tried doing this but I always get esp8266.available()=0 or Serial.available =0
Where
String sendData(String command, const int timeout)
{
String response = "";
esp8266.print(command);
delay(timeout);
while (esp8266.available()) {
char c = esp8266.read();
response += c;
digitalWrite(9, HIGH);
delay(50);
digitalWrite(9, LOW);
delay(50);
}
delay(1000);
Serial.println(response);
return response;
}