Status: " . $status . "
"; } if ((($document_id) or ($id)) and ($status != "bestilling") and (!$fane_id)){ if ($id) { $document_id = $id; } $result_status = @mysql_query("SELECT type FROM " . $editorlighttable . " WHERE id='" . $document_id . "' "); $myrow_status = @mysql_fetch_array($result_status); $status = $myrow_status['type']; } ?> <? if ($product_id){ $resultheader = mysql_query("SELECT * FROM " . $produkttable . " WHERE id='" . $product_id . "'"); $myrowheader = mysql_fetch_array($resultheader); if (substr($myrowheader['navigation'],0,3) == "<#>") { $title .= substr($myrowheader['navigation'],11); } else { $title .= $myrowheader['navigation']; } $title .= " - "; } $title .= "KBC Profiler & Tilbehør A/S"; echo $title; ?>
KBC Profiler & Tilbehør A/S"; } if ( (($fane_id) OR ($id == "256" )) AND (!$header_set) ){ echo "KBC Profiler & Tilbehør A/S"; } if ($product_id){ $resultheader = mysql_query("SELECT * FROM " . $produkttable . " WHERE id='" . $product_id . "'"); $myrowheader = mysql_fetch_array($resultheader); if (substr($myrowheader['navigation'],0,3) == "<#>") { echo "" . substr($myrowheader['navigation'],11) . ""; } else { echo "" . $myrowheader['navigation'] . ""; } } ?> Tilbage til forsiden
Forside "; } if ($product_id) { $path = "Forside "; // hent level informationer for valgte produkt $result_path = @mysql_query("SELECT id, gfx, navigation, level_1, level_2, level_3, level_4, level_5, level_6, level_7 FROM " . $produkttable . " WHERE id='" . $product_id . "' "); $myrow_path = @mysql_fetch_array($result_path); if ($status != "bestilling") { $status = $myrow_path['gfx']; } for ($levels = 1; $levels <= $numlevels; $levels++) { $thislevel = "level_" . $levels; $nextlevel = "level_" . ($levels+1); $lastlevel = "level_" . ($levels+2); // echo $thislevel . "
"; // echo $myrow_path[$thislevel] . "
"; if ($myrow_path[$thislevel] > "0") { $sql_selected_show_level .= $thislevel . "='" . $myrow_path[$thislevel] . "' AND "; } if ($myrow_path[$thislevel] == "0") { $sql_selected_last_level = $nextlevel . "='0'"; $break = "true"; } else { $sql_selected_last_level = $nextlevel . "='0'"; } if ($break) { break; } else { $sql_selected_path = $sql_selected_show_level . $sql_selected_last_level; $result_show_path = @mysql_query("SELECT id, navigation FROM " . $produkttable . " WHERE " . $sql_selected_path . " "); $myrow_show_path = @mysql_fetch_array($result_show_path); if (substr($myrow_show_path['navigation'],0,3) == "<#>") { $navigation = substr($myrow_show_path['navigation'],11); } else { $navigation = $myrow_show_path['navigation']; } $path .= "-> " . $navigation . " "; } } } if (($document_id) AND ($document != "256") ) { $path = "Forside "; $path .= "-> "; $result_path = mysql_query("SELECT id, emneheader FROM " . $editorlighttable . " WHERE id='" . $document_id . "'"); $myrow_path = @mysql_fetch_array($result_path); $path .= "" . $myrow_path['emneheader'] . ""; } if ($login != "ask") { echo $path . " |  "; } // login if ((!$login) AND (!$thisuser)){ $login_link = "?login=ask"; if ($product_id) { $login_link .= "&product_id=" . $product_id . ""; } if ($document_id) { $login_link .= "&document_id=" . $document_id . ""; } echo "Kunde adgang"; } if ($thisuser) { $login_link = "?login=exit"; if ($product_id) { $login_link .= "&product_id=" . $product_id . ""; $ordre_link .= "&product_id=" . $product_id . ""; } if ($document_id) { $login_link .= "&document_id=" . $document_id . ""; $ordre_link .= "&document_id=" . $document_id . ""; } echo "Log ud"; echo "  |  "; echo "Bestilling"; } if ($login == "ask") { $login_link = "?login="; if ($product_id) { $login_link .= "&product_id=" . $product_id . ""; } if ($document_id) { $login_link .= "&document_id=" . $document_id . ""; } echo "Kunde adgang  "; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } // ?>
\n\n"; //include "beesite/inc.checktimer.php"; // returnerer $showcurrent true/false if ((!$document_id) AND (!$product_id)) { // vis navigation til første niveau - hvis der ikke er valgt noget (forsiden) $status = "forside"; echo "\n"; echo "\n"; echo "\n"; // TD til thumbs echo "\n"; // TD til højremargin echo "\n"; // TD til level 1 echo "\n"; // TD til level 2 echo "\n"; // TD til højremargin echo "\n"; $sqlid = "SELECT * FROM " . $editorlighttable . " ORDER BY level_1, level_2"; $resultid = mysql_query($sqlid); $numid = mysql_num_rows($resultid); while ($myrowid = mysql_fetch_array($resultid)) { $shownavigation = false; if ($korrektur) { if (($myrowid['statusbody'] == '1') OR ($myrowid['statusbody'] == '3')) { // Vis aktive + korrektur $shownavigation = true; } } else { if ($myrowid['statusbody'] == '1'){ // Vis aktive $shownavigation = true; } } if (($myrowid['level_1'] > '0') AND ($myrowid['level_2'] == '0') AND ($shownavigation == 'true')) { if ($myrowid['type'] == 'produktfolder'){ // hent product_id fra databasen $result_product_id = @mysql_query("SELECT id, statusmini, imagename, level_1 FROM " . $produkttable . " WHERE id='" . $myrowid['href'] . "' "); $myrow_product_id = @mysql_fetch_array($result_product_id); echo "\n"; echo "\n"; echo "\n"; // luft echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } // 1 2 3 // visning af foldere if (($myrowid['type'] == 'folder')){ echo "\n"; echo "\n"; echo "\n"; // luft echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } if (($myrowid['type'] == 'doc') AND ($shownavigation == 'true')){ // definer timestampOn $timestampOn = $myrowid['timestampOn']; $year = substr ($timestampOn, 0, 4); $month = substr ($timestampOn,5,2); $day = substr ($timestampOn,8,2); $hour = substr ($timestampOn,11,2); $minutes = substr ($timestampOn,14,2); $seconds = substr ($timestampOn,17,2); $doctimestampOn = mktime($hour,$minutes,$seconds,$month,$day,$year); $currenttimestamp = time(); if ($doctimestampOn < $currenttimestamp) { echo "\n"; echo "\n"; echo "\n"; // luft echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } } if (($myrowid['type'] == 'iframe') AND ($shownavigation == 'true')){ // definer timestampOn $timestampOn = $myrowid['timestampOn']; $year = substr ($timestampOn, 0, 4); $month = substr ($timestampOn,5,2); $day = substr ($timestampOn,8,2); $hour = substr ($timestampOn,11,2); $minutes = substr ($timestampOn,14,2); $seconds = substr ($timestampOn,17,2); $doctimestampOn = mktime($hour,$minutes,$seconds,$month,$day,$year); $currenttimestamp = time(); if ($doctimestampOn < $currenttimestamp) { echo "\n"; echo "\n"; echo "\n"; // luft echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } } } } echo "
"; if ($myrow_product_id['imagename']) { echo ""; echo ""; } echo " " . nl2br($myrowid['emneheader']) . " "; if ($myrow_product_id['statusmini'] == "1") { $result_navigation = @mysql_query("SELECT id, status, navigation FROM " . $produkttable . " WHERE level_1='" . $myrow_product_id['level_1'] . "' AND level_2>'0' AND level_3 ='0' ORDER BY navigation"); while ($myrow_navigation = @mysql_fetch_array($result_navigation)) { $shownavigation = false; if ($korrektur) { if (($myrow_navigation['status'] == '1') OR ($myrow_navigation['status'] == '3')) { // Vis aktive + korrektur $shownavigation = true; } } else { if ($myrow_navigation['status'] == '1'){ // Vis aktive $shownavigation = true; } } if ($shownavigation == true) { if (substr($myrow_navigation['navigation'],0,3) == "<#>") { $navigation = substr($myrow_navigation['navigation'],11); echo "" . nl2br($navigation) . "
"; } else { echo "" . nl2br($myrow_navigation['navigation']) . "
"; } } } } echo "
 
 
"; if ($myrowid['miniature']) { echo ""; } echo " " . nl2br($myrowid['emneheader']) . " "; echo " 
 
\n"; if ($myrowid['id'] == '363') { echo ""; } else { echo" "; } echo " " . nl2br($myrowid['emneheader']) . "  
 
\n"; if ($myrowid['id'] == '56') { echo ""; } else { echo" "; } echo " " . nl2br($myrowid['emneheader']) . "  
 
\n"; } // slut på rutine til visning af navigation til forsiden if ($document_id) { // vis navigation til første niveau - hvis der ikke er valgt noget (forsiden) $status = "forside"; echo "\n"; echo "\n"; echo "\n"; // TD til thumbs echo "\n"; // TD til højremargin echo "\n"; // TD til level 1 echo "\n"; // TD til level 2 echo "\n"; // TD til højremargin echo "\n"; $sqlid = "SELECT * FROM " . $editorlighttable . " ORDER BY level_1, level_2"; $resultid = mysql_query($sqlid); $numid = mysql_num_rows($resultid); while ($myrowid = mysql_fetch_array($resultid)) { $shownavigation = false; if ($korrektur) { if (($myrowid['statusbody'] == '1') OR ($myrowid['statusbody'] == '3')) { // Vis aktive + korrektur $shownavigation = true; } } else { if ($myrowid['statusbody'] == '1'){ // Vis aktive $shownavigation = true; } } if (($myrowid['level_1'] > '0') AND ($myrowid['level_2'] == '0') AND ($shownavigation == 'true')) { if ($myrowid['type'] == 'produktfolder'){ // hent product_id fra databasen $result_product_id = @mysql_query("SELECT id, statusmini, imagename, level_1 FROM " . $produkttable . " WHERE id='" . $myrowid['href'] . "' "); $myrow_product_id = @mysql_fetch_array($result_product_id); echo "\n"; echo "\n"; echo "\n"; // luft echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } if (($myrowid['type'] == 'folder')){ echo "\n"; echo "\n"; echo "\n"; // luft echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } if (($myrowid['type'] == 'doc') AND ($shownavigation == 'true')){ // definer timestampOn $timestampOn = $myrowid['timestampOn']; $year = substr ($timestampOn, 0, 4); $month = substr ($timestampOn,5,2); $day = substr ($timestampOn,8,2); $hour = substr ($timestampOn,11,2); $minutes = substr ($timestampOn,14,2); $seconds = substr ($timestampOn,17,2); $doctimestampOn = mktime($hour,$minutes,$seconds,$month,$day,$year); $currenttimestamp = time(); if ($doctimestampOn < $currenttimestamp) { echo "\n"; echo "\n"; echo "\n"; // luft echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; } } } } echo "
"; if ($myrow_product_id['imagename']) { echo ""; } echo "  " . nl2br($myrowid['emneheader']) . " "; if ($myrow_product_id['statusmini'] == "1") { $result_navigation = @mysql_query("SELECT id, status, navigation FROM " . $produkttable . " WHERE level_1='" . $myrow_product_id['level_1'] . "' AND level_2>'0' AND level_3 ='0' ORDER BY navigation"); while ($myrow_navigation = @mysql_fetch_array($result_navigation)) { $shownavigation = false; if ($korrektur) { if (($myrow_navigation['status'] == '1') OR ($myrow_navigation['status'] == '3')) { // Vis aktive + korrektur $shownavigation = true; } } else { if ($myrow_navigation['status'] == '1'){ // Vis aktive $shownavigation = true; } } if ($shownavigation == true) { if (substr($myrow_navigation['navigation'],0,3) == "<#>") { $navigation = substr($myrow_navigation['navigation'],11); echo "" . nl2br($navigation) . "
"; } else { echo "" . nl2br($myrow_navigation['navigation']) . "
"; } } } } echo "
 
 
"; if ($myrowid['type'] == 'produktfolder') { $resultimage = @mysql_query("SELECT id, imagename FROM " . $produkttable . " WHERE id='" . $myrowid['href'] . "'"); $myrowimage = @mysql_fetch_array($resultimage); if ($myrowimage['imagename']) { echo ""; } } echo "  " . nl2br($myrowid['emneheader']) . " "; if ($myrowid['type'] == "produktfolder") { $result_level_1 = @mysql_query("SELECT level_1 FROM " . $produkttable . " WHERE id='" . $myrowid['href'] . "' "); $myrow_level_1 = @mysql_fetch_array($result_level_1); $result_navigation = @mysql_query("SELECT id, navigation FROM " . $produkttable . " WHERE level_1='" . $myrow_level_1['level_1'] . "' AND level_2>'0' AND level_3 ='0'"); while ($myrow_navigation = @mysql_fetch_array($result_navigation)) { if (substr($myrow_navigation['navigation'],0,3) == "<#>") { $navigation = substr($myrow_navigation['navigation'],11); echo "" . nl2br($navigation) . "
"; } else { echo "" . nl2br($myrow_navigation['navigation']) . "
"; } } } echo "
 
 
   " . nl2br($myrowid['emneheader']) . "  
 
\n"; } // slut på rutine til visning af navigation til forsiden if ($product_id) { // vis navigation til produktfoldere echo "\n"; echo "\n"; echo "\n"; // TD til thumbs echo "\n"; // TD til højremargin echo "\n"; // TD til level 1 echo "\n"; // TD til level 2 echo "\n"; // TD til højremargin echo "\n"; // hent level informationer for valgte produkt $result_level = @mysql_query("SELECT level_1, level_2, level_3, level_4, level_5, level_6, level_7 FROM " . $produkttable . " WHERE id='" . $product_id . "' "); $myrow_level = @mysql_fetch_array($result_level); for ($levels = 1; $levels <= $numlevels; $levels++) { $thislevel = "level_" . $levels; $nextlevel = "level_" . ($levels+1); $lastlevel = "level_" . ($levels+2); if ($myrow_level[$thislevel] > "0") { $showlevel = $myrow_level[$thislevel]; $sql_selected_level .= $thislevel . "='" . $showlevel . "' AND "; } if ($myrow_level[$thislevel] == "0") { $sql_first_level = $sql_selected_level . $thislevel . ">'0' AND " . $nextlevel . "='0'"; $sql_second_level .= $sql_selected_level . $thislevel . ">'0' AND " . $nextlevel . ">'0' AND" . $lastlevel . "='0'"; break; } } // hent data der passer til valgt level. $result_selected_level = @mysql_query("SELECT id, status, statusmini, gfx, imagename, navigation, level_1, level_2, level_3, level_4, level_5, level_6, level_7 FROM " . $produkttable . " WHERE " . $sql_first_level . " ORDER BY navigation"); while ($myrow_level = mysql_fetch_array($result_selected_level)) { $shownavigation = false; if ($korrektur) { if (($myrow_level['status'] == '1') OR ($myrow_level['status'] == '3')) { // Vis aktive + korrektur $shownavigation = true; } } else { if ($myrow_level['status'] == '1'){ // Vis aktive $shownavigation = true; } } if ($shownavigation) { echo "\n"; echo "\n"; echo "\n"; // luft if (substr($myrow_level['navigation'],0,3) == "<#>") { echo "\n"; } else { echo "\n"; } echo "\n"; echo "\n"; echo "\n"; echo "\n"; } } echo "
"; if ($myrow_level['imagename']) { echo ""; } echo "  " . substr($myrow_level['navigation'],12) . "  " . $myrow_level['navigation'] . " "; if ($myrow_level['statusmini'] == "1") { $result_navigation = @mysql_query("SELECT id, status, gfx, navigation FROM " . $produkttable . " WHERE " . $sql_selected_level . $thislevel . "='" . $myrow_level[$thislevel] . "' AND " . $nextlevel . ">'0' AND " . $lastlevel . "='0' ORDER BY navigation"); while ($myrow_navigation = @mysql_fetch_array($result_navigation)) { $shownavigation = false; if ($korrektur) { if (($myrow_navigation['status'] == '1') OR ($myrow_navigation['status'] == '3')) { // Vis aktive + korrektur $shownavigation = true; } } else { if ($myrow_navigation['status'] == '1'){ // Vis aktive $shownavigation = true; } } if ($shownavigation == "true") { if (substr($myrow_navigation['navigation'],0,3) == "<#>") { $navigation = substr($myrow_navigation['navigation'],12); echo "" . $navigation . "
"; } else { echo "" . $myrow_navigation['navigation'] . "
"; } } } } echo "
 
 
\n"; } echo "\n\n\n"; ?>