function main($content, $conf)
 {
     $this->conf = $conf;
     //debug ($conf);
     $this->pi_loadLL();
     //debug($this->piVars);
     $WhereSTH = " WHERE (starttime=0 OR starttime <" . time() . ") AND (endtime=0 OR endtime>" . time() . ") AND deleted=0 AND hidden=0";
     $req = "SELECT * from tx_vm19watsniou" . $WhereSTH . " order by tstamp DESC LIMIT " . $this->conf['NiousNumber'];
     $rep = mysql(TYPO3_db, $req);
     //$content='<H2>'.$this->pi_getLL("WhatsNew").'</H2>'; // le titre est affich�au niveau du plugin
     $content .= '<table border="0">';
     while ($rw = mysql_fetch_array($rep)) {
         if ($this->pi_getPageLink($rw[pid] || $rw[typcontent] == "vm19_hnlinks")) {
             // gestion des droits  ... simple non ?
             // les images sont nomm�s comme les types de contenus
             $content .= '<tr><td><img src="' . $this->imgPath . $rw[typcontent] . '.gif"></td><td>';
             // debug $content.= "| getPageLink". $this->pi_getPageLink($rw[pid])."|";
             if ($rw[typcontent] == "vm19_hnlinks") {
                 $tabisa = explode("|", $rw[title]);
                 $href = strstr($tabisa[1], "http://") ? $tabisa[1] : "http://" . $tabisa[1];
                 $title = $tabisa[0];
                 $content .= '<H3><a href="' . $href . '" target="_blank">' . $title . '</a></H3>';
             } else {
                 $content .= '<H3>' . $this->pi_linkToPage($rw[title], $rw[pid]) . '</H3>';
             }
             // ne fonctionne pas quand l'id ne correspond pas au titre
             //	  $content.='<H2>'.VmlinkToPage($rw[title],$rw[pid]).'</H2>';
             $content .= '<DIV style="margin:2px">';
             $content .= "<b>" . $this->pi_getLL("tc_" . $rw[typcontent]) . "</b>";
             if ($rw[tstamp] <= $rw[crdate]) {
                 $content .= $this->pi_getLL("crdate");
             } else {
                 $content .= $this->pi_getLL("modifdate");
             }
             $femtctrad = $this->pi_getLL("tcf_" . $rw[typcontent]);
             // pour g�er le f�inin de cr�(e) ou modifi�e)
             $content .= $femtctrad . $this->pi_getLL("on");
             $content .= getDateF($rw[tstamp]);
             //      $tabidarbo=unserialize($rw[tabidarbo]);
             $content .= "<br/>" . $this->pi_getLL("path");
             $tabstrarbo = unserialize(stripslashes($rw[tabstrarbo]));
             foreach ($tabstrarbo as $key => $value) {
                 $content .= $this->pi_linkToPage($value, substr($key, 2)) . " > ";
             }
             $content = vdc($content, 3);
             // enl�e le dernier " > "
             $content .= '</DIV></td></tr>';
         }
         // fin si droit OK
     }
     // fin boucle sur nouveaut�
     $content .= "</table>";
     /*$content='
           <strong>This is a few paragraphs:</strong><BR>
           <P>This is line 1</P>
           <P>This is line 2</P>
     
           <h3>This is a form:</h3>
           <form action="'.$this->pi_getPageLink($GLOBALS["TSFE"]->id).'" method="POST">
             <input type="hidden" name="no_cache" value="1">
             <input type="text" name="'.$this->prefixId.'[input_field]" value="'.htmlspecialchars($this->piVars["input_field"]).'">
             <input type="submit" name="'.$this->prefixId.'[submit_button]" value="'.htmlspecialchars($this->pi_getLL("submit_button_label")).'">
           </form>
           <BR>
           <P>You can click here to '.$this->pi_linkToPage("get to this page again",$GLOBALS["TSFE"]->id).'</P>
         ';
         */
     return $this->pi_wrapInBaseClass($content);
 }
 /**
  * [Put your description here]
  */
 function getFieldContent($fN, $mode = "L")
 {
     switch ($fN) {
         case "uid":
             return $this->pi_list_linkSingle($this->internal["currentRow"][$fN], $this->internal["currentRow"]["uid"], 1);
             // The "1" means that the display of single items is CACHED! Set to zero to disable caching.
             break;
             // plus de lien vers la fiche détaillée sur le nom: il est fait sur la loupe
             /*
             			case "title":
             				// This will wrap the title in a link: to Single if in List (default), back
             
             				if($mode!="S") {
             					return $this->pi_list_linkSingle($this->internal["currentRow"]["title"],$this->internal["currentRow"]["uid"],1);
             					}
             				else return $this->internal["currentRow"][$fN]; */
         // plus de lien vers la fiche détaillée sur le nom: il est fait sur la loupe
         /*
         			case "title":
         				// This will wrap the title in a link: to Single if in List (default), back
         
         				if($mode!="S") {
         					return $this->pi_list_linkSingle($this->internal["currentRow"]["title"],$this->internal["currentRow"]["uid"],1);
         					}
         				else return $this->internal["currentRow"][$fN]; */
         case "nature":
         case "support":
         case "lang":
         case "topics":
             return txRecupLib("tx_vm19docsbase_" . $fN, "uid", "title", $this->internal["currentRow"][$fN]);
             break;
         case "int_author":
             //				return "toto: ".$this->internal["currentRow"][$fN];
             return txRecupLib("fe_users", "uid", "name", $this->internal["currentRow"][$fN]);
             break;
         case "tstamp":
         case "endtime":
             return getDateF($this->internal["currentRow"][$fN]);
             break;
         case "abstract":
             //return $this->pi_RTEcssText($this->internal["currentRow"][$fN]);
             /*
             				modifications apportées au traitements de la méthode getFieldContent($fN)
             				la ligne d'origine ci-dessus est générée automatiquement, mais dans ce cas, les liens (entres autres) insérés avec le RTE
             				ne sont pas affichés dans le FE correctement bien qu'ils soient enregistrés.
             				Pour que le changement ci-dessous fonctionne, il faut l'associer à la directive placée dans le gabarit principal suivante:
             				plugin.tx_macledextensionsansunderscores_pi1.RTEcontent_stdWrap.parseFunc < tt_content.text.20.parseFunc */
             return $this->cObj->stdWrap($this->pi_RTEcssText($this->internal["currentRow"][$fN]), $this->conf['RTEcontent_stdWrap.']);
             break;
         default:
             return $this->internal["currentRow"][$fN];
             break;
     }
 }
 function aff1text($rwt, $indent_n = 1)
 {
     $strt2d .= '<p style="padding-left:' . $indent_n * $this->text_indent . 'px">';
     switch ($rwt["rtt_attach_type"]) {
         case "MOD":
             $atttxt = "modifi&#233; par ";
             break;
         case "ABR":
             $atttxt = "abrog&#233; par ";
             break;
         case "REPL":
             $atttxt = "remplac&#233; par ";
             break;
         case "ANN":
             $atttxt = "annul&#233; par ";
             break;
         case "TRP":
             $atttxt = "transpos&#233; par ";
             break;
         case "APP":
             $atttxt = "appliqu&#233; par ";
             break;
         default:
             $atttxt = "";
     }
     if ($rwt["hidden"] != 1 && !$this->affok[$rwt['uid']]) {
         // affiche que si pas caché et si texte pas deja affiché
         if ($atttxt != "") {
             $strt2d .= '<span class="reg_modpar">' . $atttxt . " :<br/></span>";
         }
         $indent_n++;
         $strt2d .= '<span class="reg_natdat">' . '<a name="Anc' . $rwt["uid"] . '" title="uid=' . $rwt["uid"] . '">&#149; </a>' . ($rwt["url"] != "" ? '<a href="' . $rwt["url"] . '" target="_blank">' : "") . utf8_deconne(RecupLib("tx_vm19hnreglementation_nature", "uid", "title", $rwt["nature"])) . ($rwt["dat_approb"] > 0 ? " du " . getDateF($rwt["dat_approb"]) : "") . ($rwt["url"] != "" ? '</a>' : "") . " </span>";
         $strt2d .= $rwt["title"] != "" ? '<span class="reg_title">' . utf8_deconne($rwt["title"]) . "</span>" : "";
         $strt2d .= $rwt["number"] != "" ? '<br/><span class="reg_number">Num&#233;ro ' . $rwt["number"] . "</span>" : "";
         $strt2d .= $rwt["publication"] != "" ? '<br/><span class="reg_publication">Publi&#233; ' . utf8_deconne($rwt["publication"]) . "</span>" : "";
         $strt2d .= $rwt["fich_joint"] != "" ? '<br/><span class="reg_publication">T&#233;l&#233;charger le texte : <a href="' . $this->ChemUpLoads . $rwt["fich_joint"] . "\">" . $rwt["fich_joint"] . "</a></span>" : "";
         $strt2d .= $rwt["desc_2bf7363fc2"] != "" ? '<br/><span class="reg_desc"><a href="#" onclick="togdispt3t(this)" id=a3t' . $rwt["uid"] . ">\n\t\t\t<img src=\"" . $this->ChemImg . "f_right12.gif\" id=i3t" . $rwt["uid"] . "><em> Description </em></a>\n\t\t\t<div id=t3t" . $rwt["uid"] . " class=\"stDL3Thidd\">" . utf8_deconne($rwt["desc_2bf7363fc2"]) . "</div></span>" : "";
         $strt2d .= '<br/><span class="reg_fxhr">------------------------</span></p>';
     }
     //
     $sqlf = "SELECT * FROM tx_vm19hnreglementation_textes WHERE parent_text=" . $rwt["uid"] . " AND deleted=0 AND (starttime=0 OR starttime >= " . time() . ") AND (endtime=0 OR endtime <= " . time() . ") ORDER BY dat_approb,sorting";
     $rpat = msq($sqlf);
     //$strt2d.="<!-- $sqlf -->\n";
     while ($rwpat = mysql_fetch_array($rpat)) {
         $strt2d .= $this->aff1text($rwpat, $indent_n);
         // on réentre
     }
     $this->affok[$rwt['uid']] = true;
     // indique que texte deja affiché, pour pas qu'il s'affiche 2 fois.
     //$strt2d.="<HR/>";
     return $strt2d;
 }
 /**
  * [R�up�ation et traitement des champs]
  */
 function getFieldContent($fN)
 {
     $fieldValue = $this->internal["currentRow"][$fN];
     //		debug($fN);
     switch ($fN) {
         case "uid":
             return $this->pi_list_linkSingle($fieldValue, $this->internal["currentRow"]["uid"], 1);
             // The "1" means that the display of single items is CACHED! Set to zero to disable caching.
             break;
         case "small_img":
         case "big_img":
             if (file_exists($this->upload_img_folder . '/' . $fieldValue) && $fieldValue != "") {
                 // contruction du tableau du conf de l'image
                 // car utilisation de la m�hode cObj->IMAGE($conf) pour redimensionnement auto
                 // les param�res addistionnels (Align et maxW notamment, sont plac�s dans le ext_typoscript_setup.txt)
                 $ConfI["file"] = $this->upload_img_folder . '/' . $fieldValue;
                 $ConfI["file."]["maxW"] = $this->conf[$fN . "MaxWidth"];
                 return str_replace(">", ' class="actu' . $fN . '">', $this->cObj->IMAGE($ConfI));
                 //return '<img src="'.$this->upload_img_folder.'/'.$fieldValue.'" align="left" border="0">';
                 // voir http://typo3api.ueckermann.de/classtslib__cObj.html#a69 pour plus d'info sue les param
             } elseif ($fN == "small_img") {
                 //return '<img src="'.$this->conf["extCurDir"].'fleche_puce.gif" class="picto" />';
                 // Diabne veut plus du picto
                 return "";
             } else {
                 return "";
             }
             break;
         case "abstract":
         case "bodytext":
             //return $this->pi_RTEcssText($fieldValue);
             /*
             				modifications apport�s au traitements de la m�hode getFieldContent($fN)
             				la ligne d'origine ci-dessus est g��� automatiquement, mais dans ce cas, les liens (entres autres) ins�� avec le RTE
             				ne sont pas affich� dans le FE correctement bien qu'ils soient enregistr�.
             				Pour que le changement ci-dessous fonctionne, il faut l'associer �la directive plac� dans le gabarit principal suivante:
             				plugin.tx_macledextensionsansunderscores_pi1.RTEcontent_stdWrap.parseFunc < tt_content.text.20.parseFunc */
             return $this->cObj->stdWrap($this->pi_RTEcssText($fieldValue), $this->conf['RTEcontent_stdWrap.']);
             break;
         case "starttime":
             if ($fieldValue == "0") {
                 $fieldValue = $this->internal["currentRow"]["tstamp"];
             }
         case "tstamp":
         case "endtime":
             if ($fieldValue != "0") {
                 return getDateF($fieldValue);
             }
             break;
         case "author":
             $fieldValue = txRecupLib("fe_users", "uid", "name", $fieldValue);
             if (!$fieldValue) {
                 // si pas d'auteur interne saisit, renvoie le be_user cr�teur
                 $fieldValue = txRecupLib("be_users", "uid", "realName", $this->internal["currentRow"]["cruser_id"]);
             }
             return $fieldValue ? "Auteur : " . $fieldValue : "";
             break;
         case "email":
             $fieldValue = txRecupLib("fe_users", "uid", "email", $this->internal["currentRow"]["author"]);
             // si pas de mail et que l'auteur interne n'existe pas non plus, on renvoe le mail du be_user createur
             if (!$fieldValue && !txRecupLib("fe_users", "uid", "name", $this->internal["currentRow"]["author"])) {
                 $fieldValue = txRecupLib("be_users", "uid", "email", $this->internal["currentRow"]["cruser_id"]);
             }
             return $fieldValue ? $fieldValue : "";
             break;
         case "document":
             if ($fieldValue != "") {
                 $CfN = $this->upload_doc_folder . '/' . $fieldValue;
                 $fieldValue .= '<span class="actdoc">';
                 $fieldValue .= DFSIL($CfN);
                 $fieldValue .= '&nbsp;<a href="' . $CfN . '" target="_blank"><img src="' . $this->ChemImg . 'telecharger.gif" class="picto" title="' . $this->pi_getLL("download", "[download]") . '"></a></span>';
             }
             return $fieldValue;
             break;
         case "bimg_credit":
             if ($fieldValue != "") {
                 $fieldValue = $this->pi_getLL("CredPhot", "[(C) Photo]") . $fieldValue;
             }
             return $fieldValue;
             break;
         default:
             return $fieldValue;
             break;
     }
 }
 /**
  * [Put your description here]
  */
 function getFieldContent($fN, $mode = "L")
 {
     switch ($fN) {
         case "uid":
             return $this->internal["currentRow"]["uid"];
             break;
         case "editor":
             return txRecupLib("tx_dlcubehnshop_editors", "uid", "name", $this->internal["currentRow"][$fN]);
             break;
         case "support":
             return txRecupLib("tx_vm19docsbase_support", "uid", "title", $this->internal["currentRow"][$fN]);
             break;
         case "price":
             // number_format ( float number [, int decimals [, string dec_point, string thousands_sep]] )
             if ($this->internal["currentRow"][$fN] > 0) {
                 return number_format(round($this->internal["currentRow"][$fN], 2), 2, ",", " ") . "&nbsp;&#8364;";
             } else {
                 return $this->pi_getLL("gratos", "[gratos]");
             }
             break;
         case "tva":
             return $this->internal["currentRow"][$fN] . "&nbsp;&#037;";
             break;
         case "weight":
             return $this->internal["currentRow"][$fN] . " g";
             break;
         case "technicaldegree":
             for ($i = 1; $i <= $this->internal["currentRow"][$fN]; $i++) {
                 $imf .= '<img src="' . $this->conf["iconDir"] . 'fer_cheval15.gif" class="picto">&nbsp;';
             }
             return $imf;
             break;
         case "nbpages":
             return $this->internal["currentRow"][$fN] > 0 ? $this->internal["currentRow"][$fN] . "&nbsp;pages" : "";
             break;
         case "tstamp":
         case "crdate":
         case "endtime":
             return getDateF($this->internal["currentRow"][$fN]);
             break;
         case "designation":
         case "descdetail":
             //return $this->pi_RTEcssText($this->internal["currentRow"][$fN]);
             /*
             				modifications apport?s au traitements de la m?hode getFieldContent($fN)
             				la ligne d'origine ci-dessus est g??? automatiquement, mais dans ce cas, les liens (entres autres) ins?? avec le RTE
             				ne sont pas affich? dans le FE correctement bien qu'ils soient enregistr?.
             				Pour que le changement ci-dessous fonctionne, il faut l'associer ?la directive plac? dans le gabarit principal suivante:
             				plugin.tx_macledextensionsansunderscores_pi1.RTEcontent_stdWrap.parseFunc < tt_content.text.20.parseFunc */
             return $this->cObj->stdWrap($this->pi_RTEcssText($this->internal["currentRow"][$fN]), $this->conf['RTEcontent_stdWrap.']);
             break;
         default:
             return $this->internal["currentRow"][$fN];
             break;
     }
 }