Hi,

Read the user guide.

Regards
--
Abdulmnem Benaiad
Almontaha CTO
Tripoli-Libya
www.almontaha.ly
about.me <http://about.me/benaiad/bio>



On Sat, Oct 23, 2010 at 4:17 PM, prashant singh <[email protected]>
 wrote:

> thanx .. it helped,now kannel is able to send mesg but i am unable to
> recieve the response of kannel through my java program i.e. whether mesg is
> sent or queued or whatever..please guide me on this issue also.
>
> regards,
> prashant
>

On Sat, Oct 23, 2010 at 10:47 AM, Benaiad <[email protected]> wrote:

> Hi,
>
> Try this:
> --------------
> String result = "";
> String data =  "user" + "=" + URLEncoder.encode("test","UTF8")
>         + "&" + "pass"  + "=" + URLEncoder.encode("test", "UTF8")
>         + "&" + "to"       + "=" + URLEncoder.encode("999", "UTF8")
>         + "&" + "text"    + "=" + URLEncoder.encode("test ", "UTF8");
> java.net.URL url = new java.net.URL("
> http://localhost:13013/cgi-bin/sendsms?"+data);
> java.io.InputStream in = url.openStream();
> java.io.BufferedInputStream bufIn = new java.io.BufferedInputStream(in);
> for (;;) {
>                 int car = bufIn.read(); // Check for EOF
>                 if (car == -1) {
>                     break;
>                 } else {
>                     result = result + (char) car;
>                 }
> }
> bufIn.close();
> in.close();
> ---------------
> Hope this help.
>
> Regards
> --
> Abdulmnem Benaiad
> Almontaha CTO
> Tripoli-Libya
> www.almontaha.ly
> about.me <http://about.me/benaiad/bio>
>
>
>
> On Sat, Oct 23, 2010 at 9:16 AM, prashant singh <[email protected]
> > wrote:
>
>> URL url = new URL("http://localhost:13013/cgi-bin/sendsms?";);
>>
>
>

Reply via email to