fhiiqm/prod_hier.php
changeset 29 72f79dab938e
parent 28 8d8bce56918f
child 34 fc60ef80a7ad
equal deleted inserted replaced
28:8d8bce56918f 29:72f79dab938e
    10     error_reporting(E_ALL ^ E_NOTICE);
    10     error_reporting(E_ALL ^ E_NOTICE);
    11     
    11     
    12     session_start();
    12     session_start();
    13     if (! isset($_SESSION["userid"]))
    13     if (! isset($_SESSION["userid"]))
    14     { 
    14     { 
    15         include_once ("inc/func_lib.inc.php");	
    15         include_once ($_SERVER["DOCUMENT_ROOT"]."/fhiiqm/inc/func_lib.inc.php");	
    16         login($_SERVER["PHP_SELF"]);
    16         login($_SERVER["PHP_SELF"]);
    17         exit;
    17         exit;
    18     }
    18     }
    19     
    19     
    20     if (is_null($_SESSION["recht"]) || (!is_null($_SESSION["recht"]) && !in_array("pr",$_SESSION["recht"]) && !in_array("pe",$_SESSION["recht"])))
    20     if (is_null($_SESSION["recht"]) || (!is_null($_SESSION["recht"]) && !in_array("pr",$_SESSION["recht"]) && !in_array("pe",$_SESSION["recht"])))
    36 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    36 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    37 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    37 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    38 
    38 
    39 <head>
    39 <head>
    40 	<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
    40 	<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
    41    	<link href="css/db.css" rel="STYLESHEET" type="TEXT/CSS" media="screen" /> 
    41    	<link href="/fhiiqm/css/db.css" rel="STYLESHEET" type="TEXT/CSS" media="screen" /> 
    42    	<link href="css/db_print.css" rel="STYLESHEET" type="TEXT/CSS" media="print" /> 
    42    	<link href="/fhiiqm/css/db_print.css" rel="STYLESHEET" type="TEXT/CSS" media="print" /> 
    43 
    43 
    44 	<title>Produkthierarchie</title>
    44 	<title>Produkthierarchie</title>
    45 </head>
    45 </head>
    46 
    46 
    47 <body>
    47 <body>
    49 <?php
    49 <?php
    50     echo "&nbsp;";  
    50     echo "&nbsp;";  
    51     echo "<div class=\"float-br smaller\" valign='top'>";
    51     echo "<div class=\"float-br smaller\" valign='top'>";
    52     echo "&nbsp;&nbsp;&nbsp;user: " . $_SESSION["userid"];
    52     echo "&nbsp;&nbsp;&nbsp;user: " . $_SESSION["userid"];
    53     echo "&nbsp;&nbsp;&nbsp;<a class='sc' href='/fhiiqm/logout.php' title='Session beenden'>logout</a></div>\n";
    53     echo "&nbsp;&nbsp;&nbsp;<a class='sc' href='/fhiiqm/logout.php' title='Session beenden'>logout</a></div>\n";
    54     echo "<div class=\"float-r\"><img src=\"img/node-tree.png\" border=\"0\" alt=\"Produkte\" title=\"Produkte\"/></div>\n";
    54     echo "<div class=\"float-r\"><img src=\"/fhiiqm/img/node-tree.png\" border=\"0\" alt=\"Produkte\" title=\"Produkte\"/></div>\n";
    55 
    55 
    56     $prods = $_POST['prods'];
    56     $prods = $_POST['prods'];
    57     $submit = $_POST['search'];
    57     $submit = $_POST['search'];
    58 
    58 
    59     include_once("inc/dbconnect.inc.php");
    59     include_once($_SERVER["DOCUMENT_ROOT"]."/fhiiqm/inc/dbconnect.inc.php");
    60 	$dbc = new dbconnection();
    60 	$dbc = new dbconnection();
    61 
    61 
    62     
    62     
    63     if (!$submit)
    63     if (!$submit)
    64     {
    64     {
   140         echo "</form>\n";	
   140         echo "</form>\n";	
   141         echo "</div>\n";
   141         echo "</div>\n";
   142     }
   142     }
   143     else
   143     else
   144     {
   144     {
   145         echo "<p class='sc'>&nbsp;&nbsp;&nbsp;<a href=\"prod_hier.php\" target=\"_self\" title=\"Produkthierarchie\">neue Auswahl Produkthierarchie</a></p>\n";    
   145         echo "<p class='sc'>&nbsp;&nbsp;&nbsp;<a href=\"/fhiiqm/prod_hier.php\" target=\"_self\" title=\"Produkthierarchie\">neue Auswahl Produkthierarchie</a></p>\n";    
   146         echo "<div align='center'>\n";
   146         echo "<div align='center'>\n";
   147         if ($prods['ber'] || $prods['grp'])
   147         if ($prods['ber'] || $prods['grp'])
   148         {
   148         {
   149             if (!$prods['grp']) $prods['grp']=0;
   149             if (!$prods['grp']) $prods['grp']=0;
   150             if (!$prods['ber']) $prods['ber']=0;
   150             if (!$prods['ber']) $prods['ber']=0;
   198 /*    		if ($result = $dbc -> querySingleItem("SELECT COUNT(*) FROM Produkt"))
   198 /*    		if ($result = $dbc -> querySingleItem("SELECT COUNT(*) FROM Produkt"))
   199 		{
   199 		{
   200 			echo "<p>Tabelle 'produkt' enthaelt $result Eintraege</p>\n";
   200 			echo "<p>Tabelle 'produkt' enthaelt $result Eintraege</p>\n";
   201 		} */
   201 		} */
   202         echo "</div>\n";
   202         echo "</div>\n";
   203         echo "<p class='sc'>&nbsp;&nbsp;&nbsp;<a href=\"prod_hier.php\" target=\"_self\" title=\"Produkthierarchie\">neue Auswahl Produkthierarchie</a></p>\n";    
   203         echo "<p class='sc'>&nbsp;&nbsp;&nbsp;<a href=\"/fhiiqm/prod_hier.php\" target=\"_self\" title=\"Produkthierarchie\">neue Auswahl Produkthierarchie</a></p>\n";    
   204         if (!is_null($_SESSION["recht"]) && in_array("pe",$_SESSION["recht"]))
   204         if (!is_null($_SESSION["recht"]) && in_array("pe",$_SESSION["recht"]))
   205             echo "<p class='sc'>&nbsp;&nbsp;&nbsp;<a href=\"produkt_ins.php\" target=\"_self\" title=\"Produkt erfassen\">Produkt erfassen</a></p>\n";    
   205             echo "<p class='sc'>&nbsp;&nbsp;&nbsp;<a href=\"/fhiiqm/produkt_ins.php\" target=\"_self\" title=\"Produkt erfassen\">Produkt erfassen</a></p>\n";    
   206     }
   206     }
   207 
   207 
   208 ?>
   208 ?>
   209 </body>
   209 </body>
   210 </html>
   210 </html>