To get proper cyrillic or any UCS-2 text on your handset:

1) Make sure you use latest kannel version from SVN (compile it yourself)

2) execute in MySQL:
ALTER table send_sms charset=utf8
ALTER table sent_sms charset=utf8
ALTER table dlr charset=utf8
So all your tables will be in utf8 encoding.

3) When you insert text into send_sms table you need to make sure text is
in UTF-8 encoding and urlencoded.

4) set coding=2 and charset='utf8', NOTE: each MT will be limited to 70
symbols. If you use concatenated MT each part will be limited to 69 symbols.

5) This way you'll get proper text on your handset.

About msgdata field in sent_sms table: text is double urlencoded, I think
it's either a bug in kannel or feature (?). Text is urlencoded to avoid all
hassle to deal with many encodings out there, because for every encoding
you'd need proper escaping, this way kannel deals with escaping. If you
really need to preserve original text (AS IS) you need to modify kannel's
source code as well as sqlbox, which can be tricky OR as a workaround you
can have another table where you INSERT your text as well and save it for
billing purposes (e.g. billing table)

Generally speaking: both send_sms and sent_sms tables are kinda temporary
tables (at least I keep only 24 hours records there so kannel operates
quickly, because it still depends on MySQL answer).

You can set a TRIGGER on sent_sms table and get updated your other billing
table.

2016-01-22 14:08 GMT+03:00 Deins <notabenaaba...@gmail.com>:

> I need to send sms with a cyrillic symbols. I write sql query with a field
> coding=2.
> In the send_sms table I see right value of the msgdata field. But in
> sent_sms table all characters transforms into 3F3F3F.... string. How to
> deal with it?
>
>

Reply via email to