Source for file display.php
Documentation is available at display.php
* @author linea21 <info@linea21.com>
* @license http://opensource.org/licenses/gpl-3.0.html
include_once('../user/'. SQL. '.inc.php');
for($i= 0; $i< count($data); $i++ ) {
$link = HrefMaker(array('rub'=> $GLOBALS['links'][U_L]['calendar']['linkvalue'],'id'=> $data[$i]['workcal_workshop_id'], '#' => 'cal-'. $data[$i]['workcal_id']));
$workshop_title = _t('name', 'workshop_module') . ' : '. formatText($data[$i]['workshop_denomination'], '2ATT');
$workshop_task= formatText($data[$i]['workcal_task'], '2HTML');
// no link if shared event
if($data[$i]['workcal_workshop_id'] == 999999999) {
$link = $_SERVER["PHP_SELF"]. '#';
$workshop_title = _t('workshop_mod', 'event_common');
$content.= '<li><a href="'. $link. '" title="'. $workshop_title. '" class="tips">'. $data[$i]['task_date']. ' : '. $workshop_task. '</a></li>';
$content= '<p>'. _t('divers', 'nodata'). '</p>';
for($i= 0; $i< count($data); $i++ ) {
$link = HrefMaker(array('rub'=> $GLOBALS['links'][U_L]['calendar']['linkvalue'],'id'=> $data[$i]['workcal_workshop_id'], '#' => 'cal-'. $data[$i]['workcal_id']));
$workshop_title = _t('name', 'workshop_module') . ' : '. formatText($data[$i]['workshop_denomination'], '2ATT');
$workshop_task= formatText($data[$i]['workcal_task'], '2HTML');
// no link if shared event
if($data[$i]['workcal_workshop_id'] == 999999999) {
$link = $_SERVER["PHP_SELF"]. '#';
$workshop_title = _t('workshop_mod', 'event_common');
$content.= '<li><a href="'. $link. '" title="'. $workshop_title. '" class="tips">'. $data[$i]['task_date']. ' : '. $workshop_task. '</a></li>';
$content= '<p>'. _t('divers', 'nodata'). '</p>';
$content= '<ul id="vnav">';
for($i= 0; $i< count($data); $i++ ) {
$workshop_title= formatText($data[$i]['workshop_denomination'], '2HTML');
$workshop_resume= formatText($data[$i]['workshop_resume'], '2HTML');
$content.= '<li><a href="#tabs-'. $i. '" class="selected" title="'. formatText($workshop_title, '2ATT'). '">'. $workshop_title. '</a></li>'. END_LINE;
for($i= 0; $i< count($data); $i++ ) {
$link = array('rub'=> $GLOBALS['links'][U_L]['workgroup']['linkvalue'],'id'=> $data[$i]['workshop_id'],'name'=> $data[$i]['workshop_denomination']);
$workshop_title= formatText($data[$i]['workshop_denomination'], '2HTML');
$workshop_resume= formatText($data[$i]['workshop_resume'], '2HTML');
$content.= '<div id="tabs-'. $i. '" class="ie6bugfix">';
$content.= '<h3>'. $workshop_title. '</h3>'. END_LINE;
$content.= '<div>'. $workshop_resume. '</div>';
$content.= '<p class="access"><a href="'. HrefMaker($link). '" title="'. formatText($workshop_title, '2ATT'). '">'. _t('access','workgroup'). '</a></p>';
$content= '<p class="info">'. _t('divers','nodata'). '</p>';
$content = '<div id="home_publication">'. END_LINE;
$content.= '<h2>'. _t('public','last_news_h1'). '</h2>'. END_LINE;
$link_publi= array('rub'=> $GLOBALS['links'][U_L]['publication']['linkvalue']);
for($i= 0; $i< count($data); $i++ ) {
$publi_id= $data[$i]['publi_id'];
$publi_title= formatText($data[$i]['publi_title'],'2HTML');
$publi_resume= formatText($data[$i]['publi_resume'],'2HTML');
$link_this= array('rub'=> $GLOBALS['links'][U_L]['publication']['linkvalue'], 'id'=> $publi_id, 'name'=> $data[$i]['publi_title']);
$content.= '<h3>'. $publi_title. '</h3>';
$content.= '<a href="'. HrefMaker($link_this). '" title="'. formatText($GLOBALS['links'][U_L]['publication']['desc']. ' : '. $publi_title, '2ATT'). '">';
$content.= '</div><br />';
//$content.='<a href="'.HrefMaker($link_publi).'" title="'.$GLOBALS['links'][U_L]['publication']['desc'].'">';
//$content.='accéder à la liste des dossiers';
$content = '<div id="home_edito">'. END_LINE;
$content.= '<h2>'. _t('header', 'welcome'). '</h2>'. END_LINE;
$content.= _t('public','edito');
$link_gdt= array('rub'=> $GLOBALS['links'][U_L]['workgroup']['linkvalue']);
$content = '<div id="home_top"><div id="home_gdt">'. END_LINE;
$content.= '<h2>'. _t('public','workgroup_h1'). '</h2>'. END_LINE;
$content.= '<a href="'. HrefMaker($link_gdt). '" title="'. formatText($GLOBALS['links'][U_L]['workgroup']['desc'], '2ATT'). '">';
$content.= _t('public','workgroup_edito');
$link_idd= array('rub'=> $GLOBALS['links'][U_L]['dashboard']['linkvalue']);
$content = '<div id="home_idd">'. END_LINE;
$content.= '<h2>'. _t('public','dashboard_h1'). '</h2>'. END_LINE;
$content.= '<a href="'. HrefMaker($link_idd). '" title="'. formatText($GLOBALS['links'][U_L]['dashboard']['desc'], '2ATT'). '">';
$content.= _t('public','dashboard_edito');
$content.= '</div></div>';
* @return void ( echo string )
//$content .= '<a href="#contenu" class="semnone" title="'._t('header','goto_contents').'" accesskey="2">'._t('header','goto_contents').'</a>'.END_LINE;
while (list ($key, $value) = each ($GLOBALS['menuitems'])) {
(ActiveItemAlias($GLOBALS['activeitem']) == $value) ? $classe = ' class="actif"' : $classe = '' ;
$current_link = array('rub' => $GLOBALS['links'][U_L][$value]['linkvalue']);
$content .= '<li id="menu_'. $value. '">';
$content .= '<a href="' . HrefMaker($current_link) . '" title="' . $GLOBALS['links'][U_L][$value]['desc'] . '" accesskey="' . $GLOBALS['links'][U_L][$value]['accesskey'] . '" id="amenu_'. $value. '"'. $classe. '>' . $GLOBALS['links'][U_L][$value]['title'] . '</a>';
* Renvoie les liens de creation de compte ou de déconnexion
* suivant le statut de l'utilisateur
$link_account = array('rub' => $GLOBALS['links'][U_L]['user-prefs']['linkvalue']);
$content = '<div id="myaccount">';
if (isset ($_COOKIE['linea21']['whois'])) {
if(isset ($_COOKIE['linea21']['firstname'])) $title= ucfirst($_COOKIE['linea21']['firstname']);
else $title= $_COOKIE['linea21']['login'];
$content .= '<h3>'. _t('header','welcome'). ' '. $title. ',</h3>';
$content .= '<h3>'. _t('header','myaccount'). '</h3>';
$content .= '<li><a href="' . HrefMaker($link_account) . '" accesskey="u" title="'. _t('header','myaccount_title'). '">' . $str . '</a></li>';
$link_create = array('rub' => $GLOBALS['links'][U_L]['user-registration']['linkvalue']);
$link_logout = array('rub' => $GLOBALS['links'][U_L]['logout']['linkvalue']);
if (isset ($_COOKIE['linea21']['whois'])) $content .= '<li><a href="' . HrefMaker($link_logout) . '" accesskey="l" title="'. _t('header','deconnexion_title'). '">' . ucfirst(_t('header','deconnexion')) . '</a></li>';
else $content .= '<li><a href="' . HrefMaker($link_create) . '" accesskey="c" title="'. _t('divers','user_inscription_title'). '">' . _t('divers','user_inscription') . '</a></li>';
* Formulaire envoi d'un mot de passe
* @return void (echo string)
if($back=== 1) $back= $_SERVER['HTTP_REFERER'];
$input_hidden = $GLOBALS['links'][U_L]['forgot-password']['linkvalue'];
$link_pass = array('rub' => $GLOBALS['links'][U_L]['forgot-password']['linkvalue']);
if(isset ($_POST['valid'])) {
$msg = '<div class="error">'. sprintf(_t('auth', 'no_user'), $login). '</div>';
include_once('../class/class.user.php');
$key = $user->generateNewPasskey($r['user_id'], $GLOBALS['sql_object']);
$todo_mail = 'forgot_pass';
$user_email = $r['profile_email'];
$link_pass = array('rub' => $GLOBALS['links'][U_L]['forgot-password']['linkvalue'], 'token' => $key);
include_once(themePath('../user/mail_actions.php'));
include_once('../mail/template.php');
$msg = '<div class="info">'. sprintf(_t('auth', 'sending_mail'), $user_email). '</div>';
$form = '<p>'. _t('auth','note') . '</p>' . END_LINE;
if(isset ($msg)) $form .= $msg . END_LINE;
$form .= '<form action="index.php" method="post">' . END_LINE;
$form .= '<div id="forgot_pass">' . END_LINE;
$form .= '<p><label for="login" class="labelised">' . _t('divers','login') . ' : </label>' . END_LINE;
$form .= '<input type="text" maxlength="20" class="tinytextfield" name="login" id="login" /></p>' . END_LINE;
$form .= '<input type="hidden" name="rub" id="rub" value="' . $input_hidden . '" />' . END_LINE;
$form .= '<input type="hidden" name="referer" id="referer" value="' . $back . '" />' . END_LINE;
$form .= '<input type="submit" class="submitbut" value="'. _t('btn','valid'). '" title="'. _t('btn','valid'). '" size="15" name="valid" id="valid" />'. END_LINE;
* Formulaire d'authentification pour login ou inscription
* @return void (echo string)
function AuthForm($todo = 'LOGON', $back = 1 )
if($back=== 1) $back = $_SERVER['HTTP_REFERER'];
isset ($_POST['login']) ? $form_login = $_POST['login'] : $form_login = '';
isset ($_POST['email']) ? $form_email = $_POST['email'] : $form_email = '';
isset ($_POST['firstname']) ? $form_firstname = strip_input(trim($_POST['firstname'])) : $form_firstname = '';
isset ($_POST['lastname']) ? $form_lastname = strip_input(trim($_POST['lastname'])) : $form_lastname = '';
$input_hidden = $GLOBALS['links'][U_L]['user-prefs']['linkvalue'];
$input_hidden = $GLOBALS['links'][U_L]['user-registration']['linkvalue'];
$link_pass = array('rub' => $GLOBALS['links'][U_L]['forgot-password']['linkvalue']);
$form = '<form action="index.php" method="post">' . END_LINE;
$form .= '<div id="' . $div_id . '">' . END_LINE;
$form .= '<p><label for="login" class="labelised">' . _t('divers','login') . ' : </label>' . END_LINE;
$form .= '<input type="text" maxlength="20" class="tinytextfield" name="login" id="login" value="'. $form_login. '" />' . END_LINE;
$form .= '<p><label for="password" class="labelised">' . _t('divers','password') . ' : </label>' . END_LINE;
$form .= '<input type="password" maxlength="20" class="tinytextfield" name="password" id="password" /></p>' . END_LINE;
$form .= '<p class="forgot_pass"><a href="'. HrefMaker($link_pass). '">'. _t('auth', 'forgot_password'). '</a></p>';
$form .= '<p><label for="email" class="labelised">' . _t('divers','email') . ' : </label>' . END_LINE;
$form .= '<input type="text" maxlength="100" class="tinytextfield" name="email" id="email" value="'. $form_email. '" /></p>' . END_LINE;
$form .= '<p><label for="firstname" class="labelised">' . ucfirst(_t('user','first_name')) . ' ('. _t('divers','optional') . ') : </label>' . END_LINE;
$form .= '<input type="text" maxlength="200" class="tinytextfield" name="firstname" id="firstname" value="'. $form_firstname. '" /></p>' . END_LINE;
$form .= '<p><label for="lastname" class="labelised">' . ucfirst(_t('user','last_name')) . ' ('. _t('divers','optional') . ') : </label>' . END_LINE;
$form .= '<input type="text" maxlength="200" class="tinytextfield" name="lastname" id="lastname" value="'. $form_lastname. '" /></p>' . END_LINE;
$form .= '<input type="hidden" name="rub" id="rub" value="' . $input_hidden . '" />' . END_LINE;
$form .= '<input type="hidden" name="referer" id="referer" value="' . $back . '" />' . END_LINE;
$form .= '<input type="submit" class="submitbut" value="'. _t('btn','valid'). '" title="'. _t('btn','valid'). '" size="15" name="valid" id="valid" />'. END_LINE;
* Return groups user has subscribed to
if(!isset ($_COOKIE['linea21']['workshop'])) return false;
$link_account = array('rub' => $GLOBALS['links'][U_L]['user-prefs']['linkvalue']);
// get and prepare user groups
if($groups[0]== '/') $groups = substr($groups, 1); // removing first separator
$content = '<div id="mygroups">'. END_LINE;
$content .= '<h3>'. _t('groups', 'mine'). '</h3>'. END_LINE;
for($i= 0; $i< count($data); $i++ ) {
$link = array('rub'=> $GLOBALS['links'][U_L]['workgroup']['linkvalue'],'id'=> $data[$i]['workshop_id']);
$workshop_title = formatText($data[$i]['workshop_denomination'], '2HTML');
$content .= '<li><a href="'. HrefMaker($link). '" title="'. formatText($data[$i]['workshop_denomination'], '2ATT'). '">'. $workshop_title. '</a></li>';
$content .= '<a href="'. HrefMaker(array('rub' => $GLOBALS['links'][U_L]['project']['linkvalue'])). '" title="'. $GLOBALS['links'][U_L]['project']['title']. '">'. $GLOBALS['links'][U_L]['project']['title']. '</a>';
$action= $GLOBALS['links'][U_L]['subscribe-newsletter']['linkvalue'];
$form = '<form action="index.php" method="post">' . END_LINE;
$form .= '<div id="newsletter_form">' . END_LINE;
$form.= '<h3>'. _t('menu_alt','newsletter'). '</h3>';
$form .= '<label for="newsletteremail">' . _t('divers','email') . ' : </label>' . END_LINE;
$form .= '<input type="text" maxlength="200" size="19" class="tinytextfield" name="newsletteremail" id="newsletteremail" />' . END_LINE;
$form .= '<input type="submit" value="'. _t('btn','valid'). '" alt="'. _t('btn','valid'). '" title="'. _t('btn','valid'). '" size="15" name="valid" id="valid_newsletter" />'. END_LINE;
$form .= '<input type="checkbox" name="del_action" id="del_action" style="float:left;margin:0em 1em 0 3.2em" />';
$form .= '<input type="hidden" name="rub" id="rub_newsletter" value='. $GLOBALS['links'][U_L]['subscribe-newsletter']['linkvalue']. ' />' . END_LINE;
$form .= '<label for="del_action" class="checkboxlab">'. _t('newsletter','unsubscribe'). '</label>' . END_LINE;
$content = '<div id="recentNews">'. END_LINE;
//$content.= '<p>'._t('divers','actu_left').'</p>';
$content.= '<h3>'. _t('divers','actu_left'). '</h3>';
for($i= 0; $i< count($data); $i++ ) {
$title= formatText($data[$i]['news_title'],'2HTML');
$link_table= array('rub'=> $GLOBALS['links'][U_L]['news']['linkvalue'],'id'=> $data[$i]['news_id'], 'name' => $data[$i]['news_title']);
$content.= '<li><a href="'. HrefMaker($link_table). '" title="'. formatText($GLOBALS['links'][U_L]['news']['desc']. ' : '. $title, '2ATT'). '">'. $title. '</a>';
#$content.='<em>'._t('statut', 'published_on').' '.$data[$i]['news_published_date_display'].'</em>'.END_LINE;
$content.= '<p>'. _t('divers','nodata'). '</p>';
$content = '<div id="recentIndicators">'. END_LINE;
$content.= '<h3>'. _t('divers','sdi_left'). '</h3>';
for($i= 0; $i< count($data); $i++ ) {
$test[$i]= $data[$i]['sdii_id'];
$title= formatText($data[$i]['sdii_name'],'2HTML');
$link_table= array('rub'=> $GLOBALS['links'][U_L]['dashboard']['linkvalue'],'id'=> $data[$i]['sdii_id'], 'parentid'=> $data[$i]['sdiv_scale'], 'name' => $data[$i]['sdii_name'] );
$content.= '<li><a href="'. HrefMaker($link_table). '" title="'. formatText($GLOBALS['links'][U_L]['dashboard']['desc']. ' : '. $title, '2ATT'). '">'. $title. '</a>';
$content.= _t('divers','nodata');
$action= $GLOBALS['links'][U_L]['search-result']['linkvalue'];
$form = '<form action="index.php" method="get">'. END_LINE;
$form .= '<div id="searchinput">'. END_LINE;
$form.= '<h3>'. _t('menu','search'). '</h3>';
$form.= '<br /><label for="search">'. _t('menu','search'). ' </label>'. END_LINE;
$form.= '<input type="text" maxlength="100" size="15" name="search" id="search" accesskey="4" class="tinytextfield" />'. END_LINE;
$form.= '<input type="hidden" name="rub" id="rub_search" value="'. $GLOBALS['links'][U_L]['search-result']['linkvalue']. '" />' . END_LINE;
$form.= '<input type="submit" value="'. _t('btn','valid'). '" size="15" name="valid" id="validsearch" />'. END_LINE;
$form.= '<p id="searchadv">';
$form.= '<a href="'. HrefMaker(array('rub'=> $GLOBALS['links'][U_L]['search']['linkvalue'])). '" title="'. formatText($GLOBALS['links'][U_L]['search']['title'], '2ATT'). '">';
$form.= _t('menu','advancedsearch');
$content= '<a href="mailto:'. SITE_MAIL. '" ';
$content.= 'title="'. SITE_MAIL. '" >'. _t('divers','contact'). ' </a> | ';
$content.= '<a href="'. HrefMaker(array('rub'=> $GLOBALS['links'][U_L]['accessibility']['linkvalue'])). '" ';
$content.= 'title="'. formatText(_t('divers','accessibility'), '2ATT'). '" accesskey="0"> '. _t('divers','accessibility'). ' </a> | <a href="rss2.php" title="RSS">rss</a><br />';
|