| 8 |
lars |
1 |
|
|
|
2 |
<h2>Internationalisation</h2>
|
|
|
3 |
|
|
|
4 |
<p>Localisation of the presentation layer is important for any software package, and I aim to make this normally arduous task as easy as possible in DataTables. To this end, a number of contributors have kindly translated the language strings used is DataTables into various different languages. If you translate DataTables into any other languages, please <a href="/contact">let me know</a> and I'll happily include the translation here.</p>
|
|
|
5 |
|
|
|
6 |
<ul>
|
|
|
7 |
<li><a href="#how_to">How to use DataTables internalisation options</a></li>
|
|
|
8 |
<li><a href="#functions">Translations</a></li>
|
|
|
9 |
</ul>
|
|
|
10 |
|
|
|
11 |
|
|
|
12 |
<a name="how_to"></a>
|
|
|
13 |
<h3>How to use DataTables internalisation options</h3>
|
|
|
14 |
|
|
|
15 |
<p>There are two methods by which you can include internalisation options in DataTables - loading the language file through an Ajax request, or at initialisation time using the <a href="/usage/i18n">oLanguage</a> property. The following example shows how to include the <a href="#German">German translation</a> as an Ajax file (<a href="/examples/advanced_init/language_file.html">live example</a> - a <a href="/examples/basic_init/language.html">live example</a> for oLanguage control is also available):</p>
|
|
|
16 |
|
|
|
17 |
<pre class="brush: html"><script type="text/javascript" src="jquery.dataTables.js"></script>
|
|
|
18 |
<script type="text/javascript">
|
|
|
19 |
$(document).ready(function() {
|
|
|
20 |
$('#example').dataTable( {
|
|
|
21 |
"oLanguage": {
|
|
|
22 |
"sUrl": "dataTables.german.txt"
|
|
|
23 |
}
|
|
|
24 |
} );
|
|
|
25 |
} );
|
|
|
26 |
</script>
|
|
|
27 |
</pre>
|
|
|
28 |
|
|
|
29 |
|
|
|
30 |
<a name="functions"></a>
|
|
|
31 |
<h3>Translations</h3>
|
|
|
32 |
|
|
|
33 |
include(`build.1.inc')
|