Your "other" issues are not really Kannel related. But I do have one (other) suggestion. Make sure you urlencode $number as well. Otherwise the '+' sign will be seen as a space.
== Rene -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of termbsd Sent: Tuesday, 31 January, 2012 14:00 To: [email protected] Subject: Re: Sending SMS from Asterisk using Kannel HI, I tried using curl in my php script.I got few errors. My php script SMS.php code is: ************************** $number = "+919957681012"; $text1 ="This is sms from php"; $encmsg=urlencode($text1); $ch= curl_init(); curl_setopt($ch,CURLOPT_URL, "http://localhost:13013/cgi-bin/sendsms?username=kanneluser&password=foobar& to=$number&text=$encmsg"); curl_exec($ch); curl_close($ch); ************************** I get 2 errors when running this: 1) ./usr/bin/php: /usr/local/lib/libxml2.so.2: no version information available (required by /usr/bin/php) libxml2.so.2- This file is at 3 places when i searched for it. a) /usr/lib/libxml2.so.2 b) /usr/local/lib/libxml2.so.2 c) /home/speechwarenet/Desktop/Kannel/libxml2-2.7.2/.libs/libxml2.so.2 Do i have to delete any one of these files and link it again to another?Please suggest. 2) When I execute the PHP script - ./SMS.php i get, Cache Access Denied. </STRONG> </UL> </P> <P>Sorry, you are not currently allowed to request: <PRE> http://localhost:13013/cgi-bin/sendsms?</PRE> from this cache until you have authenticated yourself. </P> <P> You need to use Netscape version 2.0 or greater, or Microsoft Internet Explorer 3.0, or an HTTP/1.1 compliant browser for this to work. My smskannel.conf has the below settings: #include = "Desktop/Kannel/gateway-1.4.3/doc/examples/modems.conf" group = core admin-port = 13000 smsbox-port = 13001 admin-password = bar box-deny-ip = "*.*.*.*" box-allow-ip = "127.0.0.1" group = smsc smsc = at modemtype =auto device = /dev/ttyS0 my-number = 8811909770 (SIM number in GSM modem) connect-allow-ip = 127.0.0.1 log-level =0 group = smsbox bearerbox-host = 127.0.0.1 sendsms-port = 13013 global-sender = 8811909770 log-level = 0 group = sendsms-user username = kanneluser password = foobar concatenation = true max-messages =10 group = sms-service keyword = keyword-regex =.* catch-all =yes max-messages =0 get-url ="http://localhost/sms?phone=%p&text=%a" group = sms-service keyword = default text = "No service specified" Please help me.I am stuck with this.. -- View this message in context: http://old.nabble.com/Sending-SMS-from-Asterisk-using-Kannel-tp33159189p3323 5965.html Sent from the Kannel - User mailing list archive at Nabble.com.
