dolibarr  20.0.0-alpha
notice.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (C) 2016-2021 Laurent Destailleur <eldy@users.sourceforge.net>
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation; either version 3 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program. If not, see <https://www.gnu.org/licenses/>.
16  */
17 
26 if (!defined('NOLOGIN')) {
27  define("NOLOGIN", 1); // This means this output page does not require to be logged.
28 }
29 if (!defined('NOCSRFCHECK')) {
30  define("NOCSRFCHECK", 1); // We accept to go on this page from external web site.
31 }
32 if (!defined('NOIPCHECK')) {
33  define('NOIPCHECK', '1'); // Do not check IP defined into conf $dolibarr_main_restrict_ip
34 }
35 if (!defined('NOSESSION')) {
36  define('NOSESSION', '1');
37 }
38 if (!defined('NOBROWSERNOTIF')) {
39  define('NOBROWSERNOTIF', '1');
40 }
41 
42 // Load Dolibarr environment
43 require '../main.inc.php';
44 
45 
50 if (!GETPOST('transkey', 'alphanohtml') && !GETPOST('transphrase', 'alphanohtml')) {
51  print 'Sorry, it seems your internet connection is off.<br>';
52  print 'You need to be connected to network to use this software.<br>';
53 } else {
54  $langs->loadLangs(array("error", "other"));
55 
56  if (GETPOST('transphrase', 'alphanohtml')) {
57  print dol_escape_htmltag(GETPOST('transphrase', 'alphanohtml'));
58  } elseif (GETPOST('transkey', 'alphanohtml')) {
59  print dol_escape_htmltag($langs->trans(GETPOST('transkey', 'alphanohtml')));
60  }
61 }
62 
63 $db->close();
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
dol_escape_htmltag($stringtoescape, $keepb=0, $keepn=0, $noescapetags='', $escapeonlyhtmltags=0, $cleanalsojavascript=0)
Returns text escaped for inclusion in HTML alt or title or value tags, or into values of HTML input f...