Added definition searching feature, polished gui, updated instructions, and bug fixes...
[openemr.git] / interface / language / language.php
blob8e4c6d1a8c5bf884c5a83889d74f3fa121b68140
1 <?php
2 //INCLUDES, DO ANY ACTIONS, THEN GET OUR DATA
3 include_once("../globals.php");
4 include_once("$srcdir/registry.inc");
5 include_once("$srcdir/sql.inc");
6 include_once("../../library/acl.inc");
7 require_once("language.inc.php");
8 require_once("$srcdir/formdata.inc.php");
10 // Setting to enable custom logging of language translations
11 // (Note that the below mysql table is required for this function)
12 $enable_custom_language_logging=false;
13 /* Note that the table mysql lang_custom is required for this function,
14 which can be accomplished with following script in mysql:
15 CREATE TABLE lang_custom (
16 lang_description varchar(100) NOT NULL default '',
17 lang_code char(2) NOT NULL default '',
18 constant_name varchar(255) NOT NULL default '',
19 definition mediumtext NOT NULL default ''
20 ) ENGINE=MyISAM ;
23 //START OUT OUR PAGE....
25 <html>
26 <head>
27 <?php html_header_show();?>
28 <link rel="stylesheet" href="<?php echo $css_header;?>" type="text/css">
29 <script type="text/javascript" src="../../library/overlib_mini.js"></script>
30 <script type="text/javascript" src="../../library/calendar.js"></script>
31 </head>
33 <body class="body_top">
34 <form name='translation' id='translation' method='get' action='language.php' onsubmit="return top.restoreSession()">
35 <input type='hidden' name='m' value='<?php echo strip_escape_custom($_GET['m']); ?>' />
36 <input type='hidden' name='edit' value='<?php echo strip_escape_custom($_GET['edit']); ?>' />
37 <span class="title"><?php xl('Multi Language Tool','e') ?></span>
38 <table>
39 <tr>
40 <td class="small" colspan='4'>
41 <a href="?m=definition" onclick="top.restoreSession()"><?php xl('Edit Definitions','e'); ?></a> |
42 <a href="?m=language" onclick="top.restoreSession()"><?php xl('Add Language','e'); ?></a> |
43 <a href="?m=constant" onclick="top.restoreSession()"><?php xl('Add Constant','e'); ?></a> |
44 <?php if ($enable_custom_language_logging) { ?>
45 <a href="?m=manage" onclick="top.restoreSession()"><?php xl('Manage Translations','e'); ?></a>
46 <?php } ?>
47 </td>
48 </tr>
49 </table>
50 </form>
52 <?php
53 switch ($_GET['m']):
54 case 'definition':
55 include_once('lang_definition.php');
56 break;
57 case 'constant':
58 include_once('lang_constant.php');
59 break;
60 case 'language':
61 include_once('lang_language.php');
62 break;
63 case 'manage':
64 include_once('lang_manage.php');
65 break;
66 endswitch;
69 <BR><A HREF="lang.info.html" TARGET="_blank"><?php xl('Info','e'); ?></A>
70 </body>
71 </html>