getCurrentUser(); function sendCreationMail($userEmail,&$list) { $message = sprintf(_('A mailing list will be created on %1$s in few minutes and you are the list administrator. This list is: %3$s@%2$s . Your mailing list info is at: %4$s . List administration can be found at: %5$s . Your list password is: %6$s . You are encouraged to change this password as soon as possible. Thank you for registering your project with %1$s. -- the %1$s staff '), $GLOBALS['sys_name'], $GLOBALS['sys_lists_host'], $list->getName(), $list->getExternalInfoUrl(), 'http://'.$GLOBALS['sys_lists_host'].'/mailman/admin/'.$this->getName(), $list->getPassword()); $mailSubject = sprintf(_('%1$s New Mailing List'), $GLOBALS['sys_name']); $hdrs = "From: ".$GLOBALS['sys_email_admin'].$GLOBALS['sys_lf']; $hdrs .='Content-type: text/plain; charset=utf-8'.$GLOBALS['sys_lf']; mail ($userEmail,$mailSubject,$message,$hdrs); } function table_begin() { echo "
\n"; } function table_end() { echo ' |
Mailing lists provided via a GForge version of GNU Mailman. Thanks to the Mailman and Python crews for excellent software.
'); } function display_list($currentList) { $request =& HTTPRequest::instance(); $current_user=UserManager::instance()->getCurrentUser(); if($currentList->isPublic()!='9'){ if ($currentList->isError()) { echo $currentList->getErrorMessage(); } else { getIcon(); echo ' '.$currentList->getName().' ['; if($currentList->getStatus() == '3') { echo _('Not activated yet'); } else { echo ' '._('Archives').''; if(isLogged()) { if ($currentList->isMonitoring()) { echo ' | '._('Unsubscribe').' '; echo ' | '._('Preferences').''; } else { echo ' | '._('Subscribe').''; } if ($currentList->getListAdminID() == $current_user->getID()){ echo ' | '._('Administrate').' '; } } } echo ' ]';
}
}
}
function display_list_admin($currentList)
{
$request =& HTTPRequest::instance();
$current_user=UserManager::instance()->getCurrentUser();
if($currentList->isPublic()!='9'){
if ($currentList->isError() ) {
echo $currentList->getErrorMessage();
} else
{
getIcon();
echo ' '.$currentList->getName().' [';
}
if($currentList->getStatus() == '3') {
echo _('Not activated yet');
} else {
echo ' '._('Update').'';
echo ' | '. _('Delete').'';
if ($currentList->getListAdminID() == $current_user->getID()){
echo ' | '._('Administrate from Mailman').' ';
}
}
echo ' ]
';
echo htmlspecialchars($currentList->getDescription()).'
'; } } function mailman_header($params) { global $group_id; $current_user=UserManager::instance()->getCurrentUser(); $request =& HTTPRequest::instance(); //required for site_project_header $params['group'] = $request->get('group_id'); $params['toptab'] = 'mailman'; site_project_header($params); echo '
'; // admin link is only displayed if the user is a project administrator if ($current_user->isMember($request->get('group_id'),'A')) { if (isset($params['admin'])){ echo ''._('Administration').''; } else{ echo ''._('Administration').''; } } if ($params['help']) { helpButton($params['help']); } } function mail_footer($params) { site_project_footer($params); } // Local Variables: // mode: php // c-file-style: "bsd" // End: ?>