File: localizing.html

package info (click to toggle)
smstools 3.1.21-3
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 2,500 kB
  • sloc: ansic: 18,624; sh: 1,196; php: 115; makefile: 42; awk: 17
file content (337 lines) | stat: -rwxr-xr-x 10,543 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <META NAME="Title" CONTENT="SMS Server Tools 3">
    <META NAME="Robots" CONTENT="INDEX,FOLLOW">
    <META NAME="Language" CONTENT="English">
    <title>SMS Server Tools 3</title>
<STYLE type="text/css">
BODY {
  BACKGROUND: #ffffff; MARGIN: 5px 5px 10px; FONT: 10pt verdana, geneva, lucida, arial, helvetica, sans-serif; COLOR: #000000
}
td {
  FONT: 10pt verdana, geneva, lucida, arial, helvetica, sans-serif;
}
h3 {
  background-color: #DCDCFE;
}
blockquote {
  background-color: #FFD;
  font-size: 90%;
  padding:5pt;
  padding-top:1pt;
  margin-bottom:5pt;
  border-style: outset;
  border-color: #aaaa99;
  border-width: 0.05pt 2pt 2pt 0.05pt;
}
blockquote p:first-letter {
  font-size: 110%;
  font-weight: bold;
  color: red;
}
</STYLE>
  </head>

<body>
<h2><font color=blue><a href="http://smstools3.kekekasvi.com">SMS Server Tools 3</a></font></h2>
<a href="index.html">Home</a>
<h3>Localizing</h3>
<!-- START --><p>
<p>
Starting from the version 3.1, message files can be written using localized headers.
While localization is in use, english words can still be used.
Localization settings can also be used to drop some unwanted headers from the incoming files, like "From_TOA".
</p>
<p>
A file containing definitions of localization can be defined in the global section of configuration file (smsd.conf)
using the setting: <b>language_file = /path_to_smstools3/examples/language-UTF-8.fi</b>. 
</p>
<p>
Character set used in the language file should match to the locale setting used by the system
which creates outgoing message files. This is very important when UTF-8 is used as a locale, because
byte sequences of special characters should match. Because of this, there is two versions of finnish
translation available in the <i>examples</i> directory: <b>language-ISO-8859-15.fi</b> and <b>language-UTF-8.fi</b>.
NOTE: those translations are from 2007 version of smsd, and not updated which means that all current headers are
not presented in those files. Headers listed in this page are from the version 3.1.16 (released 2017).
</p>
<p>
Headers written using Unicode (UCS2) are not currently supported.
If you are interested to use Unicode headers, please contact the author.
</p>
<p>
Localization file can contain empty lines and comment lines starting with # character.
Keywords are case-insensitive and everything is checked by the smsd.
Keyword and value is separated using an equal sign.
If there are syntactical failures, an error message is produced and the smsd does not start.
</p>
<p>
First, some general settings are available:
<table border=1 bgcolor=lightgrey>

  <tr><td bgcolor=yellow valign=top>datetime</td>
      <td>format string. Can be used to localize timestamp format.<br>
      For example: <b>datetime = %d.%m.%Y %H:%M:%S</b> produces <b>14.08.2007 12:34:56</b>.<br>
      See <i>man strftime</i> for more details.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>incoming</td>
      <td>yes/no. Default: yes. Defines if incoming message files are written using localized headers.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>no_chars</td>
      <td>Used like yes_chars.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>no_word</td>
      <td>Used like yes_word.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>yes_chars</td>
      <td>Define one or more character sequences (or byte sequences if using UTF-8) which means "yes" as the input value.<br>
      Sequence should be inside apostrophes and sequences are delimited using comma.<br>
      For example in finnish, "yes" can be defined using: <b>yes_chars = 'K','k'</b>.
      </td>
  </tr>
  <tr><td bgcolor=yellow valign=top>yes_word</td>
      <td>Defines a word to be used when smsd writes "yes" word to the file, like "kyllä".</td>
  </tr>

</table>
</p>

<p>
While defining alternatives for message file headers, ensure that there is colon included at the end of word.
Some words in the following list are used in the content part, and there colon should not be used.
This list includes a definition how and where a header is used by the smsd.
</p>
<p>
Alternative content for a header can be given as "-" (minus sign only) which means that there is no
translation for this header and smsd does not print this header to the files.
If a header has a translation to be used as an input, and it is wanted that this header is not printed
to the files, an alternative text can start with minus sign.
Some headers cannot be omitted, those cases are market to the list.
</p>
<p>
<table border=1 bgcolor=lightgrey>

  <tr><td bgcolor=yellow valign=top>Alphabet:</td>
      <td>Msg file input. Incoming message.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Autosplit:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Binary:</td>
      <td> Msg file input (sets alphabet to 1 or 0).</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>CALL MISSED</td>
      <td>Incoming call, written to the message body.<br>
      Cannot be omitted.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Call_type:</td>
      <td>Incoming message from phonebook.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Class:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>DCS_hex:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Description:</td>
      <td>Written to all message files..</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Fail_reason:</td>
      <td>Failed outgoing message (currently only spooling uses this).</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Failed:</td>
      <td>Timestamp for failed message.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Flash:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>From:</td>
      <td>Msg file input: informative. Incoming message: senders address.<br>
      Cannot be omitted.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>From_SMSC:</td>
      <td>Incoming message: senders SMSC.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>From_TOA:</td>
      <td>Incoming message: senders Type Of Address.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Hex:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>IMEI:</td>
      <td>Incoming / Sent (or failed) message.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>IMSI:</td>
      <td>Incoming / Sent (or failed) message, identification code if supported.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Include:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Incomplete:</td>
      <td>Incoming message.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Language:</td>
      <td>Msg file input, incoming message.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Language_ext:</td>
      <td>Msg file input, incoming message.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Length:</td>
      <td>Incoming message, text/data length.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Macro:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Message_id:</td>
      <td>Sent (successfully) message.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Message_reference:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>missed</td>
      <td>Incoming call type. Note: this is a value.<br>
      Cannot be omitted.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Modem:</td>
      <td>Sent message, device name (=modemname).</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Name:</td>
      <td>Incoming message: name from the modem response (???).</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Number:</td>
      <td>SIM card's telephone number (if defined in the config file).</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Original_filename:</td>
      <td>Stored when moving file from outgoing directory and unique filenames are used in the spooler.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Ping:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Priority:</td>
      <td>Msg file input.<br>
      With this header a value HIGH can be used and also localized "yes" meaning will work (defined using yes_chars).</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Provider:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Received:</td>
      <td>Incoming message timestamp.<br>
      Cannot be omitted.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Reject_duplicates:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Replace:</td>
      <td>Msg file input. Incoming message: exists with code if replace code was defined.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Reply_path:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Report:</td>
      <td>Msg file input. Incoming message: report was asked yes/no.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Result:</td>
      <td>Voicecall. Result string from a modem.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Retries:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Sending_time:</td>
      <td>Outgoing time.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Sent:</td>
      <td>Outgoing timestamp. Incoming: senders date & time (from PDU).</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>SMSC:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Subject:</td>
      <td>Incoming message, modemname.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>System_message:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Text_is_pdu:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>To:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>To_TOA:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>UDH-Type:</td>
      <td>Incoming message, type(s) of content of UDH if present.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Validity:</td>
      <td>Msg file input.<br>
      Note that if word values are used, they should be written using english.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Voicecall:</td>
      <td>Msg file input.</td>
  </tr>

  <tr><td bgcolor=yellow valign=top>Queue:</td>
      <td>Msg file input.</td>
  </tr>

</table>
</p>

<hr>
</body>
</html>