noalyss Version-9
extension_get.inc.php
Go to the documentation of this file.
1<?php
2//This file is part of NOALYSS and is under GPL
3//see licence.txt
4
5if ( ! defined ('ALLOWED') ) die('Appel direct ne sont pas permis');
6require_once NOALYSS_INCLUDE.'/lib/ac_common.php';
7require_once NOALYSS_INCLUDE.'/constant.php';
8require_once NOALYSS_INCLUDE.'/lib/function_javascript.php';
9require_once NOALYSS_INCLUDE.'/constant.security.php';
10\Noalyss\Dbg::echo_var(1,__FILE__);
11/**
12 * included from do.php + extension_choice.inc.php
13 */
14
15// find file and check security
16global $cn,$g_user;
17
19
20if ($ext->search($_REQUEST['plugin_code']) == -1)
21 {
22 echo_warning("plugin non trouvé");
23 return;
24}
25if ($ext->can_request($g_user->login)==-1)
26{
27 alert("Plugin non authorisé");
28 return;
29}
30if ( ! file_exists(NOALYSS_PLUGIN.'/'.trim($ext->me_file)))
31 {
32
33 echo \Noalyss\Dbg::echo_var(1,"not found ".NOALYSS_PLUGIN.'/'.trim($ext->me_file));
34 alert(j(_("Ce fichier n'existe pas ")));
35 return;
36 }
37require_once NOALYSS_PLUGIN.DIRECTORY_SEPARATOR.trim($ext->me_file);
38
39
40?>
echo_warning($p_string)
warns
Definition: ac_common.php:589
j($p_string)
escape correctly php string to javascript
Definition: ac_common.php:96
alert($p_msg, $buffer=false)
alert in javascript
Definition: ac_common.php:738
$_REQUEST['ac']
manage the extension, it involves the table extension
static echo_var($n_level, $msg, $print=true)
Display the value of a var if DEBUGNOALYSS is greater than $n_level, the debugging info has a certain...
Definition: dbg.php:45
global $g_user
global $cn
included from do.php + extension_choice.inc.php