dolibarr/htdocs/index.php

86 lines
1.9 KiB
PHP
Raw Normal View History

2002-04-29 19:53:37 +02:00
<?PHP
2003-02-11 14:24:02 +01:00
/* Copyright (C) 2001-2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
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
*/
2003-09-11 22:18:51 +02:00
require("./pre.inc.php");
2002-04-29 19:53:37 +02:00
llxHeader();
2003-02-11 14:24:02 +01:00
2003-07-24 13:56:55 +02:00
print_fiche_titre( "Dolibarr ".DOL_VERSION,'<a href="about.php">A propos</a>');
2002-04-29 19:53:37 +02:00
2003-09-13 15:39:12 +02:00
print '<div class="titre">Connect<63> en tant que : <b>' . $user->prenom . ' ' . $user->nom .'</b> ['.$user->code.']</div>';
2003-06-24 16:46:08 +02:00
print "<br>";
/*
* Boites
*
*/
2003-08-06 11:12:47 +02:00
$user->getrights('');
$sql = "SELECT b.rowid, b.box_id, d.file FROM ".MAIN_DB_PREFIX."boxes as b, ".MAIN_DB_PREFIX."boxes_def as d WHERE b.box_id = d.rowid";
$result = $db->query($sql);
if ($result)
{
$num = $db->num_rows();
2003-02-13 18:15:40 +01:00
$j = 0;
2003-02-13 18:15:40 +01:00
while ($j < $num)
{
2003-02-13 18:15:40 +01:00
$obj = $db->fetch_object($j);
$boxes[$j] = "includes/boxes/".$obj->file;
$j++;
}
}
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++)
{
2003-07-24 13:56:55 +02:00
if ($ii % 2 == 0)
2003-06-17 18:00:53 +02:00
{
print "<tr>\n";
}
print '<td valign="top" width="50%">';
2003-02-13 18:15:40 +01:00
include($boxes[$ii]);
2003-06-17 18:00:53 +02:00
print "</td>";
if ( ($ii -1) / 3 == 0)
{
print "</tr>\n";
}
2003-02-13 18:15:40 +01:00
}
2003-06-17 18:00:53 +02:00
print "</table>";
$db->close();
2002-04-29 19:53:37 +02:00
2002-05-10 14:04:12 +02:00
llxFooter("<em>Derni&egrave;re modification $Date$ r&eacute;vision $Revision$</em>");
2002-04-29 19:53:37 +02:00
?>