sim808 with arduino uno and http request error

Hi,
I was trying to send some gps data to web with AT commands. I was successful with serial monitor terminal. But when I try to send the same command by Arduino IDE( Not serial monitor terminal) program, then it shows error for “AT+HTTPACTION=0”(actually it is not executing) and executing all previous commands(looping) which should not be done because those primary AT commands is not in the loop. Can someone tell me why those commands are looping? and why last AT command is not executing, as it is executed in serial monitor terminal?

error.png

test_AT.ino (2.31 KB)