2004-10-20 23:06:45 +02:00
|
|
|
|
<?php
|
2004-07-05 14:46:12 +02:00
|
|
|
|
/* Copyright (C) 2001-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
2005-01-03 20:21:51 +01:00
|
|
|
|
* Copyright (C) 2004-2005 Laurent Destailleur <eldy@users.sourceforge.net>
|
2002-04-29 21:47:03 +02:00
|
|
|
|
*
|
|
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
|
|
* (at your option) any later version.
|
|
|
|
|
|
*
|
|
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
|
|
*
|
|
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
|
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
|
|
*
|
2002-06-20 21:25:15 +02:00
|
|
|
|
* $Id$
|
|
|
|
|
|
* $Source$
|
|
|
|
|
|
*
|
2002-04-29 19:53:37 +02:00
|
|
|
|
*/
|
2005-01-03 20:21:51 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
|
\file htdocs/index.php
|
|
|
|
|
|
\brief Page accueil par defaut
|
|
|
|
|
|
\version $Revision$
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
2003-09-11 22:18:51 +02:00
|
|
|
|
require("./pre.inc.php");
|
2002-04-29 19:53:37 +02:00
|
|
|
|
|
2005-02-27 17:45:59 +01:00
|
|
|
|
$user->getrights('');
|
|
|
|
|
|
|
2005-01-03 20:21:51 +01:00
|
|
|
|
|
|
|
|
|
|
// Simule le menu par d<>faut sur Home
|
|
|
|
|
|
$_GET["mainmenu"]="home";
|
|
|
|
|
|
|
|
|
|
|
|
|
2002-04-29 19:53:37 +02:00
|
|
|
|
llxHeader();
|
2003-02-11 14:24:02 +01:00
|
|
|
|
|
2004-07-25 17:31:16 +02:00
|
|
|
|
$userstring=$user->prenom . ' ' . $user->nom .' ['.$user->code.']';
|
|
|
|
|
|
print_fiche_titre($langs->trans("WelcomeString",dolibarr_print_date(mktime(),"%A %d %B %Y"),$userstring), '<a href="about.php">'.$langs->trans("About").'</a>');
|
|
|
|
|
|
|
2004-07-26 16:38:34 +02:00
|
|
|
|
if (defined("MAIN_MOTD") && strlen(trim(MAIN_MOTD)))
|
|
|
|
|
|
{
|
|
|
|
|
|
print "<br>".nl2br(MAIN_MOTD);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2004-06-26 19:43:07 +02:00
|
|
|
|
print "<br>\n";
|
2002-04-29 19:53:37 +02:00
|
|
|
|
|
2005-01-03 20:21:51 +01:00
|
|
|
|
|
2003-02-13 17:58:48 +01:00
|
|
|
|
/*
|
2005-02-27 17:45:59 +01:00
|
|
|
|
* Affichage des boites
|
2003-02-13 17:58:48 +01:00
|
|
|
|
*
|
|
|
|
|
|
*/
|
2005-02-27 17:45:59 +01:00
|
|
|
|
include_once("./boxes.php");
|
|
|
|
|
|
$infobox=new InfoBox($db);
|
|
|
|
|
|
$boxes=$infobox->listboxes("0"); // 0 = valeur pour la page accueil
|
2003-06-17 18:00:53 +02:00
|
|
|
|
|
2005-02-27 17:45:59 +01:00
|
|
|
|
$NBCOLS=2; // Nombre de colonnes pour les boites
|
2003-06-17 18:00:53 +02:00
|
|
|
|
print '<table width="100%">';
|
2003-02-13 18:15:40 +01:00
|
|
|
|
for ($ii=0, $ni=sizeof($boxes); $ii<$ni; $ii++)
|
|
|
|
|
|
{
|
2005-02-27 17:45:59 +01:00
|
|
|
|
if ($ii % $NBCOLS == 0) print "<tr>\n";
|
2003-11-09 18:24:14 +01:00
|
|
|
|
print '<td valign="top" width="50%">';
|
2003-06-17 18:00:53 +02:00
|
|
|
|
|
2005-02-27 17:45:59 +01:00
|
|
|
|
// Affichage boite ii
|
2005-02-27 18:57:21 +01:00
|
|
|
|
include_once(DOL_DOCUMENT_ROOT."/includes/boxes/".$boxes[$ii].".php");
|
2005-02-27 17:45:59 +01:00
|
|
|
|
$box=new $boxes[$ii]();
|
|
|
|
|
|
$box->loadBox();
|
|
|
|
|
|
$box->showBox();
|
2003-02-13 17:58:48 +01:00
|
|
|
|
|
2005-02-27 17:45:59 +01:00
|
|
|
|
print "</td>";
|
|
|
|
|
|
if ($ii % $NBCOLS == ($NBCOLS-1)) print "</tr>\n";
|
|
|
|
|
|
}
|
|
|
|
|
|
if ($ii % $NBCOLS == ($NBCOLS-1)) print "</tr>\n";
|
2003-06-17 18:00:53 +02:00
|
|
|
|
print "</table>";
|
|
|
|
|
|
|
2005-02-27 17:45:59 +01:00
|
|
|
|
|
2003-02-13 17:58:48 +01:00
|
|
|
|
$db->close();
|
2002-04-29 19:53:37 +02:00
|
|
|
|
|
2002-05-10 14:04:12 +02:00
|
|
|
|
llxFooter("<em>Dernière modification $Date$ révision $Revision$</em>");
|
2002-04-29 19:53:37 +02:00
|
|
|
|
?>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|