33require
'../main.inc.php';
34require_once DOL_DOCUMENT_ROOT.
'/core/lib/admin.lib.php';
35require_once DOL_DOCUMENT_ROOT.
'/core/lib/mailmanspip.lib.php';
36require_once DOL_DOCUMENT_ROOT.
'/categories/class/categorie.class.php';
47$langs->loadLangs(array(
"admin",
"members",
"mailmanspip"));
54$action =
GETPOST(
'action',
'aZ09');
63if ($action ==
'update' || $action ==
'add') {
64 $constnamearray =
GETPOST(
"constname",
'array');
65 $constvaluearray =
GETPOST(
"constvalue",
'array');
66 $constnotearray =
GETPOST(
"constnote",
'array');
69 if ($action ==
'update' || $action ==
'add') {
70 foreach ($constnamearray as $key => $val) {
91if ($action ==
'set') {
99if ($action ==
'unset') {
114llxHeader(
'', $langs->trans(
"MailmanSpipSetup"), $help_url,
'', 0, 0,
'',
'',
'',
'mod-admin page-spip');
117$linkback =
'<a href="'.DOL_URL_ROOT.
'/admin/modules.php?restore_lastsearch_values=1">'.$langs->trans(
"BackToModuleList").
'</a>';
118print
load_fiche_titre($langs->trans(
"MailmanSpipSetup"), $linkback,
'title_setup');
121$head = mailmanspip_admin_prepare_head();
128 print
'<form action="'.$_SERVER[
"PHP_SELF"].
'" method="POST">';
129 print
'<input type="hidden" name="token" value="'.newToken().
'">';
130 print
'<input type="hidden" name="action" value="update">';
135 $link =
'<a href="'.$_SERVER[
"PHP_SELF"].
'?action=unset&token='.
newToken().
'&value=0&name=ADHERENT_USE_SPIP">';
137 $link .=
img_picto($langs->trans(
"Activated"),
'switch_on');
141 'ADHERENT_SPIP_SERVEUR',
143 'ADHERENT_SPIP_USER',
154 print
'<div class="center"><input type="submit" class="button" value="'.$langs->trans(
"Update").
'" name="update"></div>';
160 $link =
'<a class="reposition" href="'.$_SERVER[
"PHP_SELF"].
'?action=set&token='.
newToken().
'&value=1&name=ADHERENT_USE_SPIP">';
162 $link .=
img_picto($langs->trans(
"Disabled"),
'switch_off');
dolibarr_set_const($db, $name, $value, $type='chaine', $visible=0, $note='', $entity=1)
Insert a parameter (key,value) into database (delete old key then insert it again).
form_constantes($tableau, $strictw3c=2, $helptext='', $text='Value')
Show array with constants to edit.
dolibarr_del_const($db, $name, $entity=1)
Delete a constant.
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader($head='', $title='', $help_url='', $target='', $disablejs=0, $disablehead=0, $arrayofjs='', $arrayofcss='', $morequerystring='', $morecssonbody='', $replacemainareaby='', $disablenofollow=0, $disablenoindex=0)
Empty header.
load_fiche_titre($title, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='')
Load a title with picto.
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='', $noduplicate=0, $attop=0)
Set event messages in dol_events session object.
img_picto($titlealt, $picto, $moreatt='', $pictoisfullpath=0, $srconly=0, $notitle=0, $alt='', $morecss='', $marginleftonlyshort=2)
Show picto whatever it's its name (generic function)
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='', $dragdropfile=0)
Show tabs of a record.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
newToken()
Return the value of token currently saved into session with name 'newtoken'.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
dol_print_error($db=null, $error='', $errors=null)
Displays error message system with all the information to facilitate the diagnosis and the escalation...
getDolGlobalString($key, $default='')
Return a Dolibarr global constant string value.
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...
global $conf
The following vars must be defined: $type2label $form $conf, $lang, The following vars may also be de...
accessforbidden($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program.