source: trunk/web/app/mods/e_news.php @ 1

Last change on this file since 1 was 1, checked in by dj3c1t, 12 years ago

import initial

File size: 602 bytes
Line 
1<?php
2
3  function e_news($env)
4  { $path = array("root", "news");
5    $depth = 1;
6    if(isset($_GET[$env->param("categorie")]))
7    { if(strlen($_GET[$env->param("categorie")]) > 0) $path[] = (int)$_GET[$env->param("categorie")];
8      $depth = 0;
9    }
10    if(($env->out["categories"] = $env->data->all_news_categories()) !== false)
11    { if(($env->out["news"] = $env->data->news($path, $env->start, $depth, true)) !== false)
12      {
13      }
14      else $env->erreur .= "<br>Impossible de lire les news";
15    }
16    else $env->erreur .= "<br>Impossible de lire la liste des categories de news";
17  }
18
19?>
Note: See TracBrowser for help on using the repository browser.