dolibarr/htdocs/main.inc.php3

110 lines
3.1 KiB
PHP
Raw Normal View History

2002-04-30 12:56:25 +02:00
<?PHP
/* Copyright (C) 2002 Rodolphe Quiedeville <rodolphe@quiedeville.org>
*
* $Id$
* $Source$
*
* 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.
*
*/
require ($GLOBALS["DOCUMENT_ROOT"]."/conf/conf.class.php3");
require ($GLOBALS["DOCUMENT_ROOT"]."/lib/mysql.lib.php3");
2002-04-30 17:54:32 +02:00
2002-04-30 12:56:25 +02:00
require ($GLOBALS["DOCUMENT_ROOT"]."/lib/functions.inc.php3");
2002-04-30 17:54:32 +02:00
require ($GLOBALS["DOCUMENT_ROOT"]."/user.class.php3");
require ($GLOBALS["DOCUMENT_ROOT"]."/lib/product.class.php3");
2002-04-30 12:56:25 +02:00
$conf = new Conf();
$db = new Db();
$user = new User($db);
$user->fetch($GLOBALS["REMOTE_USER"]);
2002-05-06 21:10:48 +02:00
$bc[0]="class=\"impair\"";
$bc[1]="class=\"pair\"";
2002-04-30 17:36:13 +02:00
function llxFooter($foot='') {
print "</TD></TR>";
/*
*
*/
print "</TABLE>\n";
print "$foot<br>";
print '[<a href="http://savannah.gnu.org/bugs/?group_id=1915">Bug report</a>]&nbsp;';
print '[<a href="http://savannah.gnu.org/projects/dolibarr/">Source Code</a>]&nbsp;';
print "</BODY></HTML>";
}
2002-04-30 12:56:25 +02:00
2002-05-04 01:01:45 +02:00
function top_menu($head) {
global $user, $conf;
print "<HTML><HEAD>";
print $head;
print "<META HTTP-EQUIV=\"Content-Type\" CONTENT=\"text/html; charset=iso-8859-1\">\n";
2002-05-04 23:28:42 +02:00
print '<LINK REL="stylesheet" TYPE="text/css" HREF="/'.$conf->css.'">';
2002-05-04 01:01:45 +02:00
print "</HEAD>\n";
print '<BODY BGCOLOR="#c0c0c0" TOPMARGIN="0" BOTTOMMARGIN="0" LEFTMARGIN="0" RIGHTMARGIN="0" MARGINHEIGHT="0" MARGINWIDTH="0">';
2002-05-06 21:10:48 +02:00
/*
* Barre superieure
*
*/
2002-05-04 01:01:45 +02:00
2002-05-06 21:10:48 +02:00
print '<TABLE border="0" width="100%" bgcolor="#000000" cellspacing="0" cellpadding="0">';
print '<tr><td>';
print '<TABLE border="0" width="100%" cellspacing="1" cellpadding="2">';
2002-05-04 01:01:45 +02:00
print "<TR>";
2002-05-06 21:10:48 +02:00
print '<TD width="15%" class="menu" align="center"><A class="menu" href="/">Accueil</A></TD>';
2002-05-04 01:01:45 +02:00
2002-05-06 21:10:48 +02:00
print '<TD width="15%" class="menu" align="center">';
2002-05-04 01:01:45 +02:00
if ($user->comm > 0) {
2002-05-06 21:10:48 +02:00
print '<A class="menu" href="../comm/">Commercial</A></TD>';
2002-05-04 01:01:45 +02:00
} else {
2002-05-06 21:10:48 +02:00
print '-';
2002-05-04 01:01:45 +02:00
}
2002-05-06 21:10:48 +02:00
print '<TD width="15%" class="menu" align="center">';
if ($user->compta > 0) {
print '<A class="menu" href="../compta/">Compta</A></TD>';
} else {
print '-';
}
2002-05-04 01:01:45 +02:00
2002-05-06 21:10:48 +02:00
print '<TD width="15%" class="menu" align="center">-</TD>';
print '<TD width="15%" class="menu" align="center">-</TD>';
print '<TD width="15%" class="menu" align="center">-</TD>';
print '<TD width="10%" class="menu" align="center">'.$user->code.'</td>';
print '</TR>';
print '</table>';
print '</td></tr>';
print '</table>';
/*
* Table principale
*
*/
print '<TABLE border="0" width="100%">';
2002-05-04 01:01:45 +02:00
}
2002-04-30 12:56:25 +02:00
?>