27include_once DOL_DOCUMENT_ROOT.
'/core/modules/DolibarrModules.class.php';
48 $this->family =
"technic";
50 $this->
name = preg_replace(
'/^mod/i',
'', get_class($this));
51 $this->
description =
"Ajout de files d'informations RSS dans les ecrans Dolibarr";
53 $this->version =
'dolibarr';
54 $this->const_name =
'MAIN_MODULE_'.strtoupper($this->
name);
58 $this->dirs = array(
"/externalrss/temp");
61 $this->config_page_url = array(
"external_rss.php");
64 $this->depends = array();
65 $this->requiredby = array();
66 $this->phpmin = array(7, 0);
67 $this->phpmax = array();
70 $this->
const = array();
73 $this->boxes = array();
77 $this->rights = array();
78 $this->rights_class =
'externalrss';
89 public function init($options =
'')
96 $this->boxes = array();
97 $sql =
"select name, value from ".MAIN_DB_PREFIX.
"const";
98 $sql .=
" WHERE name like 'EXTERNAL_RSS_TITLE_%'";
99 $sql .=
" AND entity = ".$conf->entity;
100 $result = $this->db->query($sql);
102 while ($obj = $this->db->fetch_object($result)) {
104 if (preg_match(
'/EXTERNAL_RSS_TITLE_([0-9]+)/i', $obj->name, $reg)) {
107 $this->boxes[$reg[1]][
'file'] =
"box_external_rss.php";
108 $this->boxes[$reg[1]][
'note'] = $reg[1].
" (".$obj->value.
")";
111 $this->db->free($result);
116 return $this->
_init($sql, $options);
127 public function remove($options =
'')
132 $this->boxes[0][
'file'] =
"box_external_rss.php";
134 return $this->
_remove($sql, $options);
_init($array_sql, $options='')
Enables a module.
_remove($array_sql, $options='')
Disable function.
print $script_file $mode $langs defaultlang(is_numeric($duration_value) ? " delay=". $duration_value :"").(is_numeric($duration_value2) ? " after cd cd cd description as description
Only used if Module[ID]Desc translation string is not found.
$conf db name
Only used if Module[ID]Name translation string is not found.