title: Sending an SMS via sms gateway in delphi
body: <p>the code "supplied" by the gateway website is available at <a href="http://www.freesmsgateway.com/api" rel="nofollow">http://www.freesmsgateway.com/api</a>
  I did my best in terms of trying to implement this but have no idea. Googled extensively to no avail. This is something quite cool to implement into a program so i hope a detailed answer would be able to help many people. It appears to post so maybe i interpreted the parameters wrong? Any help or input is valued. Please excuse any formatting mishaps? first time poster to the site. Btw using delphi XE4. message output is in the link below <a href="http://i.stack.imgur.com/xM4r3.png" rel="nofollow">showmessage returned text</a>.</p>
  
  <p>Here is the delphi code:</p>
  
  <pre><code>function tform1.PostExample: string;
       var    param:TStringList;
              valid:boolean;
              url,text:string;
              http:TIDHttp;
        begin
           http := TIDHttp.Create(nil);
           http.HandleRedirects := true;
           http.ReadTimeout := 5000;
           param:=TStringList.create;
           param.Clear;
           param.Add('access_token=994ad8885430************91b6eb8f');
           param.Add('message=Test');
           param.Add('send_to=0729122723');
           valid:=true;
           url:='http://www.FreeSMSGateway.com/api_send';
            try
              text:=http.Post(url,param);
            except
             on E:Exception do
              begin
               valid:=false;
              end;
            end;
           if valid then
            showmessage( text )
            else
            showmessage( '' );
           end;
           end.
  </code></pre>