commit 2da792841b9be1d8f6d9ce7bdc7a0d9b24542396
Author: Holger Lindemann <hli@lx-system.de>
Date:   Mon Jan 7 09:45:38 2013 +0100

    Wird nicht mehr weiterentwickelt / gepflegt. Funktion fraglich.
    
    Evtl. Nachfolgeprojekt auf Basis der neuen PHPeppershop-Schnittstelle.

diff --git a/olcom/Shop.png b/olcom/Shop.png
deleted file mode 100644
index aa2b8741c..000000000
Binary files a/olcom/Shop.png and /dev/null differ
diff --git a/olcom/artistic_license b/olcom/artistic_license
deleted file mode 100644
index d0ac87759..000000000
--- a/olcom/artistic_license
+++ /dev/null
@@ -1,51 +0,0 @@
-The Artistic License
-
-Preamble
-
-The intent of this document is to state the conditions under which a Package may be copied, such that the Copyright Holder maintains some semblance of artistic control over the development of the package, while giving the users of the package the right to use and distribute the Package in a more-or-less customary fashion, plus the right to make reasonable modifications.
-
-Definitions:
-
-    * "Package" refers to the collection of files distributed by the Copyright Holder, and derivatives of that collection of files created through textual modification.
-    * "Standard Version" refers to such a Package if it has not been modified, or has been modified in accordance with the wishes of the Copyright Holder.
-    * "Copyright Holder" is whoever is named in the copyright or copyrights for the package.
-    * "You" is you, if you're thinking about copying or distributing this Package.
-    * "Reasonable copying fee" is whatever you can justify on the basis of media cost, duplication charges, time of people involved, and so on. (You will not be required to justify it to the Copyright Holder, but only to the computing community at large as a market that must bear the fee.)
-    * "Freely Available" means that no fee is charged for the item itself, though there may be fees involved in handling the item. It also means that recipients of the item may redistribute it under the same conditions they received it.
-
-1. You may make and give away verbatim copies of the source form of the Standard Version of this Package without restriction, provided that you duplicate all of the original copyright notices and associated disclaimers.
-
-2. You may apply bug fixes, portability fixes and other modifications derived from the Public Domain or from the Copyright Holder. A Package modified in such a way shall still be considered the Standard Version.
-
-3. You may otherwise modify your copy of this Package in any way, provided that you insert a prominent notice in each changed file stating how and when you changed that file, and provided that you do at least ONE of the following:
-
-    a) place your modifications in the Public Domain or otherwise make them Freely Available, such as by posting said modifications to Usenet or an equivalent medium, or placing the modifications on a major archive site such as ftp.uu.net, or by allowing the Copyright Holder to include your modifications in the Standard Version of the Package.
-
-    b) use the modified Package only within your corporation or organization.
-
-    c) rename any non-standard executables so the names do not conflict with standard executables, which must also be provided, and provide a separate manual page for each non-standard executable that clearly documents how it differs from the Standard Version.
-
-    d) make other distribution arrangements with the Copyright Holder.
-
-4. You may distribute the programs of this Package in object code or executable form, provided that you do at least ONE of the following:
-
-    a) distribute a Standard Version of the executables and library files, together with instructions (in the manual page or equivalent) on where to get the Standard Version.
-
-    b) accompany the distribution with the machine-readable source of the Package with your modifications.
-
-    c) accompany any non-standard executables with their corresponding Standard Version executables, giving the non-standard executables non-standard names, and clearly documenting the differences in manual pages (or equivalent), together with instructions on where to get the Standard Version.
-
-    d) make other distribution arrangements with the Copyright Holder.
-
-5. You may charge a reasonable copying fee for any distribution of this Package. You may charge any fee you choose for support of this Package. You may not charge a fee for this Package itself. However, you may distribute this Package in aggregate with other (possibly commercial) programs as part of a larger (possibly commercial) software distribution provided that you do not advertise this Package as a product of your own.
-
-6. The scripts and library files supplied as input to or produced as output from the programs of this Package do not automatically fall under the copyright of this Package, but belong to whomever generated them, and may be sold commercially, and may be aggregated with this Package.
-
-7. C or perl subroutines supplied by you and linked into this Package shall not be considered part of this Package.
-
-8. The name of the Copyright Holder may not be used to endorse or promote products derived from this software without specific prior written permission.
-
-9. THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-
-The End
-
diff --git a/olcom/c2s.gif b/olcom/c2s.gif
deleted file mode 100644
index 2c2b55db7..000000000
Binary files a/olcom/c2s.gif and /dev/null differ
diff --git a/olcom/conf.php b/olcom/conf.php
deleted file mode 100644
index ab4c8350e..000000000
--- a/olcom/conf.php
+++ /dev/null
@@ -1,71 +0,0 @@
-<?
-// Verbindung zur ERP-db
-$ERPuser="lxoffice";
-$ERPpass="geheim";
-$ERPhost="localhost";
-$ERPport="";
-$ERPdbname="stable";
-$ERPdns="pgsql://$ERPuser:$ERPpass@$ERPhost/$ERPdbname";
-$ERPusr["Name"]="hli";
-$ERPusr["ID"]="376";
-$ERPdir="tmp/shopartikel.csv";
-$ERPimgdir="/usr/lib/lx-office-erp";
-$maxSize="";
-$ERPftphost="localhost";
-$ERPftpuser="olcom";
-$ERPftppwd="olcom";
-//Verbindung zur osCommerce-db
-$SHOPuser="root";
-$SHOPpass="db4web";
-$SHOPhost="localhost";
-$SHOPport="";
-$SHOPdbname="olc";
-$dbprefix="";
-$SHOPlang="Array";
-$SHOPdns="mysql://$SHOPuser:$SHOPpass@$SHOPhost/$SHOPdbname";
-$SHOPdir="tmp/shopartikel.csv";
-$SHOPimgdir="/var/www/olcommerce/images/product_images";
-$SHOPftphost="localhost";
-$SHOPftpuser="olcom";
-$SHOPftppwd="olcom";
-$versand["ID"]="1568";
-$div16["ID"]="413";
-$div07["ID"]="414";
-$nachn["ID"]="413";
-$minder["ID"]="";
-$paypal["ID"]="413";
-$versand["TAX"]="16.00000";
-$div16["TAX"]="16.00000";
-$div07["TAX"]="7.00000";
-$nachn["TAX"]="16.00000";
-$minder["TAX"]="";
-$paypal["TAX"]="16.00000";
-$versand["NR"]="versand";
-$div16["NR"]="div16";
-$div07["NR"]="div07";
-$nachn["NR"]="div16";
-$minder["NR"]="";
-$paypal["NR"]="div16";
-$div16["TXT"]="Diverse Artikel 16% MWSt.";
-$div07["TXT"]="Diverse Artikel 7% MWSt.";
-$versand["TXT"]="Versandkosten";
-$nachn["TXT"]="Diverse Artikel 16% MWSt.";
-$minder["TXT"]="";
-$paypal["TXT"]="Diverse Artikel 16% MWSt.";
-$bgcol[1]="#ddddff";
-$bgcol[2]="#ddffdd";
-$preA="";
-$preK="";
-$auftrnr="1";
-$debug=false;
-$kdnum="1";
-$stdprice="0";
-$altprice="0";
-$KDGrp="";
-$nopic="bilder/lx-office-crm.png";
-$showErr="true";
-$Language[0]=array("ERP"=>0,"SHOP"=>2);
-$Language[1]=array("ERP"=>2204,"SHOP"=>0);
-$SHOPdefaultlang="2";
-$SpracheAlle="false";
-?>
\ No newline at end of file
diff --git a/olcom/confedit.php b/olcom/confedit.php
deleted file mode 100644
index d44fe0936..000000000
--- a/olcom/confedit.php
+++ /dev/null
@@ -1,511 +0,0 @@
-<?
-// $Id: confedit.php,v 1.3 2004/06/30 11:34:30 hli Exp $
-if (!isset($_SERVER['PHP_AUTH_USER'])) {
-       Header("WWW-Authenticate: Basic realm=\"Configurations-Editor\"");
-       Header("HTTP/1.0 401 Unauthorized");
-       echo "Sie m&uuml;ssen sich autentifizieren\n";
-       exit;
-} else {
-	$login=($_GET["login"])?$_GET["login"]:$_POST["login"];
-        if (file_exists ("conf$login.php")) {
-                require "conf$login.php";
-        } else {
-                require "conf.php";
-        }
-	if ($_SERVER['PHP_AUTH_USER']<>$ERPftpuser || $_SERVER['PHP_AUTH_PW']<>$ERPftppwd) {
-		Header("WWW-Authenticate: Basic realm=\"My Realm\"");
-		Header("HTTP/1.0 401 Unauthorized");
-		echo "Sie m&uuml;ssen sich autentifizieren\n";
-		exit;
-	}
-	require_once "DB.php";
-	function pg($sel) {
-	global $dbP;
-		echo "\t<option value=0";
-		if ($sel==0) echo " selected";
-		echo ">Standard VK\n";
-		if (!$dbP) return;
-		$sql="select id,pricegroup from pricegroup";
-		$pgs=$dbP->getall($sql);
-		if ($pgs) foreach ($pgs as $row) {
-			echo "\t<option value=".$row[0];
-			if ($sel==$row[0]) echo " selected";
-			echo ">".$row[1]."\n";
-		}
-	}
-	function shoplang($sel,$default) {
-	global $dbM;
-		$sql="SELECT L.*, C.configuration_value FROM languages L LEFT JOIN configuration C ";
-		$sql.="ON L.code = C.configuration_value";
-		$rs=$dbM->getAll($sql,DB_FETCHMODE_ASSOC);
-	        if (!$rs) {
-        	      echo "\t\t<option value='0'>keine Sprachen\n";
-	        } else {
-			echo "\t\t<option value='0' ".(($sel==0)?"selected":"").">nicht verwenden\n";
-			foreach ($rs as $row) {
-				if ($default["id"]<>$row["languages_id"]) {
-					echo "\t\t<option value='".$row["languages_id"]."' ";
-					echo (($row["languages_id"]==$sel)?"selected":"").">";
-					echo ($row["code"]==$row["configuration_value"])?"!":" ";
-					echo $row["name"]."\n";
-				}
-			}
-		}
-	}
-	function erplang($sel) {
-	global $dbP;
-		$sql="select * from language";
-		$rs=$dbP->getAll($sql,DB_FETCHMODE_ASSOC);
-	        if (!$rs) {
-        	      echo "\t\t<option>keine Sprachen\n";
-	        } else {
-			//echo "\t\t<option value='0' ".(($sel==0)?"selected":"").">Standard\n";
-			foreach ($rs as $row) {
-				echo "\t\t<option value='".$row["id"]."' ";
-				echo ($sel==$row["id"])?"selected":"";
-				echo ">".$row["description"]."\n";
-			}
-		}
-	}
-	function getERPlangs() {
-	global $dbP;
-		$sql="select * from language";
-		$rs=$dbP->getAll($sql,DB_FETCHMODE_ASSOC);
-		return $rs;
-	}
-	function getShopDefault() {
-	global $dbM;
-		if (!$dbM) return false;
-		$sql="select * from languages L left join configuration C on L.code=C.configuration_value ";
-		$sql.="where  configuration_key = 'DEFAULT_LANGUAGE'";
-		$rs=$dbM->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ($rs) {
-		        return array("id"=>$rs[0]["languages_id"],"name"=>$rs[0]["name"]);
-		} else  {
-			return 0;
-		}
-	}
-	if ($_POST["ok"]=="sichern") {
-		$ok=true;
-		if ($_POST["ERPpass"]) {
-			$dsnP="pgsql://".$_POST["ERPuser"].":".$_POST["ERPpass"]."@".$_POST["ERPhost"]."/".$_POST["ERPdbname"];
-		} else {
-			$dsnP="pgsql://".$_POST["ERPuser"]."@".$_POST["ERPhost"]."/".$_POST["ERPdbname"];
-		}
-		$dbP=@DB::connect($dsnP);
-		if (DB::isError($dbP)||!$dbP) {
-			$ok=false;
-			echo "Keine Verbindung zur ERP<br>";
-			echo $dbP->userinfo;
-			$dbP=false;
-		} else {
-			//Steuertabelle ERP
-            $sql ="select  BG.id as bugru,T.rate,TK.startdate from buchungsgruppen BG left join chart C ";
-            $sql.="on BG.income_accno_id_0=C.id left join taxkeys TK on TK.chart_id=C.id left join tax T ";
-            $sql.="on T.id=TK.tax_id where TK.startdate <= now()";
-            $rs=$dbP->getAll($sql,DB_FETCHMODE_ASSOC);
-            $erptax=array();
-            foreach ($rs as $row) {
-                 if ($erptax[$row["bugru"]]["startdate"]<$row["startdate"]) {
-                      $erptax[$row["bugru"]]["startdate"]=$row["startdate"];
-                      $erptax[$row["bugru"]]["rate"]=sprintf("%1.4f",$row["rate"]*100);
-                 }
-            }
-            $sql ="select  P.id,P.description,P.buchungsgruppen_id as bugru from ";
-            $sql.="parts P where P.partnumber = '%s'";
-			$rs=$dbP->getall(sprintf($sql,$_POST["div16NR"]));
-			$_POST["div16ID"]=$rs[0][0];
-			$div16txt=$rs[0][1];
-			$_POST["div16TAX"]=$erptax[$rs[0][2]]["rate"];
-			$rs=$dbP->getall(sprintf($sql,$_POST["div07NR"]));
-			$_POST["div07ID"]=$rs[0][0];
-			$_POST["div07TAX"]=$erptax[$rs[0][2]]["rate"];
-			$div07txt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["versandNR"]));
-			$_POST["versandID"]=$rs[0][0];
-			$_POST["versandTAX"]=$erptax[$rs[0][2]]["rate"];
-			$versandtxt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["nachnNR"]));
-			$_POST["nachnID"]=$rs[0][0];
-			$_POST["nachnTAX"]=$erptax[$rs[0][2]]["rate"];
-			$nachntxt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["minderNR"]));
-			$_POST["minderID"]=$rs[0][0];
-			$_POST["minderTAX"]=$erptax[$rs[0][2]]["rate"];
-			$mindertxt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["paypalNR"]));
-			$_POST["paypalID"]=$rs[0][0];
-			$_POST["paypalTAX"]=$erptax[$rs[0][2]]["rate"];
-			$paypaltxt=$rs[0][1];
-			$rs=$dbP->getall("select id from employee where login = '".$_POST["ERPusrN"]."'");
-			$_POST["ERPusrID"]=$rs[0][0];
-		}
-		if ($_POST["SHOPpass"]) {
-			$dsnM="mysql://".$_POST["SHOPuser"].":".$_POST["SHOPpass"]."@".$_POST["SHOPhost"]."/".$_POST["SHOPdbname"];
-		} else {
-			$dsnM="mysql://".$_POST["SHOPuser"]."@".$_POST["SHOPhost"]."/".$_POST["SHOPdbname"];
-		}
-		$dbM=@DB::connect($dsnM);
-		if (DB::isError($dbM)||!$dbM) {
-			$ok=false;
-			echo "Keine Verbindung zum Shop<br>";
-			echo $dbM->userinfo;
-			$dbM=false;
-		};
-		if ($ok) {
-			$ShopDefaultLang=getShopDefault();
-			$f=fopen("conf$login.php","w");
-			$v="1.6";
-			$d=date("Y/m/d H:i:s");
-			fputs($f,"<?\n// Verbindung zur ERP-db\n");
-			fputs($f,"\$ERPuser=\"".$_POST["ERPuser"]."\";\n");
-			fputs($f,"\$ERPpass=\"".$_POST["ERPpass"]."\";\n");
-			fputs($f,"\$ERPhost=\"".$_POST["ERPhost"]."\";\n");
-			fputs($f,"\$ERPport=\"".$_POST["ERPport"]."\";\n");
-			fputs($f,"\$ERPdbname=\"".$_POST["ERPdbname"]."\";\n");
-			fputs($f,"\$ERPdns=\"pgsql://\$ERPuser:\$ERPpass@\$ERPhost/\$ERPdbname\";\n");
-			fputs($f,"\$ERPusr[\"Name\"]=\"".$_POST["ERPusrN"]."\";\n");
-			fputs($f,"\$ERPusr[\"ID\"]=\"".$_POST["ERPusrID"]."\";\n");
-			fputs($f,"\$ERPdir=\"".$_POST["ERPdir"]."\";\n");
-			fputs($f,"\$ERPimgdir=\"".$_POST["ERPimgdir"]."\";\n");
-			fputs($f,"\$maxSize=\"".$_POST["maxSize"]."\";\n");
-			fputs($f,"\$ERPftphost=\"".$_POST["ERPftphost"]."\";\n");
-			fputs($f,"\$ERPftpuser=\"".$_POST["ERPftpuser"]."\";\n");
-			fputs($f,"\$ERPftppwd=\"".$_POST["ERPftppwd"]."\";\n");
-			fputs($f,"//Verbindung zur osCommerce-db\n");
-			fputs($f,"\$SHOPuser=\"".$_POST["SHOPuser"]."\";\n");
-			fputs($f,"\$SHOPpass=\"".$_POST["SHOPpass"]."\";\n");
-			fputs($f,"\$SHOPhost=\"".$_POST["SHOPhost"]."\";\n");
-			fputs($f,"\$SHOPport=\"".$_POST["SHOPport"]."\";\n");
-			fputs($f,"\$SHOPdbname=\"".$_POST["SHOPdbname"]."\";\n");
-			fputs($f,"\$dbprefix=\"".$_POST["dbprefix"]."\";\n");
-			fputs($f,"\$SHOPlang=\"".$_POST["SHOPlang"]."\";\n");
-			fputs($f,"\$SHOPdns=\"mysql://\$SHOPuser:\$SHOPpass@\$SHOPhost/\$SHOPdbname\";\n");
-			fputs($f,"\$SHOPdir=\"".$_POST["SHOPdir"]."\";\n");
-			fputs($f,"\$SHOPimgdir=\"".$_POST["SHOPimgdir"]."\";\n");
-			fputs($f,"\$SHOPftphost=\"".$_POST["SHOPftphost"]."\";\n");
-			fputs($f,"\$SHOPftpuser=\"".$_POST["SHOPftpuser"]."\";\n");
-			fputs($f,"\$SHOPftppwd=\"".$_POST["SHOPftppwd"]."\";\n");
-			fputs($f,"\$versand[\"ID\"]=\"".$_POST["versandID"]."\";\n");
-			fputs($f,"\$div16[\"ID\"]=\"".$_POST["div16ID"]."\";\n");
-			fputs($f,"\$div07[\"ID\"]=\"".$_POST["div07ID"]."\";\n");
-			fputs($f,"\$nachn[\"ID\"]=\"".$_POST["nachnID"]."\";\n");
-			fputs($f,"\$minder[\"ID\"]=\"".$_POST["minderID"]."\";\n");
-			fputs($f,"\$paypal[\"ID\"]=\"".$_POST["paypalID"]."\";\n");
-			fputs($f,"\$versand[\"TAX\"]=\"".$_POST["versandTAX"]."\";\n");
-			fputs($f,"\$div16[\"TAX\"]=\"".$_POST["div16TAX"]."\";\n");
-			fputs($f,"\$div07[\"TAX\"]=\"".$_POST["div07TAX"]."\";\n");
-			fputs($f,"\$nachn[\"TAX\"]=\"".$_POST["nachnTAX"]."\";\n");
-			fputs($f,"\$minder[\"TAX\"]=\"".$_POST["minderTAX"]."\";\n");
-			fputs($f,"\$paypal[\"TAX\"]=\"".$_POST["paypalTAX"]."\";\n");
-			fputs($f,"\$versand[\"NR\"]=\"".$_POST["versandNR"]."\";\n");
-			fputs($f,"\$div16[\"NR\"]=\"".$_POST["div16NR"]."\";\n");
-			fputs($f,"\$div07[\"NR\"]=\"".$_POST["div07NR"]."\";\n");
-			fputs($f,"\$nachn[\"NR\"]=\"".$_POST["nachnNR"]."\";\n");
-			fputs($f,"\$minder[\"NR\"]=\"".$_POST["minderNR"]."\";\n");
-			fputs($f,"\$paypal[\"NR\"]=\"".$_POST["paypalNR"]."\";\n");
-			fputs($f,"\$div16[\"TXT\"]=\"".$div16txt."\";\n");
-			fputs($f,"\$div07[\"TXT\"]=\"".$div07txt."\";\n");
-			fputs($f,"\$versand[\"TXT\"]=\"".$versandtxt."\";\n");
-			fputs($f,"\$nachn[\"TXT\"]=\"".$nachntxt."\";\n");
-			fputs($f,"\$minder[\"TXT\"]=\"".$mindertxt."\";\n");
-			fputs($f,"\$paypal[\"TXT\"]=\"".$paypaltxt."\";\n");
-			fputs($f,"\$bgcol[1]=\"#ddddff\";\n");
-			fputs($f,"\$bgcol[2]=\"#ddffdd\";\n");
-			fputs($f,"\$preA=\"".$_POST["preA"]."\";\n");
-			fputs($f,"\$preK=\"".$_POST["preK"]."\";\n");
-			fputs($f,"\$auftrnr=\"".$_POST["auftrnr"]."\";\n");
-			fputs($f,"\$debug=".$_POST["debug"].";\n");
-			fputs($f,"\$kdnum=\"".$_POST["kdnum"]."\";\n");
-			fputs($f,"\$stdprice=\"".$_POST["stdprice"]."\";\n");
-			fputs($f,"\$altprice=\"".$_POST["altprice"]."\";\n");
-			fputs($f,"\$KDGrp=\"".$_POST["KDGrp"]."\";\n");
-			fputs($f,"\$nopic=\"".$_POST["nopic"]."\";\n");
-			fputs($f,"\$showErr=\"true\";\n");
-			$Language=array();
-			$DefaultLangOk=false;
-			if ($_POST["ERPlang"]) foreach ($_POST["ERPlang"] as $key=>$val) {
-				if ($_POST["SHOPlang"][$key]==$ShopDefaultLang["id"]) $DefaultLangOk=true;
-					$sl=($_POST["SHOPlang"][$key])?$_POST["SHOPlang"][$key]:0;
-					fputs($f,"\$Language[$key]=array(\"ERP\"=>$val,\"SHOP\"=>".$sl.");\n");
-			}
-			if (!$DefaultLangOk) {
-				fputs($f,"\$SHOPdbname=\"\";\n");
-				echo "Es wurde keine ERP-Sprache der Shopdefaultsprache zugewiesen.";
-				echo "Verbindung zum Shop abgebrochen<br>";
-			}
-			fputs($f,"\$SHOPdefaultlang=\"".$ShopDefaultLang["id"]."\";\n");
-			fputs($f,"\$SpracheAlle=\"".$_POST["SpracheAlle"]."\";\n");
-			fputs($f,"?>");
-			fclose($f);
-			require "conf$login.php";
-			if ($dbprefix<>"") $pre=$dbprefix."_";
-			$sql="select count(*) from ".$pre."customers_number";
-			$rc=@$dbM->query($sql);
-			if ($rc->code==-18) {
-				$sql="CREATE TABLE ".$pre."customers_number (  cid int(6) NOT NULL auto_increment,  customers_id int(3) NOT NULL default '0', ";
-				$sql.="kdnr int NOT NULL default '0', shipto int,  PRIMARY KEY  (cid)) TYPE=MyISAM";
-				$rc=@$dbM->query($sql);
-				if ($rc->code==-1) {
-					echo "Fehler beim Erzeugen der Tabelle '".$pre."customers_number' in der Shop-db";
-				} else {
-					echo "Tabelle '".$pre."customers_number' in der Shop-db angelegt.";
-				}
-			} else {
-				$sql="select shipto from ".$pre."customers_number limit 1";
-				$rc=@$dbM->query($sql);
-				if ($rc->code==-19) {
-					$sql="alter table ".$pre."customers_number add column shipto int";
-					$rc=@$dbM->query($sql);
-                                	if ($rc->code==-1) {
-						echo "Fehler beim Anlegen der Spalte 'shipto' in 'customers_number'";
-					} else {
-						echo "'shipto' in 'customers_number' angelegt.";
-					}
-				}
-			}
-		} else {
-			$ERPuser=$_POST["ERPuser"];
-			$ERPpass=$_POST["ERPpass"];
-			$ERPhost=$_POST["ERPhost"];
-			$ERPport=$_POST["ERPport"];
-			$ERPdbname=$_POST["ERPdbname"];
-			$ERPusrN=$_POST["ERPusrN"];
-			$ERPdir=$_POST["ERPdir"];
-			$ERPimgdir=$_POST["ERPimgdir"];
-			$maxSize=$_POST["maxSize"];
-			$ERPftphost=$_POST["ERPftphost"];
-			$ERPftpuser=$_POST["ERPftpuser"];
-			$ERPftppwd=$_POST["ERPftppwd"];
-			$SHOPuser=$_POST["SHOPuser"];
-			$SHOPpass=$_POST["SHOPpass"];
-			$SHOPhost=$_POST["SHOPhost"];
-			$SHOPport=$_POST["SHOPport"];
-			$SHOPdbname=$_POST["SHOPdbname"];
-			$dbprefix=$_POST["dbprefix"];
-			$SHOPlang=$_POST["SHOPlang"];
-			$SHOPdir=$_POST["SHOPdir"];
-			$SHOPimgdir=$_POST["SHOPimgdir"];
-			$SHOPftphost=$_POST["SHOPftphost"];
-			$SHOPftpuser=$_POST["SHOPftpuser"];
-			$SHOPftppwd=$_POST["SHOPftppwd"];
-			$div16NR=$_POST["div16NR"];
-			$div07NR=$_POST["div07NR"];
-			$versandNR=$_POST["versandNR"];
-			$nachnNR=$_POST["nachnNR"];
-			$minderNR=$_POST["minderNR"];
-			$paypalNR=$_POST["paypalNR"];
-			$preA=$_POST["preA"];
-			$preK=$_POST["preK"];
-			$kdnum=$_POST["kdnum"];
-			$auftrnr=$_POST["auftrnr"];
-			$debug=$_POST["debug"];
-			$altprice=$_POST["altprice"];
-			$stdprice=$_POST["stdprice"];
-			$nopic=$_POST["nopic"];
-		}
-		$ERPlangs=getERPlangs();
-                $CntERPLang=count($ERPlangs); //$rs[0][0];
-	} else {
-		if (file_exists ("conf$login.php")) {
-                	require "conf$login.php";
-	       	} else {
-               		require "conf.php";
-	       	}
-		$dsnP = array(
-                    'phptype'  => 'pgsql',
-                    'username' => $ERPuser,
-                    'password' => $ERPpass,
-                    'hostspec' => $ERPhost,
-                    'database' => $ERPdbname,
-                    'port'     => $ERPport
-                );
-                $dbP=@DB::connect($dsnP);
-                if (DB::isError($dbP)||!$dbP) {
-                        echo "Keine Verbindung zur ERP<br>";
-                        $dbP=false;
-                        //echo $dbP->userinfo;
-                } else {
-                        //$rs=$dbP->getAll("select count(*) from language");
-                        $ERPlangs=getERPlangs();
-                        $CntERPLang=count($ERPlangs); //$rs[0][0];
-                }
-                $dsnM = array(
-                    'phptype'  => 'mysql',
-                    'username' => $SHOPuser,
-                    'password' => $SHOPpass,
-                    'hostspec' => $SHOPhost,
-                    'database' => $SHOPdbname,
-                    'port'     => $SHOPport
-                );
-                $dbM=@DB::connect($dsnM);
-                if (DB::isError($dbM)||!$dbM) {
-                        echo "Keine Verbindung zum SHOP<br>";
-                        //echo $dbM->userinfo;
-                		$dbM=false;
-                } else {
-                        $ShopDefaultLang=getShopDefault();
-                }
-	}
-	?>
-<html>
-<body>
-<center>
-<table style="background-color:#cccccc">
-<form name="ConfEdit" method="post" action="confedit.php">
-<input type="hidden" name="div16ID" value="<?= $div16["ID"] ?>">
-<input type="hidden" name="div07ID" value="<?= $div07["ID"] ?>">
-<input type="hidden" name="minderID" value="<?= $minder["ID"] ?>">
-<input type="hidden" name="versandID" value="<?= $versand["ID"] ?>">
-<input type="hidden" name="nachnID" value="<?= $nachn["ID"] ?>">
-<input type="hidden" name="paypalID" value="<?= $paypal["ID"] ?>">
-<input type="hidden" name="ERPusrID" value="<?= $ERPusr["ID"] ?>">
-<input type="hidden" name="login" value="<?= $login ?>">
-<tr><th>Daten</th><th>Lx-ERP</th><th></th><th>Shop</th></tr>
-<tr>
-	<td>db-Host</td>
-	<td colspan="2"><input type="text" name="ERPhost" size="25" value="<?= $ERPhost ?>"></td>
-	<td><input type="text" name="SHOPhost" size="25" value="<?= $SHOPhost ?>"></td>
-</tr>
-<tr>
-	<td>Port</td>
-	<td colspan="2"><input type="text" name="ERPport" size="25" value="<?= $ERPport ?>"></td>
-	<td><input type="text" name="SHOPport" size="25" value="<?= $SHOPport ?>"></td>
-</tr>
-<tr>
-	<td>Database</td>
-	<td colspan="2"><input type="text" name="ERPdbname" size="20" value="<?= $ERPdbname ?>"></td>
-	<td><input type="text" name="SHOPdbname" size="20" value="<?= $SHOPdbname ?>"></td>
-</tr>
-<tr>
-	<td>db-User Name</td>
-	<td colspan="2"><input type="text" name="ERPuser" size="15" value="<?= $ERPuser ?>"></td>
-	<td><input type="text" name="SHOPuser" size="15" value="<?= $SHOPuser ?>"></td>
-</tr>
-<tr>
-	<td>db-User PWD</td>
-	<td colspan="2"><input type="text" name="ERPpass" size="15" value="<?= $ERPpass ?>"></td>
-	<td><input type="text" name="SHOPpass" size="15" value="<?= $SHOPpass ?>"></td>
-</tr>
-<tr>
-	<td>User-ID</td>
-	<td colspan="2"><input type="text" name="ERPusrN" size="10" value="<?= $ERPusr["Name"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($ERPusr["ID"])?"":"checked") ?> onFocus="blur();">
-		&nbsp;&nbsp;&nbsp;&nbsp;db-Prefix
-	</td>
-	<td><input type="text" name="dbprefix" size="15" value="<?= $dbprefix ?>"></td>
-</tr>
-<tr>
-	<td>CSV-Dir</td>
-	<td colspan="2"><input type="text" name="ERPdir" size="30" value="<?= $ERPdir ?>"></td>
-	<td><input type="text" name="SHOPdir" size="30" value="<?= $SHOPdir ?>"></td>
-</tr>
-<tr>
-	<td>Image-Dir</td>
-	<td colspan="2"><input type="text" name="ERPimgdir" size="30" value="<?= $ERPimgdir ?>"></td>
-	<td><input type="text" name="SHOPimgdir" size="30" value="<?= $SHOPimgdir ?>"></td>
-</tr>
-<tr>
-	<td>FTP-Host</td>
-	<td colspan="2"><input type="text" name="ERPftphost" size="20" value="<?= $ERPftphost ?>"></td>
-	<td><input type="text" name="SHOPftphost" size="20" value="<?= $SHOPftphost ?>"></td>
-</tr>
-<tr>
-	<td>FTP-User</td>
-	<td colspan="2"><input type="text" name="ERPftpuser" size="15" value="<?= $ERPftpuser ?>"></td>
-	<td><input type="text" name="SHOPftpuser" size="15" value="<?= $SHOPftpuser ?>"></td>
-</tr>
-<tr>
-	<td>FTP-User PWD</td>
-	<td colspan="2"><input type="text" name="ERPftppwd" size="15" value="<?= $ERPftppwd ?>"></td>
-	<td><input type="text" name="SHOPftppwd" size="15" value="<?= $SHOPftppwd ?>"></td>
-</tr>
-<tr>
-	<td>ID Diverse 16%</td>
-	<td><input type="text" name="div16NR" size="10" value="<?= $div16["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($div16["ID"])?"":"checked") ?>></td>
-	<td>ID Diverse 7%</td>
-	<td><input type="text" name="div07NR" size="10" value="<?= $div07["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($div07["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Versand</td>
-	<td><input type="text" name="versandNR" size="10" value="<?= $versand["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($versand["ID"])?"":"checked") ?>></td>
-	<td>ID Nachname</td>
-	<td><input type="text" name="nachnNR" size="10" value="<?= $nachn["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($nachn["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Paypal</td>
-	<td><input type="text" name="paypalNR" size="10" value="<?= $paypal["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($paypal["ID"])?"":"checked") ?>></td>
-	<td>ID Mindemenge</td>
-	<td><input type="text" name="minderNR" size="10" value="<?= $minder["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($minder["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-        <td >Sprachen</td>
-        <td ><input type="hidden" name="ERPlang[0]" value="0">Standard</td>
-        <td >--&gt;</td>
-        <td ><input type="hidden" name="SHOPlang[0]" value="<?= $ShopDefaultLang["id"] ?>"><?= $ShopDefaultLang["name"] ?></td>
-</tr>
-<? for($i=0; $i < $CntERPLang; $i++) {  ?>
-<tr>
-        <td >Sprachen</td>
-        <td><input type="hidden" name="ERPlang[<?= $i+1 ?>]" value="<?= $ERPlangs[$i]["id"] ?>"><?= $ERPlangs[$i]["description"] ?>
-        <td >--&gt;</td>
-        <td ><select name="SHOPlang[<?= $i+1 ?>]">
-<?= shoplang($Language[$i+1]["SHOP"],$ShopDefaultLang); ?>
-        </select></td>
-</tr>
-<? } ?>
-<tr>
-        <td colspan="2">Nur &uuml;bersetzte Artikel</td>
-        <td><input type="radio" name="SpracheAlle" value="true"  <?= ($SpracheAlle=="true")?"checked":"" ?>> Ja</td>
-        <td><input type="radio" name="SpracheAlle" value="false" <?= ($SpracheAlle<>"true")?"checked":"" ?>> Nein</td>
-</tr>
-<tr>
-	<td>Standardpreis</td>
-	<td><select name="stdprice">
-<? pg($stdprice); ?>
-	    </select></td>
-	<td>Defaultbild</td>
-	<td><input type="text" name="nopic" size="20" value="<?= $nopic ?>">
-<tr>
-	<td>abweichender Preis</td>
-	<td><select name="altprice">
-<? pg($altprice); ?>
-	    </select></td>
-	<td>Kundengruppe</td>
-	<td><input type="text" name="KDGrp" size="3" value="<?= $KDGrp ?>">
-</tr>
-<tr>
-	<td colspan="2">Auftragsnummern durch</td>
-	<td><input type="radio" name="auftrnr" value="1" <?= ($auftrnr==1)?"checked":"" ?>> LxO</td>
-	<td><input type="radio" name="auftrnr" value="0" <?= ($auftrnr<>1)?"checked":"" ?>> Shop</td>
-</tr>
-<tr>
-	<td colspan="2">Kundennummern durch</td>
-	<td><input type="radio" name="kdnum" value="1" <?= ($kdnum==1)?"checked":"" ?>> LxO</td>
-	<td><input type="radio" name="kdnum" value="0" <?= ($kdnum<>1)?"checked":"" ?>> Shop</td>
-</tr>
-<tr>
-	<td colspan="2">Nummernerweiterung</td>
-	<td>Auftrag<input type="text" name="preA" size="5" value="<?= $preA ?>"></td>
-	<td>Kunde<input type="text" name="preK" size="5" value="<?= $preK ?>"></td>
-</tr>
-<tr>
-	<td>Logging</td>
-	<td>ein<input type="radio" name="debug" value="true" <?= ($debug=="true")?"checked":"" ?>>
-	aus<input type="radio" name="debug" value="false" <?= ($debug!="true")?"checked":"" ?>></td>
-	<td></td><td></td>
-</tr>
-
-<tr><td colspan="4" align="center"><input type="submit" name="ok" value="sichern"></td></tr>
-</form>
-</table>
-</center>
-</body>
-</html>
-<? } ?>
diff --git a/olcom/diff.php b/olcom/diff.php
deleted file mode 100644
index 3e2ac7b6a..000000000
--- a/olcom/diff.php
+++ /dev/null
@@ -1,87 +0,0 @@
-<?
-// $Id: diff.php,v 1.1 2004/06/30 10:12:15 hli Exp $
-require_once "DB.php";
-require_once "conf.php";
-if ($dbprefix<>"") { define("PREFIX",$dbprefix."_"); } else { define("PREFIX",""); }
-
-if (!$db) {
-	$db=DB::connect($SHOPdns);
-	if (!$db) dbFehler("",$db->getDebugInfo());
-	if (DB::isError($db)) {
-		dbFehler("",$db->getDebugInfo());
-		die ($db->getDebugInfo());
-	};
-	$db2=DB::connect($ERPdns);
-	if (!$db2) dbFehler("",$db2->getDebugInfo());
-	if (DB::isError($db2)) {
-		dbFehler("",$db2->getDebugInfo());
-		die ($db2->getDebugInfo());
-	};
-}
-if ($_POST["ok"]) {
-	foreach($_POST as $key=>$val) {
-		if ($key=="ok") continue;
-		if ($key=="alle") continue;
-		$sql="update ".PREFIX."products set products_status=0 where products_model=$key";
-		echo "$key ";
-		if ($db->query($sql)) { echo "deaktiviert<br>"; }
-		else { echo "konnte nicht deaktiviert werden<br>"; };
-	}
-} else {
-$sql="select partnumber from parts where shop='1' order by partnumber";
-$erp=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($erp) foreach ($erp as $zeile) { $arE[]=$zeile["partnumber"]; };
-
-if ($SHOPlang>0) {
-	$defLang=$SHOPlang;
-} else {
-	$sql="select * from ".PREFIX."languages L left join ".PREFIX."configuration C on L.code=C.configuration_value where  configuration_key = 'DEFAULT_LANGUAGE'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs) {
-		$defLang=$rs[0]["languages_id"];
-	} else {
-		$defLang=1;
-	}
-}
-
-$sql="select products_model,P.products_id,products_name from ".PREFIX."products P left join ".PREFIX."products_description D on P.products_id=D.products_id where language_id=$defLang and products_status=1 order by products_model";
-$shop=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($shop) foreach ($shop as $zeile) {
-	$arS[]=$zeile["products_model"];
-	$arID[$zeile["products_model"]]=array("id"=>$zeile["products_id"],"name"=>$zeile["products_name"]);
-}
-$result=@array_diff($arS,$arE);
-if ($result) {
-?>
-<html>
-<head><title>Artikelpflege</title>
-<script language="JavaScript">
-<!--
-	function sel() {
-		val=document.doppel.alle.checked;
-		cnt=document.doppel.length;
-		for (i=0; i<cnt; i++) {
-			document.doppel.elements[i].checked=val;
-		}
-	}
-//-->
-</script>
-</head>
-<body>
-Folgende Artikel sind in der ERP nicht mehr als Shopartikel markiert.<br>
-Markieren Sie die Artikel, die deaktiviert werden sollen.<br>
-<form name='doppel' method='post' action='diff.php'>
-<table>
-<?
-foreach ($result as $data) {
-	echo "\t<tr><td><input type='checkbox' name='".$data."' value='1'></td><td>".$data."</td><td>".$arID[$data]["name"]."</td></tr>\n";
-}
-?>
-	<tr><td><input type='checkbox' name='alle' value='1' onClick="sel()"></td><td></td><td>alle Artikel</td></tr>
-	<tr><td colspan='3'><input type='submit' name='ok' value='ok'></td></tr>
-</table>
-<form>
-<? }
-	else { "Artikelbestand identisch"; };
-} ?>
-<!--a href="trans.php">zur&uuml;ck</a-->
diff --git a/olcom/e2c.gif b/olcom/e2c.gif
deleted file mode 100644
index 692eb8b87..000000000
Binary files a/olcom/e2c.gif and /dev/null differ
diff --git a/olcom/e2s.gif b/olcom/e2s.gif
deleted file mode 100644
index f557ed4ba..000000000
Binary files a/olcom/e2s.gif and /dev/null differ
diff --git a/olcom/erpexport.php b/olcom/erpexport.php
deleted file mode 100644
index 5e19c87d5..000000000
--- a/olcom/erpexport.php
+++ /dev/null
@@ -1,198 +0,0 @@
-<?
-/***************************************************************
-* $Id: erpexport.php,v 1.1 2004/06/29 08:50:30 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.0
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-?>
-<html>
-	<head><title>Lx-ERP Export der Shopartikel</title>
-	<link type="text/css" REL="stylesheet" HREF="css/main.css"></link>
-	<script language="JavaScript">
-	<!--
-		function xtcomm() {
-			document.fld.PN.value="products_model"; document.fld.partnumber.checked=true;
-			document.fld.BEZ.value="products_name"; document.fld.desctiption.checked=true;
-			document.fld.GEWICHT.value="products_weight"; document.fld.weight.checked=true;
-			document.fld.MWST.value="products_tax"; document.fld.rate.checked=true;
-			document.fld.VK.value="products_price"; document.fld.sellprice.checked=true;
-			document.fld.PG.value="categories_name"; document.fld.partsgroup.checked=true;
-			document.fld.BESCHR.value="products_description"; document.fld.notes.checked=true;
-			document.fld.LAGER.value="products_quantity"; document.fld.onhand.checked=true;
-			document.fld.encl.value="";
-			document.fld.deli.value=";";
-			document.fld.crln.value="\\n";
-			document.fld.head.checked=true;
-			document.fld.shop.value="xtcomm";
-		}
-	//-->
-	</script>
-<body>
-
-<?php
-require_once "DB.php";
-require_once "./conf.php";
-$db=DB::connect($ERPdns);
-if (!$db) dbFehler("",$db->getDebugInfo());
-if (DB::isError($db)) {
-	dbFehler("",$db->getDebugInfo());
-	die ($db->getDebugInfo());
-};
-/****************************************************
-* dbFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function dbFehler($sql,$err) {
-global $showErr;
-	if ($showErr)
-		echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-
-function shopartikel() {
-global $db;
-	$sql ="SELECT P.partnumber,P.description,P.unit,P.weight,t.rate,P.sellprice,P.listprice,P.priceupdate,PG.partsgroup,P.notes,P.image,P.onhand FROM ";
-	$sql.="parts P left join partsgroup PG on  PG.id=P.partsgroup_id ";
-	$sql.="left join chart c on c.id = P.income_accno_id ";
-	$sql.="left join tax T on T.taxkey=C.taxkey_id ";
-	$sql.="where shop = 't'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	return $rs;
-}
-if ($_POST["export"]) {
-	$data=shopartikel();
-	$delim=($_POST["deli"])?$_POST["deli"]:",";
-	if (get_magic_quotes_gpc()) {
-		$crln = stripslashes($_POST["crln"]);
-	}
-	$crln = str_replace('\\r', "\015", $crln);
-	$crln = str_replace('\\n', "\012", $crln);
-	$crln = str_replace('\\t', "\011", $crln);
-	$encl=$_POST["encl"];
-	$i=0;
-	$f=fopen($ERPdir,"w");
-	if ($_POST["partnumber"])	{$header.=$_POST["PN"].$delim; };
-	if ($_POST["desctiption"])	{$header.=$_POST["BEZ"].$delim; };
-	if ($_POST["unit"])		{$header.=$_POST["EINHEIT"].$delim; };
-	if ($_POST["onhand"])		{$header.=$_POST["LAGER"].$delim; };
-	if ($_POST["weight"])		{$header.=$_POST["GEWICHT"].$delim; };
-	if ($_POST["rate"])		{$header.=$_POST["MWST"].$delim; };
-	if ($_POST["sellprice"])	{$header.=$_POST["VK"].$delim; };
-	if ($_POST["listprice"])	{$header.=$_POST["EK"].$delim; };
-	if ($_POST["priceupdate"])	{$header.=$_POST["PDATE"].$delim; };
-	if ($_POST["partsgroup"])	{$header.=$_POST["PG"].$delim; };
-	if ($_POST["notes"])		{$header.=$_POST["BESCHR"].$delim; };
-	if ($_POST["image"])		{$header.=$_POST["IMAGE"].$delim; };
-	$header=substr($header,0,-1);
-?>
-<table class="liste">
-<!-- BEGIN Artikel -->
-<?	$i=0;
-	$f=fopen($ERPdir,"w");
-	if ($_POST["head"]) fputs($f,$header.$crln);
-	foreach($data as $zeile) {
-		$file=""; $html="";
-		if ($_POST["shop"]=="pepper") {
-			if (preg_match("/^\[.*\].*/",$zeile["partsgroup"])) { $PG=$zeile["partsgroup"]; }
-			else { $PG="[".$zeile["partsgroup"]."]"; };
-			$mwst=$zeile["rate"]*100;
-		} else if ($_POST["shop"]=="oscomm") {
-			$mwst=sprintf("%01.4f",($zeile["rate"]*100));
-			$PG=$zeile["partsgroup"];
-		} else {
-			$PG=$zeile["partsgroup"];
-			$mwst=$zeile["rate"]*100;
-		};
-		$LineCol = $bgcol[$i%2+1];
-		if ($_POST["partnumber"])	{$file.=$encl.$zeile["partnumber"].$encl.$delim; $html.="<td>".$zeile["partnumber"]."</td>";};
-		if ($_POST["desctiption"])	{$file.=$encl.strtr($zeile["description"],chr(13).chr(10),"  ").$encl.$delim; $html.="<td>".$zeile["description"]."</td>";};
-		if ($_POST["unit"])			{$file.=$encl.$zeile["unit"].$encl.$delim; $html.="<td>".$zeile["unit"]."</td>";};
-		if ($_POST["onhand"])			{$file.=$encl.$zeile["onhand"].$encl.$delim; $html.="<td>".$zeile["onhand"]."</td>";};
-		if ($_POST["weight"])		{$file.=$encl.$zeile["weight"].$encl.$delim; $html.="<td>".$zeile["weight"]."</td>";};
-		if ($_POST["rate"])			{$file.=$encl.$mwst.$encl.$delim; $html.="<td>".$mwst."</td>";};
-		if ($_POST["sellprice"])	{$file.=$encl.(sprintf("%02.2f",$zeile["sellprice"])).$encl.$delim; $html.="<td>".(sprintf("%02.2f",$zeile["sellprice"]))."</td>";};
-		if ($_POST["listprice"])	{$file.=$encl.(sprintf("%02.2f",$zeile["listprice"])).$encl.$delim; $html.="<td>".(sprintf("%02.2f",$zeile["listprice"]))."</td>";};
-		if ($_POST["partsgroup"])	{$file.=$encl.$PG.$encl.$delim; $html.="<td>".$zeile["partsgroup"]."</td>";};
-		if ($_POST["notes"])		{$file.=$encl.strtr($zeile["notes"],chr(13).chr(10),"  ").$encl.$delim; $html.="<td>".$zeile["notes"]."</td>";};
-		if ($_POST["image"])		{$file.=$encl.$zeile["image"].$encl.$delim; $html.="<td>".$zeile["image"]."</td>";};
-		$i++;
-		fputs($f,substr($file,0,-1).$crln);
-		if ($_POST["show"]) {
-?>
-	<tr  class="smal" onMouseover="this.bgColor='#FF0000';" onMouseout="this.bgColor='<?= $LineCol ?>';" bgcolor="<?= $LineCol ?>">
-		<?= $html ?>
-	</tr>
-<? 		}
-	}
-?>
-<!-- END Artikel -->
-</table>
-Anzahl der Artikel: <?= $i ?><br>
-Export am : <?= date("d.m.Y : H:i") ?><br>
-download <a href="tmp/shopartikel.csv">Exportfile</a><br><hr>
-<?
-	fclose($f);
-} // if ($export)
-?>
-Export der Shopartikel aus Lx-ERP <br>
-M&ouml;gliche Felder
-<form name="fld" action="erpexport.php" method="post">
-<input type="hidden" name="shop" value="">
-<table>
-	<tr>
-		<td><input type="checkbox" name="partnumber" value="1">Artikelnummer</td>
-		<td><input type="checkbox" name="desctiption" value="1">Bezeichnung</td>
-		<td><input type="checkbox" name="unit" value="1">Einheit</td>
-		<td><input type="checkbox" name="weight" value="1">Gewicht</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="PN" size="23"></td>
-		<td><input type="text" name="BEZ" size="23"></td>
-		<td><input type="text" name="EINHEIT" size="23"></td>
-		<td><input type="text" name="GEWICHT" size="23"></td>
-	</tr>
-	<tr><td colspan=5></td></tr>
-	<tr>
-		<td><input type="checkbox" name="sellprice" value="1">Verkaufspreis</td>
-		<td><input type="checkbox" name="listprice" value="1">Listenpreis</td>
-		<td><input type="checkbox" name="onhand" value="1">Lagerbestand</td>
-		<td><input type="checkbox" name="rate" value="1">MwSt</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="VK" size="23"></td>
-		<td><input type="text" name="EK" size="23"></td>
-		<td><input type="text" name="LAGER" size="23"></td>
-		<td><input type="text" name="MWST" size="23"></td>
-	</tr>
-	<tr><td colspan=5></td></tr>
-	<tr>
-		<td><input type="checkbox" name="partsgroup" value="1">Gruppe</td>
-		<td><input type="checkbox" name="notes" value="1">Beschreibung</td>
-		<td><input type="checkbox" name="image" value="1">Bild</td>
-		<td><input type="checkbox" name="show" value="1" checked>HTML-Anzeige</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="PG" size="23"></td>
-		<td><input type="text" name="BESCHR" size="23"></td>
-		<td><input type="text" name="IMAGE" size="23"></td>
-		<td></td>
-	</tr>
-	<tr>
-		<td>Feldtrenner <input type="text" name="deli" size="2" value=","></td>
-		<td>Feldumrahmung <input type="text" name="encl" size="2" value="&quot;"></td>
-		<td>Zeilenende <input type="text" name="crln" size="2" value="\n"></td>
-		<td><input type="checkbox" name="head" value="1" checked>Headline</td>
-	</tr>
-	<tr>
-		<td colspan=5><input type="submit" name="export" value="Export"> <input type="button" name="xsc" value="xtCommerce" onClick="xtcomm()"></td>
-	</tr>
-</table>
-<a href="trans.php">zur&uuml;ck</a>
-</form>
-</body>
-</html>
diff --git a/olcom/handbuch.odt b/olcom/handbuch.odt
deleted file mode 100644
index 517e6ec61..000000000
Binary files a/olcom/handbuch.odt and /dev/null differ
diff --git a/olcom/handbuch.pdf b/olcom/handbuch.pdf
deleted file mode 100644
index 8938ebfb0..000000000
Binary files a/olcom/handbuch.pdf and /dev/null differ
diff --git a/olcom/menu.ini b/olcom/menu.ini
deleted file mode 100644
index 02fa5def5..000000000
--- a/olcom/menu.ini
+++ /dev/null
@@ -1,12 +0,0 @@
-
-[olCom]
-
-[olCom--Warenexport]
-module=olcom/shopimport_db.php
-
-[olCom--Bestellungen]
-module=olcom/olcomexport.php
-
-[olCom--Konfiguration]
-module=olcom/confedit.php
-
diff --git a/olcom/olCom.png b/olcom/olCom.png
deleted file mode 100644
index aa2b8741c..000000000
Binary files a/olcom/olCom.png and /dev/null differ
diff --git a/olcom/olcom.png b/olcom/olcom.png
deleted file mode 100644
index 491230887..000000000
Binary files a/olcom/olcom.png and /dev/null differ
diff --git a/olcom/olcomexport.php b/olcom/olcomexport.php
deleted file mode 100644
index e9a434b51..000000000
--- a/olcom/olcomexport.php
+++ /dev/null
@@ -1,396 +0,0 @@
-<?
-/***************************************************************
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.6
-*Shop: xt::Commerce
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-/*
-* Noch einzubauen:
-*/
-//echo <<<EOF
-echo "<html>";
-echo "	<head><title>Lx-ERP Export der Shopartikel</title>";
-echo '	<link type="text/css" REL="stylesheet" HREF="css/main.css"></link>';
-echo "<body>";
-//EOF;
-
-require_once "shoplib.php";
-
-
-/**********************************************
-* getAttribut($oid,$pid)
-*
-**********************************************/
-function getAttribut($oid,$pid) {
-	$sql="select * from ".PREFIX."orders_products_attributes where orders_id=$oid and orders_products_id=$pid";
-	$rs=getAll("shop",$sql,"getAttribut");
-	$txt="";
-	foreach ($rs as $zeile) {
-		$txt.="\n - ".$zeile["products_options"].":".$zeile["products_options_values"];
-	};
-	return $txt;
-}
-
-/**********************************************
-* getBrutto($id)
-*
-**********************************************/
-function getBrutto($id) {
-	$sql="select * from ".PREFIX."orders_total where orders_id=$id and class='ot_total'";
-	$rs=getAll("shop",$sql,"getBrutto");
-	if ($rs) {
-		return $rs[0]["value"];
-	} else {
-		return 0;
-	}
-}
-
-/**********************************************
-* getMwst($id)
-*
-**********************************************/
-function getMwst($id) {
-	$sql="select * from ".PREFIX."orders_total where orders_id=$id and class='ot_tax'";
-	$rs=getAll("shop",$sql,"getMwst");
-	$mwst=0;
-	if ($rs) {
-		foreach ($rs as $zeile) {
-			$mwst+=$zeile["value"];
-		}
-	}
-	return $mwst;
-}
-
-/**********************************************
-* getSonderkosten($id,$art)
-*
-**********************************************/
-function getSonderkosten($id,$art) {
-	$sql="select * from ".PREFIX."orders_total where orders_id=$id and class='".$GLOBALS["skosten"][$art]."'";
-	$rs=getAll("shop",$sql,"getSonderkosten");
-	if ($rs[0]["value"]) {
-		$kosten=round($rs[0]["value"]/(100+$GLOBALS["versand"]["TAX"])*100,2);
-	} else {
-		$kosten=false;
-	}
-	return $kosten;
-}
-
-/**********************************************
-* insBestArtikel($zeile,$transID)
-*
-**********************************************/
-function insBestArtikel($ordersID,$transID) {
-global $div07,$div16;
-	$sql="select * from ".PREFIX."orders_products where orders_id=$ordersID";
-	$rs=getAll("shop",$sql,"insBestArtikel");
-	$ok=true;
-	if ($rs) foreach ($rs as $zeile) {
-		$sql="select * from parts where partnumber='".$zeile["products_model"]."'";
-		$rs2=getAll("erp",$sql,"insBestArtikel");
-		if ( $rs2[0]["id"]) {$artID=$rs2[0]["id"]; $artNr=$rs2[0]["partnumber"]; }
-		else {
-			if ($zeile["products_tax"]=="7.0000") {
-				$artID=$div07["ID"];
-				$artNr=$div07["NR"];
-			} else {
-				$artID=$div16["ID"];
-				$artNr=$div16["NR"];
-			};
-		}
-		$preis=round($zeile["products_price"]/(100+$zeile["products_tax"])*100,2);
-		$text=getAttribut($ordersID,$zeile["orders_products_id"]);
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$transID.",".$artID.",'".$zeile["products_name"].$text."',".$zeile["products_quantity"].",".$preis.",'Stck',0,0)";
-		echo " - Artikel:[ BuNr.:$artID ArtNr:<b>$artNr</b> ".$zeile["products_name"]." ]<br>";
-		$rc=query("erp",$sql,"insBestArtikel");
-		if ($rc === -99) { $ok=false; break; };
-	}
-	return $ok;
-}
-
-function insAuftrag($data) {
-global $ERPusr,$versand,$nachn,$minder,$paypal,$auftrnr;
-	$Zahlmethode=array("authorizenet"=>"Authorize.net","banktransfer"=>"Lastschriftverfahren","cc"=>"Kreditkarte",
-		"cod"=>"Nachnahme","eustandardtransfer"=>"EU-Standard Bank Transfer","iclear"=>"iclear Rechnungskauf",
-		"invoice"=>"Rechnung","ipayment"=>"iPayment","liberecobanktransfer"=>"Lastschriftverfahren",
-		"liberecocc"=>"Kreditkarte","moneybookers"=>"Moneybookers.com","moneyorder"=>"Scheck/Vorkasse",
-		"nochex"=>"NOCHEX","paypal"=>"PayPal","pm2checkout"=>"2CheckOut","psigate"=>"PSiGate",
-		"qenta"=>"qenta.at","secpay"=>"SECPay");
-	$brutto=getBrutto($data["orders_id"]);
-	$mwst=getMwst($data["orders_id"]);
-	$netto=$brutto-$mwst;
-	$versandK=getSonderkosten($data["orders_id"],"Versand");
-	$nachnK  =getSonderkosten($data["orders_id"],"NachName");
-	$mindermK=getSonderkosten($data["orders_id"],"Minder");
-	$paypalK =getSonderkosten($data["orders_id"],"Paypal");
-	// Hier beginnt die Transaktion
-	$rc=query("erp","BEGIN","chkKunde");
-	if ($rc === -99) { echo "Probleme mit Datenbank, Abbruch!"; exit(); };
-	if ($auftrnr) {
-		$auftrag=$GLOBALS["preA"].getNextAnr();
-	} else {
-		$auftrag=$GLOBALS["preA"].$data["orders_id"];
-	}
-	$sql="select count(*) as cnt from oe where ordnumber = '$auftrag'";
-	$rs=getAll("erp",$sql,"insAuftrag");
-	if ($rs[0]["cnt"]>0) {
-		$auftrag=$GLOBALS["preA"].getNextAnr();
-	}
-	$newID=uniqid (rand());
-	$sql="insert into oe (notes,ordnumber,cusordnumber) values ('$newID','$auftrag','".$data["kdnr"]."')";
-	$rc=query("erp",$sql,"insAuftrag");
-	$sql="select * from oe where notes = '$newID'";
-	$rs2=getAll("erp",$sql,"insAuftrag");
-	if ($data["cc_type"]) {
-		$BEZAHLEN.=$data["cc_type"]."\n".$data["cc_owner"]."\n".$data["cc_number"]."\n".$data["cc_expires"]."\n";
-	} else {
-		$BEZAHLEN=$Zahlmethode[$data["payment_method"]]."\nKontoinhaber: ";
-		$BEZAHLEN.=$data["banktransfer_owner"]."\nBanknummer: ".$data["banktransfer_blz"];
-		$BEZAHLEN.="\nKontonummer: ".$data["banktransfer_number"]."\nBank: ".$data["banktransfer_bankname"]."\n";
-	}
-	$sql="update oe set cusordnumber=".$data["orders_id"].", transdate='".$data["date_purchased"]."', customer_id=".$data["kdnr"].", ";
-	$sql.="amount=".$brutto.", netamount=".$netto.", reqdate='".$data["date_purchased"]."', taxincluded='f', ";
-	if ($data["shipto"]>0) $sql.="shipto_id=".$data["shipto"].", ";
-	$sql.="intnotes='".$data["comments"]."',notes='".$BEZAHLEN."', curr='EUR',employee_id=".$ERPusr["ID"].", vendor_id=0 ";
-	$sql.="where id=".$rs2[0]["id"];
-	$rc=query("erp",$sql,"insAuftrag");
-	if ($rc === -99) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK","chkKunde");
-		return false;
-	}
-	echo "Auftrag:[ Buchungsnummer:".$rs2[0]["id"]." AuftrNr:<b>".$auftrag."</b> ]<br>";
-	if (!insBestArtikel($data["orders_id"],$rs2[0]["id"])) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK","chkKunde");
-		return false;
-	};
-	if ($versandK) {
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$rs2[0]["id"].",".$versand["ID"].",'".$versand["TXT"]."',1,".$versandK.",'mal',0,0)";
-		$rc=query("erp",$sql,"insAuftrag");
-		if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den Versandkosten<br>";
-	}
-	if ($nachnK) {
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$rs2[0]["id"].",".$nachn["ID"].",'".$nachn["TXT"]."',1,".$nachnK.",'mal',0,0)";
-		$rc=query("erp",$sql,"insAuftrag");
-		if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den Nachnamekosten<br>";
-	}
-	if ($mindermK) {
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$rs2[0]["id"].",".$minder["ID"].",'".$minder["TXT"]."',1,".$mindermK.",'mal',0,0)";
-		$rc=query("erp",$sql,"insAuftrag");
-		if ($rc === -99) echo "Auftrag $auftrag : Fehler beim Mindermengenzuschlag<br>";
-	}
-	if ($paypalK) {
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$rs2[0]["id"].",".$paypal["ID"].",'".$paypal["TXT"]."',1,".$paypalK.",'mal',0,0)";
-		$rc=query("erp",$sql,"insAuftrag");
-		if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den PayPal-Kosten<br>";
-	}
-	$rc=query("erp","COMMIT","Auftrag");
-	if ($rc === -99) {
-		echo "Probleme mit Datenbank, Abbruch!";
-		exit();
-	}
-	$sql="update ".PREFIX."orders set orders_status ='3' WHERE orders_id =".$data["orders_id"];
-	$rc=query("shop",$sql,"insBestArtikel");
-	return true;
-}
-
-/**********************************************
-* getBestellung()
-*
-**********************************************/
-function getBestellung() {
-	$sql="select b.*,h.comments,o.*,cn.kdnr from ".PREFIX."orders o left join ".PREFIX."orders_status_history h on h.orders_id=o.orders_id ";
-	$sql.="left join ".PREFIX."banktransfer b on b.orders_id =o.orders_id left join ".PREFIX."customers_number cn on ";
-	$sql.="cn.customers_id=o.customers_id where o.orders_status=1 order by o.orders_id";
-	$rs=getAll("shop",$sql,"getBestellung");
-	return $rs;
-}
-
-/**********************************************
-* chkKdData()
-*
-**********************************************/
-function chkKunden() {
-	$felder=array("firstname","lastname","company","street_address","city","postcode","country");
-	foreach ($GLOBALS["bestellungen"] as $bestellung) {
-		$rc=query("erp","BEGIN","chkKunde");
-		if ($rc === -99) { echo "Probleme mit Datenbank, Abbruch!"; exit(); };
-		if ($bestellung["kdnr"]>0) {
-			$msg="update ";
-			$kdnr=chkOldKd($bestellung);
-			if ($kdnr == -1) { //Kunde nicht gefunden, neu anlegen.
-				$msg="insert ";
-				$kdnr=insNewKd($bestellung);
-				$GLOBALS["neuKd"]++;
-			}
-		} else {
-			$msg="insert ";
-			$kdnr=insNewKd($bestellung);
-			$GLOBALS["neuKd"]++;
-		}
-		echo $bestellung["customers_company"]." ".$bestellung["customers_name"]." $kdnr<br>";
-		$GLOBALS["bestellungen"][$GLOBALS["gesKd"]]["kdnr"]=$kdnr;
-		$sql="delete from ".PREFIX."customers_number where customers_id=".$bestellung["customers_id"];
-       	$rc=query("shop",$sql,"chkKunde");
-        $sql="insert into ".PREFIX."customers_number (customers_id,kdnr) values(".$bestellung["customers_id"].",".$kdnr.")";
-       	$rc=query("shop",$sql,"chkKunde");
-		if ($kdnr>0) {
-			foreach($felder as $feld) {
-				if ($bestellung["delivery_$feld"]<>$bestellung["customers_$feld"]) {
-					$rc=insShData($bestellung,$kdnr);
-					if ($rc>0) $GLOBALS["bestellungen"][$GLOBALS["gesKd"]]["shipto"]=$rc;
-					break;
-				}
-			}
-		}
-		if (!$kdnr || $rc === -99) {
-			$rc=query("erp","ROLLBACK","chkKunde");
-			echo $msg." ".$bestellung["customers_name"]." fehlgeschlagen!<br>";
-			return false;
-		} else {
-			$rc=query("erp","COMMIT","chkKunde");
-		}
-		$GLOBALS["gesKd"]++;
-	}
-	return true;
-}
-
-function chkOldKd($data) {
-	$sql="select * from customer where id = ".$data["kdnr"];
-	$rs=getAll("erp",$sql,"chkKdData");
-	if ($rs[0]["id"]<>$data["kdnr"]) { return -1; }; // Kunde nicht gefunden
-	if ($rs[0]["zipcode"]<>$data["customers_postcode"]) $set.="zipcode='".$data["customers_postcode"]."',";
-	if ($rs[0]["city"]<>$data["customers_city"]) $set.="city='".$data["customers_city"]."',";
-	if ($rs[0]["country"]<>$GLOBALS["LAND"][$data["customers_country"]]) $set.="land='".$GLOBALS["LAND"][$data["customers_country"]]."',";
-	if ($rs[0]["phone"]<>$data["customers_phone"])$set.="phone='".$data["customers_phone"]."',";
-	if ($rs[0]["email"]<>$data["customers_email_address"])$set.="email='".$data["customers_mail_address"]."',";
-	if ($data["customers_company"]) {
-		if ($rs[0]["name"]<>$data["customers_company"]) $set.="set name='".$data["customers_company"]."',";
-		if ($rs[0]["department_1"]<>$data["customers_name"]) $set.="department_1='".$data["customers_name"]."',";
-	} else {
-		if ($rs[0]["name"]<>$data["customers_name"]) $set.="name='".$data["customers_name"]."',";
-	}
-	if ($rs[0]["street"]<>$data["customers_street_address"]) $set.="street='".$data["customers_street_address"]."',";
-	if ($set) {
-		$sql="update customer set ".substr($set,0,-1)." where id=".$rs[0]["id"];
-		$rc=query("erp",$sql,"chkKdData");
-		if ($rc === -99) {
-			return false;
-		} else {
-			return $data["kdnr"];
-		}
-	} else {
-		return $data["kdnr"];
-	}
-}
-
-/**********************************************
-* insShData($data,$id)
-*
-**********************************************/
-function insShData($data,$id) {
-	$set=$id;
-	if ($data["delivery_company"]) { $set.=",'".$data["delivery_company"]."','".$data["delivery_name"]."',"; }
-	else { $set.=",'".$data["delivery_name"]."','',"; }
-	$set.="'".$data["delivery_street_address"]."',";
-	$set.="'".$data["delivery_postcode"]."',";
-	$set.="'".$data["delivery_city"]."',";
-	$set.="'".$data["delivery_country"]."',";
-	$set.="'".$data["customers_telephone"]."',";
-	$set.="'".$data["customers_email_address"]."'";
-	$sql="insert into shipto (trans_id,shiptoname,shiptodepartment_1,shiptostreet,shiptozipcode,shiptocity,";
-	$sql.="shiptocountry,shiptophone,shiptoemail,module) values ($set,'CT')";
-	$rc=query("erp",$sql,"insShData");
-	if ($rc === -99) return false;
-	$sql="select shipto_id from shipto where trans_id = $id and module='CT' order by itime desc limit 1";
-	$rs=getAll("erp",$sql,"insKdData");
-	if ($rs[0]["shipto_id"]>0) {
-		$sid=$rs[0]["shipto_id"];
-		$sql="update ".PREFIX."customers_number set shipto = $sid where kdnr = $id";
-        $rc2=query("shop",$sql,"insShData");
-        if ($rc2 === -99) {
-			return false;
-		}
-	} else  {
-		echo "Fehler bei abweichender Anschrift ".$data["delivery_name"];
-	}
-	if ($rc === -99) {
-		return false;
-	} else {
-		return $sid;
-	}
-}
-
-/**********************************************
-* insKdData($BID)
-*
-**********************************************/
-function insNewKd($data) {
-	$taxid=array("DE"=>0,"CH"=>2,"AU"=>1,"FR"=>1,"IT"=>1,"ES"=>1,"NL"=>1); // Muß erweitert werden
-	$newID=uniqid(rand(time(),1));
-	//Kundennummer generieren
-	if ($GLOBALS["kdnum"]==1) { // von der ERP
-		$kdnr=$GLOBALS["preK"].getNextKnr();
-	} else {		    // durch Shop
-		$kdnr=$GLOBALS["preK"].$data["customers_id"];
-	}
-	$sql="select count(*) as cnt from customer where customernumber = '$kdnr'";
-	$rs=getAll("erp",$sql,"insKdData");
-	if ($rs[0]["cnt"]>0) {  // Kundennummer gibt es schon, eine neue aus ERP
-		$kdnr=$GLOBALS["preK"].getNextKnr();
-	}
-	$sql="insert into customer (name,customernumber) values ('$newID','$kdnr')";
-	$rc=query("erp",$sql,"insKdData");
-	if ($rc === -99) return false;
-	$sql="select * from customer where name = '$newID'";
-	$rs=getAll("erp",$sql,"insKdData");
-	if (!$rs) return false;
-	if ($data["customers_company"]) {
-		$set.="set name='".$data["customers_company"]."',contact='".$data["customers_name"]."',";
-	}else {
-		$set.="set name='".$data["customers_lastname"].", ".$data["customers_firstname"]."',";
-	}
-	$set.="street='".$data["customers_street_address"]."',";
-	$set.="zipcode='".$data["customers_postcode"]."',";
-	$set.="city='".$data["customers_city"]."',";
-	$set.="country='".$data["billing_country_iso_code_2"]."',";
-	$set.="phone='".$data["customers_telephone"]."',";
-	$set.="email='".$data["customers_email_address"]."',";
-	$tid=(in_array($data["billing_country_iso_code_2"],$taxid))?$taxid[$data["billing_country_iso_code_2"]]:3;
-	$set.="taxzone_id=$tid,";
-	$set.="taxincluded='f' ";
-	$sql="update customer ".$set;
-	$sql.="where id=".$rs[0]["id"];
-	$rc=query("erp",$sql,"insKdData");
-	if ($rc === -99) { return false; }
-	else { return $rs[0]["id"]; }
-}
-
-$LAND=array("Germany"=>"D","Austria"=>"A","Switzerland"=>"CH");
-$skosten=array("Versand"=>"ot_shipping","NachName"=>"ot_cod_fee","Paypal"=>"ot_cod_fee","Minder"=>"ot_loworderfee");
-$bestellungen=getBestellung();
-$ok=count($bestellungen);
-$gesKd=0;
-$neuKd=0;
-if ($ok) {
-	echo "Es liegen $ok Bestellungen vor. <br>";
-	chkKunden();
-	echo $gesKd." Kunde(n), davon ".$neuKd." neue(r) Kunde(n).<br>";
-	foreach ($bestellungen as $bestellung) {
-		$ok=insAuftrag($bestellung);
-	}
-} else { echo "Es liegen keine Bestellungen vor!<br>"; };
-?>
-<!--a href='trans.php'>zur&uuml;ck</a-->
-</body>
-</html>
diff --git a/olcom/pixel_trans.gif b/olcom/pixel_trans.gif
deleted file mode 100644
index e7749f217..000000000
Binary files a/olcom/pixel_trans.gif and /dev/null differ
diff --git a/olcom/readme.first b/olcom/readme.first
deleted file mode 100644
index 6df2180e9..000000000
--- a/olcom/readme.first
+++ /dev/null
@@ -1,97 +0,0 @@
-Shop - Schnittstelle Lx-ERP <-> osCommerce/xt:Commerce
-
-Vorraussetzungen:
-	Lx-ERP Version >= 2.4.0
-	xt:Commerce 2.0 RC1.2
-	Pear DB, PHP-ImageMagick
-
-Installation:
-Das tar-File unterhalb vom Webserververzeichnis oder dem ERP-Verzeichnis entpacken.
-
-	$ cd /var/www/html
-	$ tar xzf /pfad/zu/xtcomm.tgz
-
-In das Verzeichnis oscomm wechseln und Schreibrechte auf die Datei conf.php und 
-das Verzeichnis tmp f�r den Webbenutzer (apache,www-data,httpd) vergeben.
-
-	$ chown apache conf.php
-	$ chmod 600 conf.php
-	$ chown apache tmp
-
-Im Browser folgende URL aufrufen:
-
-	http://webserver/pfad/xtcomm/confedit.php
-
-	z.B.: http://localhost/xtcomm/confedit.php
-
-Benutzer und Kennwort f�r die Erstinstallation sind:
-
-	xtcom / xtcom
-
-Die Maske sogf�lltig ausf�llen.
-
-	db-Host		db-Server f�r die jeweilige Anwendung
-	Database	Namen der Datenbankinstanzen
-	db-User		Username und Kennwort f�r die jeweilige Instanz
-	User-ID		Mit dieser ID soll in die ERP geschrieben werden
-	CSV-Dir		hier wird die csv-Datei erwartet (Schreibrechte!)
-	Image-Dir	hier liegen die Bilder
-	ftp-Host	Webserver der jeweiligen Anwendung
-	ftp-User	Name und Kennwort f�r ftp-Zugang
-	ID-xxxx		Interne ID der Waren. Lx-ERP:
-	Shopsprache	Die Id der Voreingestellten Sprache. Nur f�r diese 
-				werden die Artikel eingestellt.
-	Bildergr��e	in Byte
-
-Das Formular abschicken. 
-
-Sollen sp�ter �nderungen durchgef�hrt werden, so mu� bei der Anmeldung 
-der ERP-ftp-User als Benutzer verwendet werden.
-
-In der Shopinstanz mu� noch eine Tabelle angelegt werden. Das wird 
-normalerweise durch das Programm condedit.php erledigt. Sollte das aus 
-irgend einem Grund nicht funktionieren, f�hren Sie dazu die
-Datei oscom.sql als Datenbankbenutzer auf die Shopinstanz aus.
-
-	$ mysql -p -u dbuser dbinstanz < xtcom.sql
-	Enter password:
-
-Ist diese Tabelle nicht angelegt, werden Kunden in der ERP immer wieder neu 
-angelegt.
-
-Fehlerquellen:
-Befinden sich ERP und Shop nicht auf dem gleichen Server, achten Sie darauf, das
-die entsprechende Datenbank von Aussen erreichbar ist. Dazu m�ssen folgende Ports 
-freigeschaltet werden:
-
-	MySQL		3306
-	PostgreSQL	5432
-
-Auch mu� auf dem Shopserver ein ftp-Dienst eingerichtet werden, wenn Bilder �ber-
-tragen werden sollen. Die Firewal ist entsprechend anzupassen.
-
-Arbeiten:
-In der ERP kann nun bei den Artikeln das H�ckchen Shop gesetzt werden.
-Bitte auch eine Warengruppe vergeben, da sonst alle Artikel in Default landen.
-Da die ERP nur eine Kategorieebene verwalten kann, mu� der ganze Kategorienpfad
-hintelegt werden. Die einzelnen Kategorien werden durch Ausrufezeichen (!) getrennt.
-
-	Hardware -> Monitore -> LCD = Hardware!Monitore!LCD
-
-Die URL f�r die Shopschnittstelle lautet:
-
-	http://webservername/pfad/xtcom/trans.php
-
-
-Die Schnittstelle kann auch in die ERP integriert werden. Dazu installieren Sie
-die Schnittstelle wie beschrieben unterhalb der ERP. 
-Erweitern Sie die menu.ini um die Eintr�ge im xtcom-Verzeichnis. z.B.:
-
-	$ cat /pfad/zu/xtcom/menu.ini >> /pfad/zu/lx-erp/menu.ini
-
-Unter dem Men�punkt Shop stehen Ihnen nun die Module shopimport_db und xtcomexport 
-zur Verf�gung.
-
-Copyright:
-Die Schnittstelle mit ihren einzelnen Bestandteilen steht unter der "Artistic License".
-Das Copyright geh�rt Holger Lindemann. 
diff --git a/olcom/s2e.gif b/olcom/s2e.gif
deleted file mode 100644
index cd29ee3f0..000000000
Binary files a/olcom/s2e.gif and /dev/null differ
diff --git a/olcom/shopimport_csv.php b/olcom/shopimport_csv.php
deleted file mode 100644
index 53637c9b1..000000000
--- a/olcom/shopimport_csv.php
+++ /dev/null
@@ -1,174 +0,0 @@
-<?php
-/***************************************************************
-* $Id: shopimport_csv.php,v 1.2 2004/06/30 08:31:35 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.0
-*Shop: olCommerce 1.2.2
-***************************************************************/
-
-require_once "DB.php";
-require_once "conf.php";
-if ($dbprefix<>"") { define("PREFIX",$dbprefix."_"); } else { define("PREFIX",""); }
-
-$LAND=array("Germany"=>"D");
-$db=DB::connect($SHOPdns);
-if (!$db) dbFehler("",$db->getDebugInfo());
-if (DB::isError($db)) {
-	dbFehler("",$db->getDebugInfo());
-	die ($db->getDebugInfo());
-};
-
-function createCategory($name,$maingroup) {
-global $db,$langs;
-	$newID=uniqid(rand());
-	$sql="insert into ".PREFIX."categories (categories_image,parent_id,date_added) values ('$newID',$maingroup,now())";
-	$rc=$db->query($sql);
-	$sql="select * from ".PREFIX."categories where categories_image = '$newID'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$id=$rs[0]["categories_id"];
-	$sql="update ".PREFIX."categories set categories_image = null where categories_id=$id";
-	$rc=$db->query($sql);
-	echo "($name) ";
-	foreach ($langs as $LANG) {
-		$sql="insert into ".PREFIX."categories_description (categories_id,language_id,categories_name) values ($id,$LANG,'$name')";
-		$rc=$db->query($sql);
-		if (!$rc) break;
-	}
-	return ($rc)?$id:false;
-}
-function getCategory($name) {
-global $db;
-	if (empty($name)) $name="Default";
-	$tmp=split("!",$name);
-	$maingroup=0;
-	$found=true;
-	$i=0;
-	do {
-		$sql="select D.*,C.parent_id from ".PREFIX."categories C left join ".PREFIX."categories_description D on C.categories_id=D.categories_id where categories_name like '".$tmp[$i]."' and C.parent_id=$maingroup";
-		$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ($rs[0]["categories_id"]) {
-			$maingroup=$rs[0]["categories_id"];
-			echo $maingroup.":".$rs[0]["categories_name"]." ";
-			$i++;
-		} else {
-			$found=false;
-		}
-	} while ($rs and $found and $i<count($tmp));
-	for (;$i<count($tmp); $i++) {
-		$maingroup=createCategory($tmp[$i],$maingroup);
-	}
-	return $maingroup;
-}
-function insartikel($data) {
-global $db,$header,$tax,$defLang;
-	$newID=uniqid(rand());
-	$sql="insert into ".PREFIX."products (products_model,products_image) values ('".$data[array_search("products_model")]."','$newID')";
-	$rc=$db->query($sql);
-	$sql="select * from ".PREFIX."products where products_image='$newID'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$sql="update ".PREFIX."products set products_image=null,products_status=1 where products_id=".$rs[0]["products_id"];
-	$rc=$db->query($sql);
-	$sql="insert into ".PREFIX."products_description (products_id,language_id,products_name) values (".$rs[0]["products_id"].",$defLang,' ')";
-	$rc=$db->query($sql);
-	$sql="insert into ".PREFIX."products_to_categories (products_id,categories_id) values (".$rs[0]["products_id"].",".$data["categories_id"].")";
-	$rc=$db->query($sql);
-	echo " <b>insert</b> ";
-	updartikel($data,$rs[0]["products_id"]);
-}
-function updartikel($data,$id) {
-global $db,$header,$tax,$defLang;
-	$sql="update ".PREFIX."products set products_price=%01.2f,products_weight=%01.2f,products_tax_class_id=%d,products_last_modified=now()  where products_id=%d";
-	$sql=sprintf($sql,$data[array_search("products_price",$header)],$data[array_search("products_weight",$header)],$tax[$data[array_search("products_tax",$header)]],$id);
-	$rc=$db->query($sql);
-	$sql="update ".PREFIX."products_description set products_name='%s',products_description='%s' where products_id=%d and language_id=$defLang";
-	$sql=sprintf($sql,$data[array_search("products_name",$header)],$data[array_search("products_description",$header)],$id);
-	$rc=$db->query($sql);
-	$sql="update ".PREFIX."products_to_categories set categories_id=".$data[array_search("categories_id",$header)]." where products_id=$id";
-	$rc=$db->query($sql);
-	echo "(".$id." ".$data[array_search("products_name",$header)].")+++<br>";
-}
-function chkartikel($data) {
-global $db,$header,$tax;
-	$sql="select * from ".PREFIX."products P left join ".PREFIX."products_description D on P.products_id=D.products_id left join ".PREFIX."products_to_categories C on P.products_id=C.products_id where  products_model like '".$data[array_search("products_model",$header)]."' and language_id=2";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs) {
-			 if ($rs[0]["products_price"]<>$data[array_search("products_price",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_weight"]<>$data[array_search("products_weight",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_name"]<>$data[array_search("products_name",$header)])		{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_description"]<>$data[array_search("products_description",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_tax_class_id"]<>$tax[$data[array_search("products_tax",$header)]])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["categories_id"]<>$data[array_search("categories_id",$header)])		{ updartikel($data,$rs[0]["products_id"]); }
-		else { echo "(".$rs[0]["products_id"]." ".$rs[0]["products_name"].")...<br>"; };
-	} else {
-		insartikel($data);
-	}
-}
-
-$sql="select languages_id from languages";
-$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$langs[]=$zeile["languages_id"];
-	}
-} else {
-	$langs[]=1;
-}
-$sql="select * from ".PREFIX."languages L left join ".PREFIX."configuration C on L.code=C.configuration_value where  configuration_key = 'DEFAULT_LANGUAGE'";
-$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($rs) {
-	$defLang=$rs[0]["languages_id"];
-} else {
-	$defLang=$SHOPlang;
-}
-$sql="select * from ".PREFIX."tax_rates";
-$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$tax[$zeile["tax_rate"]]=$zeile["tax_class_id"];
-	}
-} else {
-	$tax[0]="";
-}
-
-if ($_FILES["csv"]["name"] || ($_POST["nofile"] && file_exists($SHOPdir)) ) {
-	if ($_FILES["csv"]["tmp_name"]) {
-		move_uploaded_file($_FILES["csv"]["tmp_name"],$SHOPdir);
-	}
-	$f=fopen($SHOPdir,"r");
-	$header=fgetcsv($f,1000,";");
-	$header[]="categories_id";
-	$data=fgetcsv($f,1000,";");
-	while (!feof($f)) {
-		$catId=getCategory($data[array_search("categories_name",$header)]);
-		$data[]=$catId;
-		chkartikel($data);
-		$data=fgetcsv($f,1000,";");
-	}
-	fclose($f);
-	echo "<a href='trans.php'>zur&uuml;ck</a>";
-} else {
-?>
-<html>
-	<head>
-		<title>Datenaustausch ERP-xt:Commerce</title>
-	</head>
-<body>
-<center>
-<br>
-<h1>Artikelimport aus csv-Datei in xt:Commerce</h1><br>
-<form name="csv" action="shopimport_csv.php" enctype="multipart/form-data" method="post">
-	<INPUT TYPE="hidden" name="MAX_FILE_SIZE" value="500000">
-	<input type="checkbox" name="nofile" value="1">Auf dem Server vorhandene Daten importieren<br>
-	Datenfile f&uuml;r Import <input type="file" name="csv"><br>
-	<input type="submit" name="ok" value="ok">
-</form>
-</center>
-<a href="trans.php">zur&uuml;ck</a>
-</body>
-</html>
-<?
-}
-?>
diff --git a/olcom/shopimport_db.php b/olcom/shopimport_db.php
deleted file mode 100644
index 917d3b1fc..000000000
--- a/olcom/shopimport_db.php
+++ /dev/null
@@ -1,442 +0,0 @@
-<?php
-/***************************************************************
-* $Id: shopimport_db.php,v 2.0 2006/10/26 10:49:11 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 2.0
-*Shop: xt:Commerce 3.04
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-require_once "shoplib.php";
-
-
-/*******************************************
-* createCategoryLang($id,$lang,$name)
-* Kategorie für eine Sprache anlegen. Ist immer
-* in der gleichen Sprache, da ERP nur eine hat.
-*******************************************/
-function createCategoryLang($id,$lang,$name) {
-	$sql="insert into ".PREFIX."categories_description (categories_id,language_id,categories_name,categories_meta_title) ";
-	$sql.="values ($id,$lang,'$name','$name')";
-	$rc=query("shop",$sql,"createCategoryLang");
-	return $rc;
-}
-
-/*******************************************
-* createCategory($name,$maingroup,$Lang,$Lanuages)
-* Eine Kategorie in der default-Sprache anlegen
-*******************************************/
-function createCategory($name,$maingroup,$Lang,$Languages) {
-	echo "Kategorie: $name<br>";
-	//Kategorie nicht vorhanden, anlegen
-	$newID=uniqid(rand());
-	$sql="insert into ".PREFIX."categories (categories_image,parent_id,date_added) values ('$newID',$maingroup,now())";
-	$rc=query("shop",$sql,"createCategory_1");
-	if ($rc === -99) return false;
-	$sql="select * from ".PREFIX."categories where categories_image = '$newID'";
-	$rs=getAll("shop",$sql,"createCategory_2");
-	$id=$rs[0]["categories_id"];
-	$sql="update ".PREFIX."categories set categories_image = null where categories_id=$id";
-	$rc=query("shop",$sql,"createCategory_3");
-	if ($rc === -99) return false;
-	createCategoryLang($id,$Lang,$name);
-	if ($Languages) foreach ($Languages as $erp=>$shop) {
-		if ($Lang<>$shop) {
-			createCategoryLang($id,$shop,$name);
-		}
-	}
-	return ($rc !== -99)?$id:false;
-}
-
-/*******************************************
-* getCategory($name,$Lang,$Languages)
-* gibt es die Kategorie schon?
-*******************************************/
-function getCategory($name,$Lang,$Languages) {
-	if (empty($name)) $name="Default";
-	$tmp=split("!",$name);
-	$maingroup=0;
-	$found=true;
-	$i=0;
-	do {
-		$sql="select D.*,C.parent_id from ".PREFIX."categories C left join ".PREFIX."categories_description D on C.categories_id=D.categories_id ";
-		$sql.="where (categories_name = '".$tmp[$i]."' or categories_meta_title ='".$tmp[$i]."') and ";
-		$sql.="C.parent_id=$maingroup and language_id=$Lang";
-		$rs=getAll("shop",$sql,"getCategory");
-		if ($rs) {
-			$maingroup=$rs[0]["categories_id"];
-			$i++;
-		} else {
-			$found=false;
-		}
-	} while ($rs and $found and $i<count($tmp));
-	for (;$i<count($tmp); $i++) {
-		$maingroup=createCategory($tmp[$i],$maingroup,$Lang,$Languages);
-	}
-	return $maingroup;
-}
-
-
-/*******************************************
-* bilder($width,$height,$dest
-* Bild in der gewünschten Größe erzeugen
-*******************************************/
-function bilder($width,$height,$dest) {
-	if (!function_exists("imagick_readimage")) { echo "Imagick-Extention nicht installiert"; return false; };
-	$handle=imagick_readimage("./tmp/tmp.file_org");
-	if (!$handle) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Lesen: $reason<BR>\n" ; flush();
-		return false;
-	}
-	if (!imagick_resize( $handle, $width, $height, IMAGICK_FILTER_UNKNOWN, 0)) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Resize: $reason<BR>\n" ;	flush();
-		return false;
-	}
-	if (!imagick_writeimage( $handle,"./tmp/tmp.file_$dest")) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Schreiben: $reason<BR>\n" ; 	flush();
-		return false;
-	}
-	return true;
-}
-
-/*******************************************
-* uploadImage($image,$id)
-* Ein Bild zum Shop übertragen
-*******************************************/
-function uploadImage($image,$id) {
-global $ERPftphost,$ERPftpuser,$ERPftppwd,$ERPimgdir,$SHOPftphost,$SHOPftpuser,$SHOPftppwd,
-		$SHOPimgdir,$picsize;
-	$picdest = array("thumb"=>"thumbnail_images","info"=>"info_images","popup"=>"popup_images","org"=>"original_images");
-	$ok=true;
-	// Bilder holen
-	if ($ERPftphost=="localhost")
-	{
-		$aus=""; $rc2=0;
-		if (is_file($ERPimgdir."/".$image)) {
-			$rc3=@exec("cp $ERPimgdir/$image ./tmp/tmp.file_org",$aus,$rc2);
-			if ($rc2>0) { $ok=false; echo "[Downloadfehler: $image]<br>"; };
-		} else {
-                        echo "[Downloadfehler: $ERPimgdir/$image nicht gefunden]";
-                        return false;
-                }
-	} else {
-		$conn_id = ftp_connect($ERPftphost);
-		if ($conn_id==false) {
-			echo "[Kein FTP-Verbindung ERP]";
-			return false;
-		}
-		ftp_login($conn_id,$ERPftpuser,$ERPftppwd);
-		$src=$ERPimgdir."/".$image;
-		$upload=ftp_get($conn_id,"tmp/tmp.file_org","$src",FTP_BINARY);
-		if (!$upload) { $ok=false; echo "[Ftp Downloadfehler: $image]<br>";};
-		ftp_quit($conn_id);
-	}
-	if ($ok) {
-		//Bildergrößen erzeugen
-		if (!bilder($picsize["PRODUCT_IMAGE_THUMBNAIL_WIDTH"],$picsize["PRODUCT_IMAGE_THUMBNAIL_HEIGHT"],"thumb")) return false;
-		if (!bilder($picsize["PRODUCT_IMAGE_INFO_WIDTH"],$picsize["PRODUCT_IMAGE_INFO_HEIGHT"],"info")) return false;
-		if (!bilder($picsize["PRODUCT_IMAGE_POPUP_WIDTH"],$picsize["PRODUCT_IMAGE_POPUP_HEIGHT"],"popup")) return false;
-		$name=(strrpos($image,"/")>0)?substr($image,strrpos($image,"/")+1):$image;
-		//zum Shop übertragen
-		if ($SHOPftphost=="localhost") {
-			foreach ($picdest as $key => $val) {
-				if (is_dir($SHOPimgdir."/".$val."/")) {
-					$src=$SHOPimgdir."/".$val."/".$name;
-					$rc2=0; $aus="";
-					$rc3=@exec("cp ./tmp/tmp.file_$key $src",$aus,$rc2);
-					if ($rc2>0) { $ok=false; echo "[Uploadfehler: $src]"; };
-				} else {
-					echo "[Uploadfehler: $val nicht gefunden]";
-					return false;
-				}
-			}
-		} else {
-			$conn_id = ftp_connect($SHOPftphost);
-			if ($conn_id==false) {
-				echo "[Kein FTP-Verbindung Shop]";
-				return false;
-			}
-			ftp_login($conn_id,$SHOPftpuser,$SHOPftppwd);
-			foreach ($picdest as $key => $val) {
-				$src=$SHOPimgdir."/".$val."/".$name;
-				$upload=ftp_put($conn_id,"$src","tmp/tmp.file_".$key,FTP_BINARY);
-				if (!$upload) { $ok=false; echo $key."[FTP Uploadfehler $src]<br>";};
-			}
-			ftp_quit($conn_id);
-		}
-		if ($ok) {
-			$sql="update ".PREFIX."products set products_image='%s',products_last_modified=now() where products_id=%d";
-			$sql=sprintf($sql,$name,$id);
-			$rc=query("shop",$sql,"uploadImage");
-			if ($rc === -99) return false;
-			echo "i";
-		}
-	}
-	return true;
-}
-
-/*******************************************
-* insartikel($data,$defLang
-* Einen neuen Artikel im Shop anlegen
-*******************************************/
-function insartikel($data,$defLang) {
-	$newID=uniqid(rand());
-	$sql="insert into ".PREFIX."products (products_model,products_image) values ('".$data["partnumber"]."','$newID')";
-	$rc=query("shop",$sql,"insartikel_1");
-	if ($rc === -99) return false;
-	$sql="select * from ".PREFIX."products where products_image='$newID'";
-	$rs=getAll("shop",$sql,"insartikel_2");
-	$sql="update products set products_image=null where products_id=".$rs[0]["products_id"];
-	$rc=query("shop",$sql,"insartikel_3");
-	if ($rc === -99) return false;
-	$sql="insert into ".PREFIX."products_to_categories (products_id,categories_id) values ";
-	$sql.="(".$rs[0]["products_id"].",".$data["categories_id"].")";
-	$rc=query("shop",$sql,"insartikel_4");
-	if ($rc === -99) return false;
-	echo " + ";
-	updartikel($data,$rs[0]["products_id"],$defLang);
-	return $rs[0]["products_id"];
-}
-
-/*******************************************
-*
-*
-*******************************************/
-function updartikel($data,$id,$defLang) {
-global $tax,$KDGrp;
-	echo $id." ";
-	$sql="update ".PREFIX."products set products_status=1,products_price=%01.2f,products_weight=%01.2f,";
-	$sql.="products_tax_class_id=%d,products_last_modified=now(),products_quantity=%d where products_id=%d";
-	$price=($data["sellprice"]>0)?$data["sellprice"]:$data["stdprice"];
-	$sql=sprintf($sql,$price,$data["weight"],$tax[sprintf("%1.4f",$data["rate"])],$data["onhand"],$id);
-	$rc=query("shop",$sql,"updartikel_1");
-	$sql="update ".PREFIX."products_to_categories set categories_id=".$data["categories_id"]." where products_id=$id";
-	$rc=query("shop",$sql,"updartikel_2");
-	echo "~";
-	if ($KDGrp>0) personal_offer ($data["altprice"],$id);
-	$sql="select * from ".PREFIX."products_description where products_id=$id and language_id=$defLang";
-	$rs=getAll("shop",$sql,"updartikel_3");
-	if ($rs) {  // bestehende Sprachen abgleichen
-		$sql="update ".PREFIX."products_description set products_name='%s',products_description='%s' where ";
-		$sql.="products_id=%d and language_id=$defLang";
-		$sql=sprintf($sql,$data["description"],$data["notes"],$id);
-		echo "l";
-	} else {  // neue Sprache einfügen
-		$sql="insert into ".PREFIX."products_description (products_id,products_name,products_description,language_id) ";
-		$sql.="values (%d,'%s','%s',%d)";
-		$sql=sprintf($sql,$id,$data["description"],$data["notes"],$defLang);
-		echo "L";
-	}
-	$rc=query("shop",$sql,"updartikel_4");
-	if ($rc === -99) { return false;
-	} else { return true; }
-}
-
-/*******************************************
-* personal_offer ($personal_offer,$products_id)
-* Spezialangebote anlegen
-*******************************************/
-function personal_offer ($personal_offer,$products_id) {
-global $KDGrp;
-	$sql="select * from ".PREFIX."personal_offers_by_customers_status_$KDGrp where ";
-	$sql.="products_id=$products_id order by quantity limit 1";
-	$rs=getAll("shop",$sql,"personal_offer_1");
-	if ($rs) {
-		if ($personal_offer) {
-			$sql="update ".PREFIX."personal_offers_by_customers_status_$KDGrp ";
-			$sql.="set personal_offer=$personal_offer where price_id = ".$rs[0]["price_id"];
-			echo "p";
-		} else {
-			$sql="delete from ".PREFIX."personal_offers_by_customers_status_$KDGrp where price_id = ".$rs[0]["price_id"];
-			echo "q";
-		}
-		$rc=query("shop",$sql,"personal_offer_2");
-	} else {
-		if ($personal_offer) {
-			$sql="insert into ".PREFIX."personal_offers_by_customers_status_$KDGrp ";
-			$sql.="(price_id,products_id,quantity,personal_offer) ";
-			$sql.="values (0,$products_id,1,$personal_offer)";
-			$rc=query("shop",$sql,"personal_offer_3");
-			if ($rc === -99) return false;
-			echo "P";
-		}
-	};
-	return true;
-}
-
-/*******************************************
-* chkartikellang($data,$Lang)
-* Gibt es den Artikel und hat er sich geändert
-*******************************************/
-function chkartikellang($data,$Lang) {
-global $tax,$KDGrp,$GeoZone;
-	if ($data["partnumber"]=="") { echo "Artikelnummer fehlt!<br>"; return false;};
-	echo $data["partnumber"]." ".$data["translation"]." -> ";
-	$sql ="select P.products_id from ".PREFIX."products P left join ".PREFIX."products_description PD on P.products_id=PD.products_id where ";
-	$sql.="products_model like '".$data["partnumber"]."' and language_id=$Lang";
-	$rs=getAll("shop",$sql,"chkartikellang");
-	if (count($rs)>0) {
-		$sql="update ".PREFIX."products_description set products_name='".$data["translation"]."', products_description='".$data["longdescription"]."' ";
-		$sql.="where products_id='".$rs[0]["products_id"]."' and language_id=$Lang";
-		$rc=query("shop",$sql,"chkartikellang_u");
-		if ($rc === -99) return false;
-	} else {
-		$sql ="select products_id from ".PREFIX."products where products_model like '".$data["partnumber"]."'";
-		$rs=getAll("shop",$sql,"chkartikellang");
-		$sql="insert into ".PREFIX."products_description (products_id,language_id,products_name,products_description) values (";
-		$sql.=$rs[0]["products_id"].",$Lang,'".$data["translation"]."','".$data["longdescription"]."')";
-		$rc=query("shop",$sql,"chkartikellang_i");
-		if ($rc === -99) return false;
-	}
-	echo $rs[0]["products_id"]."<br>\n";
-	return true;
-}
-
-/*******************************************
-* chkartikel($data,$defLang)
-* Hat sich der Artikel verändert
-*******************************************/
-function chkartikel($data,$defLang) {
-global $tax,$erptax,$KDGrp,$GeoZone,$nopic;
-	if ($data["partnumber"]=="") { echo "Artikelnummer fehlt!<br>"; return;};
-	if ($data["image"]) {
-		$data["picname"]=(strrpos($data["image"],"/")>0)?substr($data["image"],strrpos($data["image"],"/")+1):$data["image"];
-	} else if ($nopic) {
-		$data["picname"]=(strrpos($nopic,"/")>0)?substr($nopic,strrpos($nopic,"/")+1):$nopic;
-		$data["image"]=$nopic;
-	}
-	$data["onhand"]=floor($data["onhand"]);
-	echo $data["partnumber"]." ".$data["description"]." -> ";
-	$sql ="select * from ".PREFIX."products where products_model like '".$data["partnumber"]."'";
-	$rs=getAll("shop",$sql,"chkartikel");
-	$data["rate"]=$erptax[$data["bugru"]]["rate"];
-	if ($rs) {
-		updartikel($data,$rs[0]["products_id"],$defLang);
-		if ($rs[0]["products_image"]<>$data["picname"] and $data["picname"]) uploadImage($data["image"],$rs[0]["products_id"]);
-	} else {
-		$id=insartikel($data,$defLang);
-		if ($data["image"]) uploadImage($data["image"],$id);
-	}
-	echo "<br>\n";
-}
-
-/*******************************************
-* Grafiken
-*******************************************/
-//Defaultwerte
-$picsize= array("PRODUCT_IMAGE_THUMBNAIL_WIDTH" => 120,"PRODUCT_IMAGE_THUMBNAIL_HEIGHT" => 80,
-		"PRODUCT_IMAGE_INFO_WIDTH" => 200,"PRODUCT_IMAGE_INFO_HEIGHT" => 160,
-		"PRODUCT_IMAGE_POPUP_WIDTH" => 300,"PRODUCT_IMAGE_POPUP_HEIGHT" => 240,"IMAGE_QUALITY" => 80);
-//persönliche Werte
-foreach ($picsize as $key => $val) {
-	$sql=sprintf("select configuration_value from ".PREFIX."configuration where configuration_key='%s'",$key);
-	$rs=getAll("shop",$sql,"Konfiguration");
-	if ($rs[0][$key]) $picsize[$key]=$rs[0][$key];
-}
-
-/*******************************************
-* Steuern
-*******************************************/
-//Steuertabelle ERP
-$sql ="select  BG.id as bugru,T.rate,TK.startdate from buchungsgruppen BG left join chart C ";
-$sql.="on BG.income_accno_id_0=C.id left join taxkeys TK on TK.chart_id=C.id left join tax T ";
-$sql.="on T.id=TK.tax_id where TK.startdate <= now()";
-$rs=getAll("erp",$sql,"Tax ERP");
-$erptax=array();
-foreach ($rs as $row) {
-	if ($erptax[$row["bugru"]]["startdate"]<$row["startdate"]) {
-		$erptax[$row["bugru"]]["startdate"]=$row["startdate"];
-		$erptax[$row["bugru"]]["rate"]=$row["rate"]*100;
-	}
-}
-
-//Steuerzone Shop
-$sql="select GZ.geo_zone_id from ".PREFIX."configuration C, ".PREFIX."zones_to_geo_zones GZ ";
-$sql.="where C.configuration_key='STORE_COUNTRY' and GZ.zone_country_id=C.configuration_value";
-$rs=getAll("shop",$sql,"GZ");
-if ($rs) {
-	$GeoZone=$rs[0]["geo_zone_id"];
-} else {
-	echo "Steuerzone nicht gefunden";
-	exit;
-}
-
-//Steuersätze
-$sql="select * from ".PREFIX."tax_rates where tax_zone_id=$GeoZone";
-$rs=getAll("shop",$sql,"tax_rates");
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$tax[$zeile["tax_rate"]]=$zeile["tax_class_id"];
-	}
-} else {
-	$tax[0]="";
-}
-
-/*******************************************
-* Sprache
-*******************************************/
-if (empty($Language) || !$Language) {
-	echo "Keine Sprachzuordnung definiert!";
-	exit;
-}
-
-//Default Shopsprache ermitteln
-$sql="select * from ".PREFIX."languages L left join ".PREFIX."configuration C on L.code=C.configuration_value ";
-$sql.="where  configuration_key = 'DEFAULT_LANGUAGE'";
-$rs=getAll("shop",$sql,"DefaultLang");
-
-if ($rs) {
-        $ShopdefaultLang=$rs[0]["languages_id"];
-	if ($SHOPdefaultlang<>$ShopdefaultLang) {
-		echo "Defaultsprache im Shop wurde geändert";
-		exit;
-	}
-} else  {
-	echo "Keine Defaultsprache im Shop eingestellt.";
-	exit;
-}
-
-$Languages=array();
-foreach ($Language as $Langrow) {
-	if ($Langrow["SHOP"]>0 and $Langrow["ERP"]>0) $Languages[$Langrow["ERP"]]=$Langrow["SHOP"];
-}
-
-/*******************************************
-* Import starten
-*******************************************/
-$artikel=shopartikel(); //array_keys($Languages));
-
-echo "Artikelexport ERP -&gt; xt:Commerce (Standardsprache $ShopdefaultLang): ".count($artikel)." Artikel markiert.<br>";
-
-if ($artikel) { //Mit jedem Artikel in der Defaultsprache:
-	foreach ($artikel as $data) {
-		//Kategorie abfragen/anlegen
-		$data["categories_id"]=getCategory($data["partsgroup"],$ShopdefaultLang,$Languages);
-		chkartikel($data,$ShopdefaultLang,false);
-	}
-
-	foreach ($Languages as $erplang=>$shoplang) { //Mit jeder weiteren Sprache
-		$artikel=shopartikellang($erplang,$SpracheAlle);
-		echo "Shopsprache: $shoplang<br>";
-		if ($artikel) {
-			foreach ($artikel as $data) {
-				//Kategorie abfragen
-				$data["categories_id"]=getCategory($data["partsgroup"],$shoplang,$Languages);
-				if ($SpracheAlle) {
-					if ($data["translation"]=="") $data["translation"]=$data["description"];
-					if ($data["longdescription"]=="") $data["longdescription"]=$data["notes"];
-				}
-				chkartikellang($data,$shoplang);
-			}
-		}
-	}
-} else {
-	if ($debug) writelog("Fehler\n");
-}
-
-?>
diff --git a/olcom/shoplib.php b/olcom/shoplib.php
deleted file mode 100644
index 4ccaa1a99..000000000
--- a/olcom/shoplib.php
+++ /dev/null
@@ -1,287 +0,0 @@
-<?php
-
-$login=$_GET["login"];
-$debug=false;
-require_once "DB.php";
-require_once "conf$login.php";
-
-if ($dbprefix<>"") { define("PREFIX",$dbprefix."_"); } else { define("PREFIX",""); };
-
-$landarray=array("DEUTSCHLAND"=>"D","STEREICH"=>"A","OESTEREICH"=>"A","SCHWEIZ"=>"CH");
-$taxarray=array("D"=>0,"A"=>1,"CH"=>2);
-$defaultland="D";
-$taxid=0;
-$log=false;
-$erp=false;
-$shop=false;
-
-
-$ERPdns= array('phptype'  => 'pgsql',
-               'username' => $ERPuser,
-               'password' => $ERPpass,
-               'hostspec' => $ERPhost,
-               'database' => $ERPdbname,
-               'port'     => $ERPport);
-
-$SHOPdns=array('phptype'  => 'mysql',
-               'username' => $SHOPuser,
-               'password' => $SHOPpass,
-               'hostspec' => $SHOPhost,
-               'database' => $SHOPdbname,
-               'port'     => $SHOPport);
-
-/****************************************************
-* Debugmeldungen in File schreiben
-****************************************************/
-if ($debug) { $log=fopen("tmp/shop.log","a"); } // zum Debuggen
-else { $log=false; };
-
-/****************************************************
-* Shopverbindung aufbauen
-****************************************************/
-$shop=DB::connect($SHOPdns);
-if (!$shop) shopFehler("",$shop->getDebugInfo());
-if (DB::isError($shop)) {
-	$nun=date("Y-m-d H:i:s");
-	if ($log) fputs($log,$nun.": Shop-Connect\n");
-	shopFehler("",$shop->getDebugInfo());
-	die ($shop->getDebugInfo());
-};
-
-/****************************************************
-* ERPverbindung aufbauen
-****************************************************/
-$erp=DB::connect($ERPdns);
-if (!$erp) shopFehler("",$erp->getDebugInfo());
-if (DB::isError($erp)) {
-	$nun=date("Y-m-d H:i:s");
-	if ($log) fputs($log,$nun.": ERP-Connect\n");
-	shopFehler("",$erp->getDebugInfo());
-	die ($erp->getDebugInfo());
-} else {
-	if ($erp->autocommit) $erp->autocommit();
-};
-
-/****************************************************
-* SQL-Befehle absetzen
-****************************************************/
-function query($db,$sql,$function="--") {
-    $nun=date("d.m.y H:i:s");
-    if ($GLOBALS["log"]) fputs($GLOBALS["log"],$nun.": ".$function."\n".$sql."\n");
-    $rc=$GLOBALS[$db]->query($sql);
-    if ($GLOBALS["log"]) fputs($GLOBALS["log"],print_r($rc,true)."\n");
-	if ($rc!==1) {
-		return -99;
-	} else {
-		return true;
-	}
-}
-
-/****************************************************
-* Datenbank abfragen
-****************************************************/
-function getAll($db,$sql,$function="--") {
-	$nun=date("d.m.y H:i:s");
-	if ($GLOBALS["log"]) fputs($GLOBALS["log"],$nun.": ".$function."\n".$sql."\n");
-	$rs=$GLOBALS[$db]->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs["message"]<>"") {
-       	if ($GLOBALS["log"]) fputs($GLOBALS["log"],print_r($rs,true)."\n");
-		return false;
-	} else {
-        return $rs;
-	}
-}
-
-/****************************************************
-* shopFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function shopFehler($sql,$err) {
-global $showErr;
-	if ($showErr)
-		echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-
-/****************************************************
-* Nächste Auftragsnummer (ERP) holen
-****************************************************/
-function getNextAnr() {
-	$sql="select * from defaults";
-	$sql1="update defaults set sonumber=";
-	if ($rc === -99) {
-		echo "Kann keine Auftragsnummer erzeugen - Abbruch";
-		$rc=query("erp","ROLLBACK","getNextKnr");
-		exit();
-	}
-	$rs2=getAll("erp",$sql,"getNextAnr");
-	$auftrag=$rs2[0]["sonumber"]+1;
-	$rc=query("erp",$sql1.$auftrag,"getNextAnr");
-	if ($rc === -99) {
-		echo "Kann keine Auftragsnummer erzeugen - Abbruch";
-		$rc=query("erp","ROLLBACK","getNextKnr");
-		exit();
-	}
-	return $auftrag;
-}
-
-/****************************************************
-* Nächste Kundennummer (ERP) holen
-****************************************************/
-function getNextKnr() {
-	$sql="select * from defaults";
-	$sql1="update defaults set customernumber='";
-	if ($rc === -99) {
-		echo "Kann keine Kundennummer erzeugen - Abbruch";
-		exit();
-	}
-	$rs2=getAll("erp",$sql,"getNextKnr");
-	$kdnr=$rs2[0]["customernumber"]+1;
-	$rc=query("erp",$sql1.$kdnr."'","getNextKnr");
-	if ($rc === -99) {
-		echo "Kann keine Kundennummer erzeugen - Abbruch";
-		$rc=query("erp","ROLLBACK","getNextKnr");
-		exit();
-	}
-	return $kdnr;
-}
-
-
-//$shopdata=array("firma"=>"","abteilung"=>"","vorname"=>"","nachname"=>"","strasse"=>"","plz"=>"","ort"=>"","telefon"=>"","email"=>"","land"=>"","fax"=>"","notiz"=>"","postfach"=>"")
-$shopdata=array(	"id"=>"customers_id","kdnr"=>"customers_cid","bid"=>"orders_id", "anrede"=>" customers_gender",
-			"firma"=>"customers_company", "nachname"=>"customers_lastname", "vorname"=>"customers_firstname",
-			"strasse"=>"customers_street_address","plz"=>"customers_postcode","ort"=>"customers_city","land"=>"customers_country",
-			"telefon"=>"customers_phone","email"=>"customers_email_address","fax"=>"Fax","notiz"=>"comments",
-
-			"netto"=>"ot_subtotal","steuer"=>"ot_tax","datum"=>" date_purchased","bemerkung"=>"comments",
-			"artnr"=>"products_id","preis"=>"final_price","artikeltxt"=>" products_name","menge"=>" products_quantity");
-
-$shopartikel=array(	"id"=>"Artikel_ID","artnr"=>"Artikel_Nr","arttxt"=>"Name","artbeschr"=>"Beschreibung","gruppe"=>"Kategorie_ID",
-			"preis"=>"Preis","preis2"=>"Haendlerpreis","preis3"=>"Aktionspreis","gewicht"=>"Gewicht",
-			"bild"=>"Bild_gross","bestand"=>"Lagerbestand","minbestand"=>"Mindestlagermenge","steuer"=>"MwSt_Satz");
-
-
-/****************************************************
-* Ab hier Artikelexport aus ERP
-****************************************************/
-// Ab hier Artikelexport aus ERP nur eine Sprache
-function shopartikellang($lang,$alle) {
-	$sql="SELECT P.partnumber,L.translation,P.description,L.longdescription,P.notes,PG.partsgroup ";
-	$sql.="FROM parts P left join translation L on L.parts_id=P.id left join partsgroup PG on PG.id=P.partsgroup_id ";
-	$sql.="WHERE P.shop='t' and (L.language_id = $lang";
-	if ($alle) {
-		$sql.=" or L.language_id is Null)";
-	} else { $sql.=")"; };
-	$rs=getAll("erp",$sql,"shopartikellang");
-	$data=array();
-	if ($rs) foreach ($rs as $row) {
-		if (!$data[$row["partnumber"]])	$data[$row["partnumber"]]=$row;
-	}
-	return $data;
-}
-// Ab hier alle Artikelexport aus ERP Defaultsprache
-function shopartikel() {
-global $stdprice,$altprice;
-	if ($stdprice>0) {
-		$sql="SELECT P.partnumber,P.description,P.weight,(t.rate * 100) as rate,G.price as sellprice,P.sellprice as stdprice, ";
-		$sql.="PG.partsgroup,P.notes,P.image,P.onhand,G.pricegroup_id,P.buchungsgruppen_id as bugru FROM ";
-		$sql.="chart c left join tax t on c.taxkey_id=t.taxkey, parts P left join partsgroup PG on ";
-		$sql.="PG.id=P.partsgroup_id left join prices G on G.parts_id=P.id ";
-		$sql.="buchungsgruppen B  on P.buchungsgruppen_id = B.id ";
-		$sql.="where P.shop='t' and c.id=p.income_accno_id  and ";
-		$sql.="(G.pricegroup_id=$stdprice or pricegroup_id=$altprice or G.pricegroup_id is null) ";
-		$sql.="order by P.partnumber";
-	} else {
-		$sql="SELECT P.partnumber,P.description,P.weight,(t.rate * 100) as rate,P.sellprice,PG.partsgroup,";
-		$sql.="P.notes,P.image,P.onhand,P.buchungsgruppen_id as bugru FROM ";
-		$sql.="chart c left join tax t on c.taxkey_id=t.taxkey, parts P left join partsgroup PG on ";
-		$sql.="PG.id=P.partsgroup_id left join buchungsgruppen B  on P.buchungsgruppen_id = B.id ";
-		$sql.="WHERE P.shop='t'  and c.id=B.income_accno_id_0";
-	}
-	$rs=getAll("erp",$sql,"shopartikel");
-	$i=0;
-	$data=array();
-	if ($rs) foreach ($rs as $row) {
-		if (!$data[$row["partnumber"]])	$data[$row["partnumber"]]=$row;
-		if ($row["pricegroup_id"]==$altprice) {
-			$data[$row["partnumber"]]["altprice"]=($row["sellprice"])?$row["sellprice"]:$row["stdprice"];
-		} else {
-			$data[$row["partnumber"]]["sellprice"]=($row["sellprice"])?$row["sellprice"]:$row["stdprice"];
-		}
-		$i++;
-	}
-	return $data;
-}
-
-/****************************************************
-* Artikelexport in ERP importieren
-****************************************************/
-function insertArtikel($data) {
-global $shopartikel;
-	foreach ($data as $row) {
-		$pg=$GLOBALS["warengruppen"][$row[$shopartikel["gruppe"]]]["partsgroup"];
-		$bg=$GLOBALS["buchungsgruppen"][sprintf("%0.2f",$row[$shopartikel["steuer"]])];
-		$artnr=($row[$shopartikel["artnr"]])?$row[$shopartikel["artnr"]]:getArtnr();
-		$sqltmp="insert into parts (partnumber,description,notes,weight,onhand,rop,image,sellprice,unit,partsgroup_id,buchungsgruppen_id) ";
-		$sqltmp.="values ('%s','%s','%s',%0.5f,%0.5f,%0.5f,'%s',%0.5f,'%s',%d,%d)";
-		$sql=sprintf($sqltmp,$artnr,$row[$shopartikel["arttxt"]],$row[$shopartikel["artbeschr"]],
-				$row[$shopartikel["gewicht"]],$row[$shopartikel["bestand"]],$row[$shopartikel["minbestand"]],
-				$row[$shopartikel["bild"]],$row[$shopartikel["preis"]],$row[$shopartikel["einheit"]],$pg,$bg);
-		$rc=query("erp",$sql,"insertArtikel");
-		if ($rc === -99) {
-			echo $row[$shopartikel["id"]]." ".$row[$shopartikel["arttxt"]]." nicht importiert<br>";
-		} else {
-			echo "";
-		}
-		echo $sql."<br>";
-	}
-}
-
-/****************************************************
-* Nächste Artikelnummer (ERP) holen
-****************************************************/
-function getArtnr() {
-	$sql="select * from defaults";
-	$sql1="update defaults set articlenumber='";
-	$rc=query("erp","BEGIN","getArtnr");
-	if ($rc === -99) {
-		echo "Kann keine Artikelnummer erzeugen - Abbruch";
-		exit();
-	}
-	$rs2=getAll("erp",$sql,"getArtnr");
-	$artnr=$rs2[0]["articelnumber"]+1;
-	$rc=query("erp",$sql1.$artnr."'","getArtnr");
-	if ($rc === -99) {
-		echo "Kann keine Artikelnummer erzeugen - Abbruch";
-		$rc=query("erp","ROLLBACK","getArtnr");
-		exit();
-	}
-	$rc=query("erp","COMMIT","getArtnr");
-	return $artnr;
-}
-
-$buchungsgruppen=array();
-$warengruppen=array();
-
-function getBugru() {
-	$sql ="select B.id,tax.rate from buchungsgruppen B left join chart on income_accno_id_0=chart.id left join taxkeys T on ";
-	$sql.="T.chart_id=income_accno_id_0 left join tax on tax.id=T.tax_id where T.startdate<=now()";
-	$rs=getAll("erp",$sql,"getBugru");
-	if ($rs) foreach ($rs as $row) {
-		$steuer=sprintf("%0.2f",$row["rate"]*100);
-		$GLOBALS["buchungsgruppen"][$steuer]=$row["id"];
-	}
-}
-
-$wg=1000;
-
-function insPartgroup($kat) {
-	$sql="insert into partsgroup () value ()";
-	$GLOBALS["wg"]++;
-	//$rc=query("erp",$sql,"insPartgroup");
-	if ($rc === -99) { return false; }
-	else { return $GLOBALS["wg"]; }
-}
-getBugru();
-?>
diff --git a/olcom/tmp/.dummy b/olcom/tmp/.dummy
deleted file mode 100644
index e69de29bb..000000000
diff --git a/olcom/trans.php b/olcom/trans.php
deleted file mode 100644
index 4015a4888..000000000
--- a/olcom/trans.php
+++ /dev/null
@@ -1,114 +0,0 @@
-<?
-/***************************************************************
-* $Id: trans.php,v 1.1 2004/06/29 08:50:30 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.0
-*Shop: xt:Commerce 2.2
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-require_once "DB.php";
-require_once "conf.php";
-$LAND=array("Germany"=>"D");
-$db=DB::connect($SHOPdns);
-if (DB::isError($db)||!$db) { $shop="<font color='red'>Fehler</font>"; } else { $shop="ok"; };
-$db2=DB::connect($ERPdns);
-if (DB::isError($db2)||!$db2) { $erp="<font color='red'>Fehler</font>"; } else { $erp="ok"; };
-
-?>
-<html>
-	<head>
-		<title>Datenaustausch ERP-olCommerce</title>
-	</head>
-<body>
-<center>
-<table>
-	<tr>
-		<td colspan="2">
-			Eine direkte Verbindung beider Datenbanken ist erforderlich!<br>
-			Folgende Verbindungsdaten wurden gefunden:
-		</td>
-	</tr>
-	<tr>
-		<td>
-			<b>Lx-ERP</b>
-		</td>
-		<td><?= $erp ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank-Server</td>
-		<td><?= $ERPhost ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank</td>
-		<td><?= $ERPdbname ?></td>
-	</tr>
-	<tr>
-		<td>
-			<b>xt:Commerce</b>
-		</td>
-		<td><?= $shop ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank-Server</td>
-		<td><?= $SHOPhost ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank</td>
-		<td><?= $SHOPdbname ?></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td align="center"><a href="shopimport_db.php"><img src="e2s.gif" border="0"></a></td>
-		<td align="center"><a href="olcomexport.php"><img src="s2e.gif" border="0"></a></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			F&uuml;r den Export der Artikeldaten aus der ERP in eine CSV-Datei<br>
-			oder den Import der Artikeldaten in den Shop ist nur die Verbindung<br>
-			zur entsprechenden	Datenbank notwendig.<br>
-			Die CSV-Dateien werden in den konfigurierten Verzeichnissen erwartet.<br>
-			Der Webserver ben&ouml;tigt hier Schreibrechte.
-		</td>
-	</tr>
-	<tr>
-		<td>
-			<b>Lx-ERP</b>
-		</td>
-		<td><a href="<?= $ERPdir ?>"><?= $ERPdir ?></a></td>
-	</tr>
-	<tr>
-		<td>
-			<b>xt:Commerce</b>
-		</td>
-		<td><a href="<?= $SHOPdir ?>"><?= $SHOPdir ?></a></td>
-	</tr>
-	<tr>
-		<td align="center"><a href="erpexport.php"><img src="e2c.gif" border="0"></a></td>
-		<td align="center"><a href="shopimport_csv.php"><img src="c2s.gif" border="0"></a></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			Copyright (c) 2004 Lx-System - Version: 1.0 - <a href="mailto:info@lx-system.de">info@lx-system.de</a>
-		</td>
-	</tr>
-</table>
-</center>
-</body>
-</html>
diff --git a/oscom/artistic_license b/oscom/artistic_license
deleted file mode 100644
index d0ac87759..000000000
--- a/oscom/artistic_license
+++ /dev/null
@@ -1,51 +0,0 @@
-The Artistic License
-
-Preamble
-
-The intent of this document is to state the conditions under which a Package may be copied, such that the Copyright Holder maintains some semblance of artistic control over the development of the package, while giving the users of the package the right to use and distribute the Package in a more-or-less customary fashion, plus the right to make reasonable modifications.
-
-Definitions:
-
-    * "Package" refers to the collection of files distributed by the Copyright Holder, and derivatives of that collection of files created through textual modification.
-    * "Standard Version" refers to such a Package if it has not been modified, or has been modified in accordance with the wishes of the Copyright Holder.
-    * "Copyright Holder" is whoever is named in the copyright or copyrights for the package.
-    * "You" is you, if you're thinking about copying or distributing this Package.
-    * "Reasonable copying fee" is whatever you can justify on the basis of media cost, duplication charges, time of people involved, and so on. (You will not be required to justify it to the Copyright Holder, but only to the computing community at large as a market that must bear the fee.)
-    * "Freely Available" means that no fee is charged for the item itself, though there may be fees involved in handling the item. It also means that recipients of the item may redistribute it under the same conditions they received it.
-
-1. You may make and give away verbatim copies of the source form of the Standard Version of this Package without restriction, provided that you duplicate all of the original copyright notices and associated disclaimers.
-
-2. You may apply bug fixes, portability fixes and other modifications derived from the Public Domain or from the Copyright Holder. A Package modified in such a way shall still be considered the Standard Version.
-
-3. You may otherwise modify your copy of this Package in any way, provided that you insert a prominent notice in each changed file stating how and when you changed that file, and provided that you do at least ONE of the following:
-
-    a) place your modifications in the Public Domain or otherwise make them Freely Available, such as by posting said modifications to Usenet or an equivalent medium, or placing the modifications on a major archive site such as ftp.uu.net, or by allowing the Copyright Holder to include your modifications in the Standard Version of the Package.
-
-    b) use the modified Package only within your corporation or organization.
-
-    c) rename any non-standard executables so the names do not conflict with standard executables, which must also be provided, and provide a separate manual page for each non-standard executable that clearly documents how it differs from the Standard Version.
-
-    d) make other distribution arrangements with the Copyright Holder.
-
-4. You may distribute the programs of this Package in object code or executable form, provided that you do at least ONE of the following:
-
-    a) distribute a Standard Version of the executables and library files, together with instructions (in the manual page or equivalent) on where to get the Standard Version.
-
-    b) accompany the distribution with the machine-readable source of the Package with your modifications.
-
-    c) accompany any non-standard executables with their corresponding Standard Version executables, giving the non-standard executables non-standard names, and clearly documenting the differences in manual pages (or equivalent), together with instructions on where to get the Standard Version.
-
-    d) make other distribution arrangements with the Copyright Holder.
-
-5. You may charge a reasonable copying fee for any distribution of this Package. You may charge any fee you choose for support of this Package. You may not charge a fee for this Package itself. However, you may distribute this Package in aggregate with other (possibly commercial) programs as part of a larger (possibly commercial) software distribution provided that you do not advertise this Package as a product of your own.
-
-6. The scripts and library files supplied as input to or produced as output from the programs of this Package do not automatically fall under the copyright of this Package, but belong to whomever generated them, and may be sold commercially, and may be aggregated with this Package.
-
-7. C or perl subroutines supplied by you and linked into this Package shall not be considered part of this Package.
-
-8. The name of the Copyright Holder may not be used to endorse or promote products derived from this software without specific prior written permission.
-
-9. THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-
-The End
-
diff --git a/oscom/c2s.gif b/oscom/c2s.gif
deleted file mode 100644
index 1f900541d..000000000
Binary files a/oscom/c2s.gif and /dev/null differ
diff --git a/oscom/conf.php b/oscom/conf.php
deleted file mode 100644
index 07027e4be..000000000
--- a/oscom/conf.php
+++ /dev/null
@@ -1,67 +0,0 @@
-<?
-// Verbindung zur ERP-db
-$ERPuser="lxoffice#";
-$ERPpass="geheim";
-$ERPhost="localhost";
-$ERPdbname="";
-$ERPdns="pgsql://$ERPuser:$ERPpass@$ERPhost/$ERPdbname";
-$ERPusr["Name"]="";
-$ERPusr["ID"]="";
-$ERPdir="tmp/shopartikel.csv";
-$ERPimgdir="/usr/lib/lx-office-erp";
-$maxSize="";
-$ERPftphost="localhost";
-$ERPftpuser="oscom";
-$ERPftppwd="oscom";
-//Verbindung zur osCommerce-db
-$SHOPuser="";
-$SHOPpass="";
-$SHOPhost="localhost";
-$SHOPdbname="";
-$SHOPlang="";
-$SHOPdns="mysql://$SHOPuser:$SHOPpass@$SHOPhost/$SHOPdbname";
-$SHOPdir="tmp/shopartikel.csv";
-$SHOPimgdir="/var/www/oscommerce/images";
-$SHOPftphost="localhost";
-$SHOPftpuser="oscom";
-$SHOPftppwd="oscom";
-$div16["ID"]="";
-$div07["ID"]="";
-$versand["ID"]="";
-$nachn["ID"]="";
-$minder["ID"]="";
-$treuh["ID"]="";
-$paypal["ID"]="";
-$div16["NR"]="";
-$div07["NR"]="";
-$versand["NR"]="";
-$nachn["NR"]="";
-$minder["NR"]="";
-$treuh["NR"]="";
-$paypal["NR"]="";
-$div16["TAX"]="";
-$div07["TAX"]="";
-$versand["TAX"]="";
-$nachn["TAX"]="";
-$minder["TAX"]="";
-$treuh["TAX"]="";
-$paypal["TAX"]="";
-$div16["TXT"]="";
-$div07["TXT"]="";
-$versand["TXT"]="";
-$nachn["TXT"]="";
-$minder["TXT"]="";
-$treuh["TXT"]="";
-$paypal["TXT"]="";
-$pricegroup="0";
-$bgcol[1]="#ddddff";
-$bgcol[2]="#ddffdd";
-$preA="";
-$preK="";
-$auftrnr="1";
-$debug=false;
-$kdnum="1";
-$stdprice="";
-$nopic="";
-$showErr="true";
-?>
diff --git a/oscom/confedit.php b/oscom/confedit.php
deleted file mode 100644
index 54b0961bf..000000000
--- a/oscom/confedit.php
+++ /dev/null
@@ -1,389 +0,0 @@
-<?
-// $Id: confedit.php,v 1.6 2007/01/07
-if (!isset($_SERVER['PHP_AUTH_USER'])) {
-	Header("WWW-Authenticate: Basic realm=\"Configurations-Editor\"");
-	Header("HTTP/1.0 401 Unauthorized");
-	echo "Sie m&uuml;ssen sich autentifizieren\n";
-	exit;
-} else {
-	$login=($_GET["login"])?$_GET["login"]:$_POST["login"];
-	if (file_exists ("conf$login.php")) {
-		require "conf$login.php";
-	} else {
-		require "conf.php";
-	}
-	if ($_SERVER['PHP_AUTH_USER']<>$ERPftpuser || $_SERVER['PHP_AUTH_PW']<>$ERPftppwd) {
-		Header("WWW-Authenticate: Basic realm=\"My Realm\"");
-		Header("HTTP/1.0 401 Unauthorized");
-		echo "Sie m&uuml;ssen sich autentifizieren\n";
-		exit;
-	}
-	require_once "DB.php";
-	$db=@DB::connect($ERPdns);
-	if (!DB::isError($db)) {
-		$sql="select id,pricegroup from pricegroup";
-		$pgs=$db->getall($sql);
-	}
-	function pg($sel) {
-	global $pgs;
-		echo "\t<option value=0";
-		if ($sel==0) echo " selected";
-		echo ">Standard VK\n";
-		if ($pgs) foreach ($pgs as $row) {
-			echo "\t<option value=".$row[0];
-			if ($sel==$row[0]) echo " selected";
-			echo ">".$row[1]."\n";
-		}
-	}
-	if ($_POST["ok"]=="sichern") {
-		$ok=true;
-		if ($_POST["ERPpass"]) {
-			$dsnP="pgsql://".$_POST["ERPuser"].":".$_POST["ERPpass"]."@".$_POST["ERPhost"]."/".$_POST["ERPdbname"];
-		} else {
-			$dsnP="pgsql://".$_POST["ERPuser"]."@".$_POST["ERPhost"]."/".$_POST["ERPdbname"];
-		}
-		$dbP=@DB::connect($dsnP);
-		if (DB::isError($dbP)||!$dbP) {
-			$ok=false;
-			echo "Keine Verbindung zur ERP<br>";
-			echo $dbP->userinfo."<br>";
-		} else {
-			//Steuertabelle ERP
-			$sql ="select  BG.id as bugru,T.rate,TK.startdate from buchungsgruppen BG left join chart C ";
-			$sql.="on BG.income_accno_id_0=C.id left join taxkeys TK on TK.chart_id=C.id left join tax T ";
-			$sql.="on T.id=TK.tax_id where TK.startdate <= now()";
-			$rs=$dbP->getAll($sql,DB_FETCHMODE_ASSOC);
-			$erptax=array();
-			foreach ($rs as $row) {
-        		if ($erptax[$row["bugru"]]["startdate"]<$row["startdate"]) {
-                		$erptax[$row["bugru"]]["startdate"]=$row["startdate"];
-                		$erptax[$row["bugru"]]["rate"]=sprintf("%1.4f",$row["rate"]*100);
-        		}
-			}
-			$sql ="select  P.id,P.description,P.buchungsgruppen_id as bugru from ";
-			$sql.="parts P where P.partnumber = '%s'";
-			$rs=$dbP->getall(sprintf($sql,$_POST["div16NR"]));
-			$_POST["div16ID"]=$rs[0][0];
-			$div16txt=$rs[0][1];
-			$_POST["div16TAX"]=$erptax[$rs[0][2]]["rate"];
-			$rs=$dbP->getall(sprintf($sql,$_POST["div07NR"]));
-			$_POST["div07ID"]=$rs[0][0];
-			$_POST["div07TAX"]=$erptax[$rs[0][2]]["rate"];
-			$div07txt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["versandNR"]));
-			$_POST["versandID"]=$rs[0][0];
-			$_POST["versandTAX"]=$erptax[$rs[0][2]]["rate"];
-			$versandtxt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["nachnNR"]));
-			$_POST["nachnID"]=$rs[0][0];
-			$_POST["nachnTAX"]=$erptax[$rs[0][2]]["rate"];
-			$nachntxt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["minderNR"]));
-			$_POST["minderID"]=$rs[0][0];
-			$_POST["minderTAX"]=$erptax[$rs[0][2]]["rate"];
-			$mindertxt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["paypalNR"]));
-			$_POST["paypalID"]=$rs[0][0];
-			$_POST["paypalTAX"]=$erptax[$rs[0][2]]["rate"];
-			$paypaltxt=$rs[0][1];
-			$rs=$dbP->getall(sprintf($sql,$_POST["treuhNR"]));
-			$_POST["treuhID"]=$rs[0][0];
-			$_POST["treuhTAX"]=$erptax[$rs[0][2]]["rate"];
-			$treuhtxt=$rs[0][1];
-			$rs=$dbP->getall("select id from employee where login = '".$_POST["ERPusrN"]."'");
-			$_POST["ERPusrID"]=$rs[0][0];
-		}
-		if ($_POST["SHOPpass"]) {
-			$dsnM="mysql://".$_POST["SHOPuser"].":".$_POST["SHOPpass"]."@".$_POST["SHOPhost"]."/".$_POST["SHOPdbname"];
-		} else {
-			$dsnM="mysql://".$_POST["SHOPuser"]."@".$_POST["SHOPhost"]."/".$_POST["SHOPdbname"];
-		}
-		$dbM=@DB::connect($dsnM);
-		if (DB::isError($dbM)||!$dbM) {
-			$ok=false;
-			echo "Keine Verbindung zum Shop<br>";
-			echo $dbM->userinfo."<br>";
-		};
-		if ($ok) {
-			$f=fopen("conf$login.php","w");
-			$v="1.6";
-			$d=date("Y/m/d H:i:s");
-			fputs($f,"<?\n// Verbindung zur ERP-db\n");
-			fputs($f,"\$ERPuser=\"".$_POST["ERPuser"]."\";\n");
-			fputs($f,"\$ERPpass=\"".$_POST["ERPpass"]."\";\n");
-			fputs($f,"\$ERPhost=\"".$_POST["ERPhost"]."\";\n");
-			fputs($f,"\$ERPdbname=\"".$_POST["ERPdbname"]."\";\n");
-			fputs($f,"\$ERPdns=\"pgsql://\$ERPuser:\$ERPpass@\$ERPhost/\$ERPdbname\";\n");
-			fputs($f,"\$ERPusr[\"Name\"]=\"".$_POST["ERPusrN"]."\";\n");
-			fputs($f,"\$ERPusr[\"ID\"]=\"".$_POST["ERPusrID"]."\";\n");
-			fputs($f,"\$ERPdir=\"".$_POST["ERPdir"]."\";\n");
-			fputs($f,"\$ERPimgdir=\"".$_POST["ERPimgdir"]."\";\n");
-			fputs($f,"\$maxSize=\"".$_POST["maxSize"]."\";\n");
-			fputs($f,"\$ERPftphost=\"".$_POST["ERPftphost"]."\";\n");
-			fputs($f,"\$ERPftpuser=\"".$_POST["ERPftpuser"]."\";\n");
-			fputs($f,"\$ERPftppwd=\"".$_POST["ERPftppwd"]."\";\n");
-			fputs($f,"//Verbindung zur osCommerce-db\n");
-			fputs($f,"\$SHOPuser=\"".$_POST["SHOPuser"]."\";\n");
-			fputs($f,"\$SHOPpass=\"".$_POST["SHOPpass"]."\";\n");
-			fputs($f,"\$SHOPhost=\"".$_POST["SHOPhost"]."\";\n");
-			fputs($f,"\$SHOPdbname=\"".$_POST["SHOPdbname"]."\";\n");
-			fputs($f,"\$SHOPlang=\"".$_POST["SHOPlang"]."\";\n");
-			fputs($f,"\$SHOPdns=\"mysql://\$SHOPuser:\$SHOPpass@\$SHOPhost/\$SHOPdbname\";\n");
-			fputs($f,"\$SHOPdir=\"".$_POST["SHOPdir"]."\";\n");
-			fputs($f,"\$SHOPimgdir=\"".$_POST["SHOPimgdir"]."\";\n");
-			fputs($f,"\$SHOPftphost=\"".$_POST["SHOPftphost"]."\";\n");
-			fputs($f,"\$SHOPftpuser=\"".$_POST["SHOPftpuser"]."\";\n");
-			fputs($f,"\$SHOPftppwd=\"".$_POST["SHOPftppwd"]."\";\n");
-			fputs($f,"\$div16[\"ID\"]=\"".$_POST["div16ID"]."\";\n");
-			fputs($f,"\$div07[\"ID\"]=\"".$_POST["div07ID"]."\";\n");
-			fputs($f,"\$versand[\"ID\"]=\"".$_POST["versandID"]."\";\n");
-			fputs($f,"\$nachn[\"ID\"]=\"".$_POST["nachnID"]."\";\n");
-			fputs($f,"\$minder[\"ID\"]=\"".$_POST["minderID"]."\";\n");
-			fputs($f,"\$treuh[\"ID\"]=\"".$_POST["treuhID"]."\";\n");
-			fputs($f,"\$paypal[\"ID\"]=\"".$_POST["paypalID"]."\";\n");
-			fputs($f,"\$div16[\"NR\"]=\"".$_POST["div16NR"]."\";\n");
-			fputs($f,"\$div07[\"NR\"]=\"".$_POST["div07NR"]."\";\n");
-			fputs($f,"\$versand[\"NR\"]=\"".$_POST["versandNR"]."\";\n");
-			fputs($f,"\$nachn[\"NR\"]=\"".$_POST["nachnNR"]."\";\n");
-			fputs($f,"\$minder[\"NR\"]=\"".$_POST["minderNR"]."\";\n");
-			fputs($f,"\$treuh[\"NR\"]=\"".$_POST["treuhNR"]."\";\n");
-			fputs($f,"\$paypal[\"NR\"]=\"".$_POST["paypalNR"]."\";\n");
-			fputs($f,"\$div16[\"TAX\"]=\"".$_POST["div16TAX"]."\";\n");
-			fputs($f,"\$div07[\"TAX\"]=\"".$_POST["div07TAX"]."\";\n");
-			fputs($f,"\$versand[\"TAX\"]=\"".$_POST["versandTAX"]."\";\n");
-			fputs($f,"\$nachn[\"TAX\"]=\"".$_POST["nachnTAX"]."\";\n");
-			fputs($f,"\$minder[\"TAX\"]=\"".$_POST["minderTAX"]."\";\n");
-			fputs($f,"\$treuh[\"TAX\"]=\"".$_POST["treuhTAX"]."\";\n");
-			fputs($f,"\$paypal[\"TAX\"]=\"".$_POST["paypalTAX"]."\";\n");
-			fputs($f,"\$div16[\"TXT\"]=\"".$div16txt."\";\n");
-			fputs($f,"\$div07[\"TXT\"]=\"".$div07txt."\";\n");
-			fputs($f,"\$versand[\"TXT\"]=\"".$versandtxt."\";\n");
-			fputs($f,"\$nachn[\"TXT\"]=\"".$nachntxt."\";\n");
-			fputs($f,"\$minder[\"TXT\"]=\"".$mindertxt."\";\n");
-			fputs($f,"\$treuh[\"TXT\"]=\"".$treuhtxt."\";\n");
-			fputs($f,"\$paypal[\"TXT\"]=\"".$paypaltxt."\";\n");
-			fputs($f,"\$pricegroup=\"".$_POST["pricegroup"]."\";\n");
-			fputs($f,"\$bgcol[1]=\"#ddddff\";\n");
-			fputs($f,"\$bgcol[2]=\"#ddffdd\";\n");
-			fputs($f,"\$preA=\"".$_POST["preA"]."\";\n");
-			fputs($f,"\$preK=\"".$_POST["preK"]."\";\n");
-			fputs($f,"\$auftrnr=\"".$_POST["auftrnr"]."\";\n");
-			fputs($f,"\$debug=".$_POST["debug"].";\n");
-			fputs($f,"\$kdnum=\"".$_POST["kdnum"]."\";\n");
-			fputs($f,"\$stdprice=\"".$_POST["stdprice"]."\";\n");
-			fputs($f,"\$nopic=\"".$_POST["nopic"]."\";\n");
-			fputs($f,"\$showErr=\"true\";\n");
-			fputs($f,"?>");
-			fclose($f);
-			if (file_exists ("conf$login.php")) {
-			        require "conf$login.php";
-			} else {
-			        require "conf.php";
-			}
-			$sql="select count(*) from customers_number";
-			$rc=@$dbM->query($sql);
-			if ($rc->code==-18) {
-				$sql="CREATE TABLE customers_number ( cid int(6) NOT NULL auto_increment,  customers_id int NOT NULL default '0', ";
-				$sql.="kdnr int NOT NULL default '0', shipto int, PRIMARY KEY  (cid)) TYPE=MyISAM";
-				$rc=@$dbM->query($sql);
-				if ($rc->code==-1) {
-					echo "Fehler beim Erzeugen der Tabelle 'customers_number' in der Shop-db";
-				} else {
-					echo "Tabelle 'customers_number' in der Shop-db angelegt.";
-				}
-			} else {
-				$sql="select shipto from customers_number limit 1";
-				$rc=@$dbM->query($sql);
-				if ($rc->code==-19) {
-					$sql="alter table customers_number add column shipto int";
-					$rc=@$dbM->query($sql);
-                                	if ($rc->code==-1) {
-						echo "Fehler beim Anlegen der Spalte 'shipto' in 'customers_number'";
-					} else {
-						echo "'shipto' in 'customers_number' angelegt.";
-					}
-				}
-			}
-		} else {
-			$ERPuser=$_POST["ERPuser"];
-			$ERPpass=$_POST["ERPpass"];
-			$ERPhost=$_POST["ERPhost"];
-			$ERPdbname=$_POST["ERPdbname"];
-			$ERPusrN=$_POST["ERPusrN"];
-			$ERPdir=$_POST["ERPdir"];
-			$ERPimgdir=$_POST["ERPimgdir"];
-			$maxSize=$_POST["maxSize"];
-			$ERPftphost=$_POST["ERPftphost"];
-			$ERPftpuser=$_POST["ERPftpuser"];
-			$ERPftppwd=$_POST["ERPftppwd"];
-			$SHOPuser=$_POST["SHOPuser"];
-			$SHOPpass=$_POST["SHOPpass"];
-			$SHOPhost=$_POST["SHOPhost"];
-			$SHOPdbname=$_POST["SHOPdbname"];
-			$SHOPlang=$_POST["SHOPlang"];
-			$SHOPdir=$_POST["SHOPdir"];
-			$SHOPimgdir=$_POST["SHOPimgdir"];
-			$SHOPftphost=$_POST["SHOPftphost"];
-			$SHOPftpuser=$_POST["SHOPftpuser"];
-			$SHOPftppwd=$_POST["SHOPftppwd"];
-			$div16NR=$_POST["div16NR"];
-			$div07NR=$_POST["div07NR"];
-			$versandNR=$_POST["versandNR"];
-			$nachnNR=$_POST["nachnNR"];
-			$treuhNR=$_POST["treuhNR"];
-			$minderNR=$_POST["minderNR"];
-			$paypalNR=$_POST["paypalNR"];
-			$pricegroup=$_POST["pricegroup"];
-			$preA=$_POST["preA"];
-			$preK=$_POST["preK"];
-			$kdnum=$_POST["kdnum"];
-			$auftrnr=$_POST["auftrnr"];
-			$debug=$_POST["debug"];
-			$stdprice=$_POST["stdprice"];
-			$nopic=$_POST["nopic"];
-		}
-	}	else {
-		if (file_exists ("conf$login.php")) {
-			require "conf$login.php";
-		} else {
-			require "conf.php";
-		}
-	}
-?>
-<html>
-<body>
-<center>
-<table style="background-color:#cccccc">
-<form name="ConfEdit" method="post" action="confedit.php">
-<input type="hidden" name="div16ID" value="<?= $div16["ID"] ?>">
-<input type="hidden" name="div07ID" value="<?= $div07["ID"] ?>">
-<input type="hidden" name="minderID" value="<?= $minder["ID"] ?>">
-<input type="hidden" name="versandID" value="<?= $versand["ID"] ?>">
-<input type="hidden" name="nachnID" value="<?= $nachn["ID"] ?>">
-<input type="hidden" name="paypalID" value="<?= $paypal["ID"] ?>">
-<input type="hidden" name="treuhID" value="<?= $treuh["ID"] ?>">
-<input type="hidden" name="ERPusrID" value="<?= $ERPusr["ID"] ?>">
-<input type="hidden" name="login" value="<?= $login ?>">
-<tr><th>Daten</th><th>Lx-ERP</th><th></th><th>Shop</th></tr>
-<tr>
-	<td>db-Host</td>
-	<td colspan="2"><input type="text" name="ERPhost" size="25" value="<?= $ERPhost ?>"></td>
-	<td><input type="text" name="SHOPhost" size="25" value="<?= $SHOPhost ?>"></td>
-</tr>
-<tr>
-	<td>Database</td>
-	<td colspan="2"><input type="text" name="ERPdbname" size="20" value="<?= $ERPdbname ?>"></td>
-	<td><input type="text" name="SHOPdbname" size="20" value="<?= $SHOPdbname ?>"></td>
-</tr>
-<tr>
-	<td>db-User Name</td>
-	<td colspan="2"><input type="text" name="ERPuser" size="15" value="<?= $ERPuser ?>"></td>
-	<td><input type="text" name="SHOPuser" size="15" value="<?= $SHOPuser ?>"></td>
-</tr>
-<tr>
-	<td>db-User PWD</td>
-	<td colspan="2"><input type="text" name="ERPpass" size="15" value="<?= $ERPpass ?>"></td>
-	<td><input type="text" name="SHOPpass" size="15" value="<?= $SHOPpass ?>"></td>
-</tr>
-<tr>
-	<td>User-ID</td>
-	<td colspan="2"><input type="text" name="ERPusrN" size="10" value="<?= $ERPusr["Name"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($ERPusr["ID"])?"":"checked") ?> onFocus="blur();"></td>
-	<td></td>
-</tr>
-<tr>
-	<td>CSV-Dir</td>
-	<td colspan="2"><input type="text" name="ERPdir" size="30" value="<?= $ERPdir ?>"></td>
-	<td><input type="text" name="SHOPdir" size="30" value="<?= $SHOPdir ?>"></td>
-</tr>
-<tr>
-	<td>Image-Dir</td>
-	<td colspan="2"><input type="text" name="ERPimgdir" size="30" value="<?= $ERPimgdir ?>"></td>
-	<td><input type="text" name="SHOPimgdir" size="30" value="<?= $SHOPimgdir ?>"></td>
-</tr>
-<tr>
-	<td>FTP-Host</td>
-	<td colspan="2"><input type="text" name="ERPftphost" size="20" value="<?= $ERPftphost ?>"></td>
-	<td><input type="text" name="SHOPftphost" size="20" value="<?= $SHOPftphost ?>"></td>
-</tr>
-<tr>
-	<td>FTP-User</td>
-	<td colspan="2"><input type="text" name="ERPftpuser" size="15" value="<?= $ERPftpuser ?>"></td>
-	<td><input type="text" name="SHOPftpuser" size="15" value="<?= $SHOPftpuser ?>"></td>
-</tr>
-<tr>
-	<td>FTP-User PWD</td>
-	<td colspan="2"><input type="text" name="ERPftppwd" size="15" value="<?= $ERPftppwd ?>"></td>
-	<td><input type="text" name="SHOPftppwd" size="15" value="<?= $SHOPftppwd ?>"></td>
-</tr>
-<tr>
-	<td>ID Diverse 19%</td>
-	<td><input type="text" name="div16NR" size="10" value="<?= $div16["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($div16["ID"])?"":"checked") ?>></td>
-	<td>ID Diverse 7%</td>
-	<td><input type="text" name="div07NR" size="10" value="<?= $div07["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($div07["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Versand</td>
-	<td><input type="text" name="versandNR" size="10" value="<?= $versand["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($versand["ID"])?"":"checked") ?>></td>
-	<td>ID Nachname</td>
-	<td><input type="text" name="nachnNR" size="10" value="<?= $nachn["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($nachn["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Paypal</td>
-	<td><input type="text" name="paypalNR" size="10" value="<?= $paypal["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($paypal["ID"])?"":"checked") ?>></td>
-	<td>ID Treuhand</td>
-	<td><input type="text" name="treuhNR" size="10" value="<?= $treuh["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($treuh["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Mindemenge</td>
-	<td><input type="text" name="minderNR" size="10" value="<?= $minder["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($minder["ID"])?"":"checked") ?>></td>
-	<td></td>
-	<td></td>
-</tr>
-<tr>
-	<td colspan="2">Abweichende Shopsprache</td>
-	<td colspan="2"><input type="text" name="SHOPlang" size="5" value="<?= $SHOPlang ?>"> leer = Default</td>
-</tr>
-<tr>
-	<td>Preisgruppe</td>
-	<td><select name="pricegroup">
-<? pg($pricegroup); ?>
-	    </select></td>
-	<td>Defaultbild</td>
-	<td><input type="text" name="nopic" size="20" value="<?= $nopic ?>">
-</tr>
-<tr>
-	<td colspan="2">Auftragsnummern durch</td>
-	<td><input type="radio" name="auftrnr" value="1" <?= ($auftrnr==1)?"checked":"" ?>> LxO</td>
-	<td><input type="radio" name="auftrnr" value="0" <?= ($auftrnr<>1)?"checked":"" ?>> Shop</td>
-</tr>
-<tr>
-	<td colspan="2">Kundennummern durch</td>
-	<td><input type="radio" name="kdnum" value="1" <?= ($kdnum==1)?"checked":"" ?>> LxO</td>
-	<td><input type="radio" name="kdnum" value="0" <?= ($kdnum<>1)?"checked":"" ?>> Shop</td>
-</tr>
-<tr>
-	<td colspan="2">Nummernerweiterung</td>
-	<td>Auftrag<input type="text" name="preA" size="5" value="<?= $preA ?>"></td>
-	<td>Kunde<input type="text" name="preK" size="5" value="<?= $preK ?>"></td>
-</tr>
-<tr>
-	<td>Logging</td>
-	<td>ein<input type="radio" name="debug" value="true" <?= ($debug=="true")?"checked":"" ?>>
-	aus<input type="radio" name="debug" value="false" <?= ($debug!="true")?"checked":"" ?>></td>
-	<td></td><td></td>
-</tr>
-<tr><td colspan="4" align="center"><input type="submit" name="ok" value="sichern"></td></tr>
-</form>
-</table>
-</center>
-</body>
-</html>
-<? } ?>
diff --git a/oscom/confhli.php b/oscom/confhli.php
deleted file mode 100644
index 40f04ca54..000000000
--- a/oscom/confhli.php
+++ /dev/null
@@ -1,67 +0,0 @@
-<?
-// Verbindung zur ERP-db
-$ERPuser="lxoffice";
-$ERPpass="geheim";
-$ERPhost="localhost";
-$ERPdbname="stable";
-$ERPdns="pgsql://$ERPuser:$ERPpass@$ERPhost/$ERPdbname";
-$ERPusr["Name"]="hli";
-$ERPusr["ID"]="376";
-$ERPdir="tmp/shopartikel.csv";
-$ERPimgdir="/var/www/stable/";
-$maxSize="";
-$ERPftphost="localhost";
-$ERPftpuser="oscom";
-$ERPftppwd="oscom";
-//Verbindung zur osCommerce-db
-$SHOPuser="root";
-$SHOPpass="db4web";
-$SHOPhost="localhost";
-$SHOPdbname="oscom";
-$SHOPlang="";
-$SHOPdns="mysql://$SHOPuser:$SHOPpass@$SHOPhost/$SHOPdbname";
-$SHOPdir="tmp/shopartikel.csv";
-$SHOPimgdir="/var/www/oscommerce/images";
-$SHOPftphost="localhost";
-$SHOPftpuser="oscom";
-$SHOPftppwd="oscom";
-$div16["ID"]="413";
-$div07["ID"]="";
-$versand["ID"]="413";
-$nachn["ID"]="";
-$minder["ID"]="";
-$treuh["ID"]="";
-$paypal["ID"]="";
-$div16["NR"]="div16";
-$div07["NR"]="";
-$versand["NR"]="div16";
-$nachn["NR"]="";
-$minder["NR"]="";
-$treuh["NR"]="";
-$paypal["NR"]="";
-$div16["TAX"]="19.0000";
-$div07["TAX"]="";
-$versand["TAX"]="19.0000";
-$nachn["TAX"]="";
-$minder["TAX"]="";
-$treuh["TAX"]="";
-$paypal["TAX"]="";
-$div16["TXT"]="Diverse Artikel 16% MWSt.";
-$div07["TXT"]="";
-$versand["TXT"]="Diverse Artikel 16% MWSt.";
-$nachn["TXT"]="";
-$minder["TXT"]="";
-$treuh["TXT"]="";
-$paypal["TXT"]="";
-$pricegroup="0";
-$bgcol[1]="#ddddff";
-$bgcol[2]="#ddffdd";
-$preA="";
-$preK="";
-$auftrnr="1";
-$debug=true;
-$kdnum="1";
-$stdprice="";
-$nopic="";
-$showErr="true";
-?>
diff --git a/oscom/diff.php b/oscom/diff.php
deleted file mode 100644
index 7dd0e519c..000000000
--- a/oscom/diff.php
+++ /dev/null
@@ -1,70 +0,0 @@
-<?
-// $Id: diff.php,v 1.1 2004/06/30 10:12:15 hli Exp $
-if ($_POST["ok"]) {
-	require_once "shoplib.php";
-	foreach($_POST as $key=>$val) {
-		if ($key=="ok") continue;
-		if ($key=="alle") continue;
-		$sql="update products set products_status=0 where products_model='$key'";
-		//echo "$key $sql";
-		echo "$key ";
-		if (query("shop",$sql,"diff")) { echo "deaktiviert<br>"; }
-		else { echo "konnte nicht deaktiviert werden<br>"; };
-	}
-} else {
-$sql="select partnumber from parts where shop='1' order by partnumber";
-$erp=getAll("erp",$sql,"getPartnumber");
-if ($SHOPlang>0) {
-	$defLang=$SHOPlang;
-} else {
-	$sql="select * from languages L left join configuration C on L.code=C.configuration_value where  configuration_key = 'DEFAULT_LANGUAGE'";
-	$rs=getAll("shop",$sql,"getLanguage");
-	if ($rs) {
-		$defLang=$rs[0]["languages_id"];
-	} else {
-		$defLang=1;
-	}
-}
-if ($erp) foreach ($erp as $zeile) { $arE[]=$zeile["partnumber"]; };
-$sql="select products_model,P.products_id,products_name from products P left join products_description D on P.products_id=D.products_id where language_id=$defLang and products_status=1 order by products_model";
-$shop=getAll("shop",$sql,"products_model");
-if ($shop) foreach ($shop as $zeile) {
-	$arS[]=$zeile["products_model"];
-	$arID[$zeile["products_model"]]=array("id"=>$zeile["products_id"],"name"=>$zeile["products_name"]);
-}
-
-$result=@array_diff($arS,$arE);
-if ($result) {
-?>
-<html>
-<head><title>Artikelpflege</title>
-<script language="JavaScript">
-<!--
-	function sel() {
-		val=document.doppel.alle.checked;
-		cnt=document.doppel.length;
-		for (i=0; i<cnt; i++) {
-			document.doppel.elements[i].checked=val;
-		}
-	}
-//-->
-</script>
-</head>
-<body>
-Folgende Artikel sind in der ERP nicht mehr als Shopartikel markiert.<br>
-Markieren Sie die Artikel, die deaktiviert werden sollen.<br>
-<form name='doppel' method='post' action='diff.php?login=<?= $login ?>'>
-<table>
-<?
-foreach ($result as $data) {
-	echo "\t<tr><td><input type='checkbox' name='".$data."' value='1'></td><td>".$data."</td><td>".$arID[$data]["name"]."</td></tr>\n";
-}
-?>
-	<tr><td><input type='checkbox' name='alle' value='1' onClick="sel()"></td><td></td><td>alle Artikel</td></tr>
-	<tr><td colspan='3'><input type='submit' name='ok' value='ok'></td></tr>
-</table>
-<form>
-<? }
-	else { echo "Artikelbestand identisch"; };
-} ?>
-<!-- a href="trans.php">zur&uuml;ck</a -->
diff --git a/oscom/e2c.gif b/oscom/e2c.gif
deleted file mode 100644
index 692eb8b87..000000000
Binary files a/oscom/e2c.gif and /dev/null differ
diff --git a/oscom/e2s.gif b/oscom/e2s.gif
deleted file mode 100644
index 8e5421b3f..000000000
Binary files a/oscom/e2s.gif and /dev/null differ
diff --git a/oscom/erpexport.php b/oscom/erpexport.php
deleted file mode 100644
index 04fa6c921..000000000
--- a/oscom/erpexport.php
+++ /dev/null
@@ -1,223 +0,0 @@
-<?
-/***************************************************************
-* $Id: erpexport.php,v 1.1 2006/02/06 08:50:30 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.1
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-?>
-<html>
-	<head><title>Lx-ERP Export der Shopartikel</title>
-	<link type="text/css" REL="stylesheet" HREF="css/main.css"></link>
-	<script language="JavaScript">
-	<!--
-		function oscomm() {
-			document.fld.PN.value="products_model"; document.fld.partnumber.checked=true;
-			document.fld.BEZ.value="products_name"; document.fld.desctiption.checked=true;
-			document.fld.GEWICHT.value="products_weight"; document.fld.weight.checked=true;
-			document.fld.MWST.value="products_tax"; document.fld.rate.checked=true;
-			document.fld.VK.value="products_price"; document.fld.sellprice.checked=true;
-			document.fld.PG.value="categories_name"; document.fld.partsgroup.checked=true;
-			document.fld.BESCHR.value="products_description"; document.fld.notes.checked=true;
-			document.fld.LAGER.value="products_quantity"; document.fld.onhand.checked=true;
-			document.fld.encl.value="";
-			document.fld.deli.value=";";
-			document.fld.crln.value="\\n";
-			document.fld.head.checked=true;
-			document.fld.shop.value="oscomm";
-		}
-	//-->
-	</script>
-<body>
-
-<?php
-$login=$_GET["login"];
-require_once "DB.php";
-require_once "conf$login.php";
-$db=DB::connect($ERPdns);
-if (!$db) dbFehler("",$db->getDebugInfo());
-if (DB::isError($db)) {
-	dbFehler("",$db->getDebugInfo());
-	die ($db->getDebugInfo());
-};
-/****************************************************
-* dbFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function dbFehler($sql,$err) {
-global $showErr;
-	if ($showErr)
-		echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-
-function shopartikel_() {
-global $db;
-	$sql ="SELECT P.partnumber,P.description,P.unit,P.weight,t.rate,P.sellprice,P.listprice,P.priceupdate,PG.partsgroup,P.notes,P.image,P.onhand FROM ";
-	$sql.="parts P left join partsgroup PG on  PG.id=P.partsgroup_id ";
-	$sql.="left join chart c on c.id = P.income_accno_id ";
-	$sql.="left join tax T on T.taxkey=C.taxkey_id ";
-	$sql.="where shop = 't'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	return $rs;
-}
-function shopartikel() {
-global $db,$pricegroup;
-	if ($pricegroup>0) {
-		$sql="SELECT P.partnumber,P.description,G.price as sellprice,P.sellprice as stdprice, ";
-		$sql.="PG.partsgroup,P.notes,P.image,P.onhand,G.pricegroup_id,P.buchungsgruppen_id as bugru FROM ";
-		$sql.="parts P left join partsgroup PG on ";
-		$sql.="PG.id=P.partsgroup_id left join prices G on G.parts_id=P.id ";
-		$sql.="where P.shop='t' and ";
-		$sql.="(G.pricegroup_id=$pricegroup or G.pricegroup_id is null) ";
-		$sql.="order by P.partnumber";
-	} else {
-		$sql="SELECT P.partnumber,P.description,P.weight,P.sellprice,PG.partsgroup,";
-		$sql.="P.notes,P.image,P.onhand,P.buchungsgruppen_id as bugru ";
-		$sql.="FROM parts P left join partsgroup PG on PG.id=P.partsgroup_id ";
-		$sql.="left join buchungsgruppen B on P.buchungsgruppen_id = B.id ";
-		$sql.="WHERE P.shop='t'";
-	}
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	return $rs;
-}
-if ($_POST["export"]) {
-	$data=shopartikel();
-	$delim=($_POST["deli"])?$_POST["deli"]:",";
-	if (get_magic_quotes_gpc()) {
-		$crln = stripslashes($_POST["crln"]);
-	}
-	//Steuertabelle ERP
-	$sql ="select  BG.id as bugru,T.rate,TK.startdate from buchungsgruppen BG left join chart C ";
-	$sql.="on BG.income_accno_id_0=C.id left join taxkeys TK on TK.chart_id=C.id left join tax T ";
-	$sql.="on T.id=TK.tax_id where TK.startdate <= now()";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$erptax=array();
-	foreach ($rs as $row) {
-        if ($erptax[$row["bugru"]]["startdate"]<$row["startdate"]) {
-                $erptax[$row["bugru"]]["startdate"]=$row["startdate"];
-                $erptax[$row["bugru"]]["rate"]=$row["rate"]*100;
-        }
-	}
-	$crln = str_replace('\\r', "\015", $crln);
-	$crln = str_replace('\\n', "\012", $crln);
-	$crln = str_replace('\\t', "\011", $crln);
-	$encl=$_POST["encl"];
-	$i=0;
-	$f=fopen($ERPdir,"w");
-	if ($_POST["partnumber"])	{$header.=$_POST["PN"].$delim; };
-	if ($_POST["desctiption"])	{$header.=$_POST["BEZ"].$delim; };
-	if ($_POST["unit"])			{$header.=$_POST["EINHEIT"].$delim; };
-	if ($_POST["weight"])		{$header.=$_POST["GEWICHT"].$delim; };
-	if ($_POST["onhand"])		{$header.=$_POST["LAGER"].$delim; };
-	if ($_POST["rate"])			{$header.=$_POST["MWST"].$delim; };
-	if ($_POST["sellprice"])	{$header.=$_POST["VK"].$delim; };
-	if ($_POST["listprice"])	{$header.=$_POST["EK"].$delim; };
-	if ($_POST["priceupdate"])	{$header.=$_POST["PDATE"].$delim; };
-	if ($_POST["partsgroup"])	{$header.=$_POST["PG"].$delim; };
-	if ($_POST["notes"])		{$header.=$_POST["BESCHR"].$delim; };
-	if ($_POST["image"])		{$header.=$_POST["IMAGE"].$delim; };
-	$header=substr($header,0,-1);
-?>
-<table class="liste">
-<!-- BEGIN Artikel -->
-<?	$i=0;
-	$f=fopen($ERPdir,"w");
-	if ($_POST["head"]) fputs($f,$header.$crln);
-	foreach($data as $zeile) {
-		$file=""; $html="";
-		$PG=$zeile["partsgroup"];
-		$mwst=sprintf("%01.4f",$erptax[$zeile["bugru"]]["rate"]);
-		$LineCol = $bgcol[$i%2+1];
-		if ($_POST["partnumber"])	{$file.=$encl.$zeile["partnumber"].$encl.$delim; $html.="<td>".$zeile["partnumber"]."</td>";};
-		if ($_POST["desctiption"])	{$file.=$encl.strtr($zeile["description"],chr(13).chr(10),"  ").$encl.$delim; $html.="<td>".$zeile["description"]."</td>";};
-		if ($_POST["unit"])			{$file.=$encl.$zeile["unit"].$encl.$delim; $html.="<td>".$zeile["unit"]."</td>";};
-		if ($_POST["weight"])		{$file.=$encl.$zeile["weight"].$encl.$delim; $html.="<td>".$zeile["weight"]."</td>";};
-		if ($_POST["onhand"])		{$file.=$encl.$zeile["onhand"].$encl.$delim; $html.="<td>".$zeile["onhand"]."</td>";};
-		if ($_POST["rate"])			{$file.=$encl.$mwst.$encl.$delim; $html.="<td>".$mwst."</td>";};
-		if ($_POST["sellprice"])	{$file.=$encl.(sprintf("%02.2f",$zeile["sellprice"])).$encl.$delim; $html.="<td>".(sprintf("%02.2f",$zeile["sellprice"]))."</td>";};
-		if ($_POST["listprice"])	{$file.=$encl.(sprintf("%02.2f",$zeile["listprice"])).$encl.$delim; $html.="<td>".(sprintf("%02.2f",$zeile["listprice"]))."</td>";};
-		if ($_POST["priceupdate"])	{$file.=$encl.$zeile["priceupdate"].$encl.$delim; $html.="<td>".$zeile["priceupdate"]."</td>";};
-		if ($_POST["partsgroup"])	{$file.=$encl.$PG.$encl.$delim; $html.="<td>".$zeile["partsgroup"]."</td>";};
-		if ($_POST["notes"])		{$file.=$encl.strtr($zeile["notes"],chr(13).chr(10),"  ").$encl.$delim; $html.="<td>".$zeile["notes"]."</td>";};
-		if ($_POST["image"])		{$file.=$encl.$zeile["image"].$encl.$delim; $html.="<td>".$zeile["image"]."</td>";};
-		$i++;
-		fputs($f,substr($file,0,-1).$crln);
-		if ($_POST["show"]) {
-?>
-	<tr  class="smal" onMouseover="this.bgColor='#FF0000';" onMouseout="this.bgColor='<?= $LineCol ?>';" bgcolor="<?= $LineCol ?>">
-		<?= $html ?>
-	</tr>
-<? 		}
-	}
-?>
-<!-- END Artikel -->
-</table>
-Anzahl der Artikel: <?= $i ?><br>
-Export am : <?= date("d.m.Y : H:i") ?><br>
-download <a href="tmp/shopartikel.csv">Exportfile</a><br><hr>
-<?
-	fclose($f);
-} // if ($export)
-?>
-Export der Shopartikel aus Lx-ERP <br>
-M&ouml;gliche Felder
-<form name="fld" action="erpexport.php" method="post">
-<input type="hidden" name="shop" value="">
-<table>
-	<tr>
-		<td><input type="checkbox" name="partnumber" value="1">Artikelnummer</td>
-		<td><input type="checkbox" name="desctiption" value="1">Bezeichnung</td>
-		<td><input type="checkbox" name="unit" value="1">Einheit</td>
-		<td><input type="checkbox" name="weight" value="1">Gewicht</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="PN" size="23"></td>
-		<td><input type="text" name="BEZ" size="23"></td>
-		<td><input type="text" name="EINHEIT" size="23"></td>
-		<td><input type="text" name="GEWICHT" size="23"></td>
-	</tr>
-	<tr><td colspan=5></td></tr>
-	<tr>
-		<td><input type="checkbox" name="sellprice" value="1">Verkaufspreis</td>
-		<td><input type="checkbox" name="listprice" value="1">Listenpreis</td>
-		<td><input type="checkbox" name="onhand" value="1">Lagerbestand</td>
-		<td><input type="checkbox" name="rate" value="1">MwSt</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="VK" size="23"></td>
-		<td><input type="text" name="EK" size="23"></td>
-		<td><input type="text" name="LAGER" size="23"></td>
-		<td><input type="text" name="MWST" size="23"></td>
-	</tr>
-	<tr><td colspan=5></td></tr>
-	<tr>
-		<td><input type="checkbox" name="partsgroup" value="1">Gruppe</td>
-		<td><input type="checkbox" name="notes" value="1">Beschreibung</td>
-		<td><input type="checkbox" name="image" value="1">Bild</td>
-		<td><input type="checkbox" name="show" value="1" checked>HTML-Anzeige</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="PG" size="23"></td>
-		<td><input type="text" name="BESCHR" size="23"></td>
-		<td><input type="text" name="IMAGE" size="23"></td>
-		<td></td>
-	</tr>
-	<tr>
-		<td>Feldtrenner <input type="text" name="deli" size="2" value=","></td>
-		<td>Feldumrahmung <input type="text" name="encl" size="2" value="&quot;"></td>
-		<td>Zeilenende <input type="text" name="crln" size="2" value="\n"></td>
-		<td><input type="checkbox" name="head" value="1" checked>Headline</td>
-	</tr>
-	<tr>
-		<td colspan=5><input type="submit" name="export" value="Export"> <input type="button" name="osc" value="osCommerce" onClick="oscomm()"></td>
-	</tr>
-</table>
-<a href="trans.php">zur&uuml;ck</a>
-</form>
-</body>
-</html>
diff --git a/oscom/handbuch.odt b/oscom/handbuch.odt
deleted file mode 100644
index ca152ccf5..000000000
Binary files a/oscom/handbuch.odt and /dev/null differ
diff --git a/oscom/handbuch.pdf b/oscom/handbuch.pdf
deleted file mode 100644
index 5a09fafba..000000000
Binary files a/oscom/handbuch.pdf and /dev/null differ
diff --git a/oscom/menu.ini b/oscom/menu.ini
deleted file mode 100644
index 989d98de4..000000000
--- a/oscom/menu.ini
+++ /dev/null
@@ -1,12 +0,0 @@
-
-[osCom]
-
-[osCom--Warenexport]
-module=oscom/shopimport_db.php
-
-[osCom--Bestellungen]
-module=oscom/oscomexport.php
-
-[osCom--Konfiguration]
-module=oscom/confedit.php
-
diff --git a/oscom/osCom.png b/oscom/osCom.png
deleted file mode 100644
index 1ea0a47cc..000000000
Binary files a/oscom/osCom.png and /dev/null differ
diff --git a/oscom/oscom.sql b/oscom/oscom.sql
deleted file mode 100644
index 24b3ac4b9..000000000
--- a/oscom/oscom.sql
+++ /dev/null
@@ -1,9 +0,0 @@
-# $Id: oscom.sql,v 1.2 2004/07/01 20:50:34 hli Exp $
-# Zusatztabelle Kundenbeziehung ERP - osCommerce
-#
-CREATE TABLE customers_number (
-  cid int(6) NOT NULL auto_increment,
-  customers_id int(3) NOT NULL default '0',
-  kdnr int(3) NOT NULL default '0',
-  PRIMARY KEY  (cid)
-) TYPE=MyISAM;
diff --git a/oscom/oscomexport.php b/oscom/oscomexport.php
deleted file mode 100644
index ef15758d4..000000000
--- a/oscom/oscomexport.php
+++ /dev/null
@@ -1,483 +0,0 @@
-<?
-/***************************************************************
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.6
-*Shop: osCommerce 2.2 ms2
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-/*
-* Noch einzubauen:
-*/
-?>
-<html>
-	<head><title>Lx-ERP Export der Shopartikel</title>
-	<!--link type="text/css" REL="stylesheet" HREF="../css/main.css"></link-->
-<body>
-
-<?php
-require_once "shoplib.php";
-
-function sonderkosten($transID,$data,$id,$f) {
-global $versand,$nachn,$minder,$treuh,$paypal;
-	$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-	$sql.=$transID.",".${$id}["ID"].",'".${$id}["TXT"]."',1,".$data.",'Stck',0,0)";
-	fputs($f,"$transID,".${$id}["ID"].",'".${$id}["TXT"]."',1,$data\n");
-	if (!query("erp",$sql,"sonderkosten")) { return false; }
-	else { return true; };
-}
-
-function getBestellKunde($KID,$BID,$OID) {
-global $neuKd,$gesKd;
-	$sql="select kdnr from customers_number where customers_id=$KID";
-	$rs=getAll("shop",$sql,"getBestellKunde");
-	if (!$rs or $rs[0]["kdnr"]<1) {
-		$kdnr=insKdData($BID);
-		if ($kdnr>0) {
-			$sql="insert into customers_number (customers_id,kdnr) values(".$KID.",".$kdnr.")";
-			$rc=query("shop",$sql,"getBestellKunde");
-			if ($rc === -99) {
-				echo "Kundennummer nicht im Shop gespeichert: $KID<br>";
-			}
-		} else {
-			$neuKd++;
-		}
-	} else {
-		$kdnr=$rs[0]["kdnr"];
-	}
-	chkKdData($kdnr,$BID,$OID);
-	$gesKd++;
-	return $kdnr;
-}
-/**********************************************
-* getAttribut($oid,$pid)
-*
-**********************************************/
-function getAttribut($oid,$pid) {
-	$sql="select * from orders_products_attributes where orders_id=$oid and orders_products_id=$pid";
-	$rs=getAll("shop",$sql,"getAttribut");
-	$txt="";
-	foreach ($rs as $zeile) {
-		$txt.="\n - ".$zeile["products_options"].":".$zeile["products_options_values"];
-	};
-	return $txt;
-}
-function getTaxRate() {
-	$sql="select tax_rate from tax_rates R left join configuration C on C.configuration_value=R.tax_class_id ";
-	$sql.="where C.configuration_key like 'MODULE_SHIPPING%TAX%' limit 1";
-	$rs=getAll("shop",$sql,"getTaxRate");
-	if ($rs[0]["tax_rate"]) {
-		return (100+$rs[0]["tax_rate"])/100 ;
-	} else {
-		echo "Bitte mind. eine Versandart mit Steuer anlegen.";
-		return 1;
-	}
-}
-function checkTaxIncl() {
-	$sql="select * from configuration where  configuration_key = 'DISPLAY_PRICE_WITH_TAX'";
-	$rs=getAll("shop",$sql,"checkTaxIncl");
-	if ($rs[0]["configuration_value"]=="false") { return false; }
-	else { return true; }
-}
-function getNetto($id) {
-	$sql="select * from orders_total where orders_id=$id and class='ot_subtotal'";
-	$rs=getAll("shop",$sql,"getNetto");
-	return $rs[0]["value"];
-}
-/**********************************************
-* getBrutto($id)
-*
-**********************************************/
-function getBrutto($id) {
-	$sql="select * from orders_total where orders_id=$id and class='ot_total'";
-	$rs=getAll("shop",$sql,"getBrutto");
-	return $rs[0]["value"];
-}
-
-/**********************************************
-* getMwst($id)
-*
-**********************************************/
-function getMwSt($id) {
-global $TaxFactor;
-	$mwst=0;
-	$sql="select * from orders_total where orders_id=$id and class='ot_tax'";
-	$rs=getAll("shop",$sql,"getMwSt");
-	if ($rs) {
-		foreach ($rs as $zeile) {
-			$mwst+=$zeile["value"];
-		}
-	}
-	return $mwst;
-	//return $rs[0]["value"]/$TaxFactor;
-}
-/**********************************************
-* getSonderkosten($id,$art)
-*
-**********************************************/
-function getSonderkosten($id,$art) {
-        $sql="select * from orders_total where orders_id=$id and class='".$GLOBALS["skosten"][$art]."'";
-        $rs=getAll("shop",$sql,"getSonderkosten");
-        if ($rs[0]["value"]) {
-                $kosten=round($rs[0]["value"]/(100+$GLOBALS["versand"]["TAX"])*100,2);
-        } else {
-                $kosten=false;
-        }
-        return $kosten;
-}
-/**********************************************
-* insBestArtikel($zeile,$transID)
-*
-**********************************************/
-function insBestArtikel($ordersID,$transID) {
-global $div07,$div16;
-        $sql="select * from orders_products where orders_id=$ordersID";
-        $rs=getAll("shop",$sql,"insBestArtikel");
-        $ok=true;
-        if ($rs) foreach ($rs as $zeile) {
-        	$sql="select * from parts where partnumber='".$zeile["products_model"]."'";
-                $rs2=getAll("erp",$sql,"insBestArtikel");
-                if ( $rs2[0]["id"]) {
-                		$artID=$rs2[0]["id"];
-                		$artNr=$rs2[0]["partnumber"];
-                } else {
-                        if ($zeile["products_tax"]=="19.0000") {
-                                $artID=$div16["ID"];
-                                $artNr=$div16["NR"];
-                        } else {
-                                $artID=$div07["ID"];
-                                $artNr=$div07["NR"];
-                        };
-                }
-		$preis=$zeile["final_price"];
-                $text=getAttribut($ordersID,$zeile["orders_products_id"]);
-                $sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) ";
-		$sql.="values (";
-                $sql.=$transID.",".$artID.",'".$zeile["products_name"].$text."',".$zeile["products_quantity"].",";
-		$sql.=$preis.",'Stck',0,0)";
-                echo " - Artikel:[ BuNr.:$artID ArtNr:<b>$artNr</b> ".$zeile["products_name"]." ]<br>";
-                $rc=query("erp",$sql,"insBestArtikel");
-                if ($rc === -99) { $ok=false; break; };
-        }
-        return $ok;
-}
-function insAuftrag($data) {
-global $ERPusr,$versand,$nachn,$minder,$paypal,$auftrnr;
-        $Zahlmethode=array("authorizenet"=>"Authorize.net","banktransfer"=>"Lastschriftverfahren","cc"=>"Kreditkarte",
-                "cod"=>"Nachnahme","eustandardtransfer"=>"EU-Standard Bank Transfer","iclear"=>"iclear Rechnungskauf",
-                "invoice"=>"Rechnung","ipayment"=>"iPayment","liberecobanktransfer"=>"Lastschriftverfahren",
-                "liberecocc"=>"Kreditkarte","moneybookers"=>"Moneybookers.com","moneyorder"=>"Scheck/Vorkasse",
-                "nochex"=>"NOCHEX","paypal"=>"PayPal","pm2checkout"=>"2CheckOut","psigate"=>"PSiGate",
-                "qenta"=>"qenta.at","secpay"=>"SECPay");
-        $brutto=getBrutto($data["orders_id"]);
-        $mwst=getMwSt($data["orders_id"]);
-        if ($GLOBALS["inclTax"]) {
-		$netto=$brutto-$mwst;
-	} else {
-		$netto=getNetto($data["orders_id"]);
-	}
-        $versandK=getSonderkosten($data["orders_id"],"Versand");
-        $nachnK  =getSonderkosten($data["orders_id"],"NachName");
-        $mindermK=getSonderkosten($data["orders_id"],"Minder");
-        $paypalK =getSonderkosten($data["orders_id"],"Paypal");
-	$netto+=$versandK;
-	$netto+=$nachnK;
-	$netto+=$mindermK;
-	$netto+=$paypalK;
-        // Hier beginnt die Transaktion
-	$rc=query("erp","BEGIN WORK","insAuftrag");
-	if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-        if ($auftrnr) {
-                $auftrag=$GLOBALS["preA"].getNextAnr();
-        } else {
-                $auftrag=$GLOBALS["preA"].$data["orders_id"];
-        }
-        $sql="select count(*) as cnt from oe where ordnumber = '$auftrag'";
-        $rs=getAll("erp",$sql,"insAuftrag 1");
-        if ($rs[0]["cnt"]>0) {
-                $auftrag=$GLOBALS["preA"].getNextAnr();
-        }
-        $newID=uniqid (rand());
-        $sql="insert into oe (notes,ordnumber,cusordnumber) values ('$newID','$auftrag','".$data["kdnr"]."')";
-        $rc=query("erp",$sql,"insAuftrag 2");
-	if ($rc === -99) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK WORK","chkKunde");
-		if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		return false;
-	}
-        $sql="select * from oe where notes = '$newID'";
-        $rs2=getAll("erp",$sql,"insAuftrag 3");
-	if (!$rs2>0) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK WORK","chkKunde");
-		if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		return false;
-	}
-	$zahlart=$data["payment_method"]."\n";
-        if ($data["cc_type"]) $zahlart.=$data["cc_type"]."\n".$data["cc_owner"]."\n".$data["cc_number"]."\n".$data["cc_expires"]."\n";
-        $sql="update oe set cusordnumber=".$data["orders_id"].", transdate='".$data["date_purchased"]."', customer_id=".$data["kdnr"].", ";
-        $sql.="amount=".$brutto.", netamount=".$netto.", reqdate='".$data["date_purchased"]."', taxincluded='f', ";
-	if ($data["shipto"]>0) $sql.="shipto_id=".$data["shipto"].", ";
-        $sql.="intnotes='".$data["comments"]."',notes='".$zahlart."', curr='EUR',employee_id=".$ERPusr["ID"].", vendor_id=0 ";
-        $sql.="where id=".$rs2[0]["id"];
-        $rc=query("erp",$sql,"insAuftrag 4");
-        if ($rc === -99) {
-                echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK WORK","chkKunde");
-		if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-                return false;
-        }
-        echo "Auftrag:[ Buchungsnummer:".$rs2[0]["id"]." AuftrNr:<b>".$auftrag."</b> ]<br>";
-        if (!insBestArtikel($data["orders_id"],$rs2[0]["id"])) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK WORK","chkKunde");
-		if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-                return false;
-        };
-        if ($versandK) {
-                $sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-                $sql.=$rs2[0]["id"].",".$versand["ID"].",'".$versand["TXT"]."',1,".$versandK.",'Stck',0,0)";
-                $rc=query("erp",$sql,"insAuftrag 8");
-                if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den Versandkosten<br>";
-        }
-        if ($nachnK) {
-                $sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-                $sql.=$rs2[0]["id"].",".$nachn["ID"].",'".$nachn["TXT"]."',1,".$nachnK.",'Stck',0,0)";
-                $rc=query("erp",$sql,"insAuftrag 9");
-                if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den Nachnamekosten<br>";
-        }
-        if ($mindermK) {
-                $sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-                $sql.=$rs2[0]["id"].",".$minder["ID"].",'".$minder["TXT"]."',1,".$mindermK.",'Stck',0,0)";
-                $rc=query("erp",$sql,"insAuftrag 10");
-                if ($rc === -99) echo "Auftrag $auftrag : Fehler beim Mindermengenzuschlag<br>";
-        }
-        if ($paypalK) {
-                $sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-                $sql.=$rs2[0]["id"].",".$paypal["ID"].",'".$paypal["TXT"]."',1,".$paypalK.",'Stck',0,0)";
-                $rc=query("erp",$sql,"insAuftrag 11");
-                if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den PayPal-Kosten<br>";
-        }
-        $sql="update orders set orders_status ='3' WHERE orders_id =".$data["orders_id"];
-        $rc=query("shop",$sql,"insBestArtikel 12");
-	if ($rc === -99) echo "Bestellung im Shop nicht geschlossen";
-	$rc=query("erp","COMMIT WORK","chkKunde");
-	if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-	return true;
-}
-
-/**********************************************
-* getBestellung()
-*
-**********************************************/
-function getBestellung() {
-	$sql="select o.*,h.comments,cn.kdnr from orders o left join orders_status_history h on h.orders_id=o.orders_id ";
-	$sql.="left join customers_number cn on ";
-	$sql.="cn.customers_id=o.customers_id where o.orders_status=1 order by o.orders_id";
-	$rs=getAll("shop",$sql,"getBestellung");
-	return $rs;
-}
-
-/**********************************************
-* chkKdData()
-*
-**********************************************/
-function chkKunden() {
-	$felder=array("firstname","lastname","company","street_address","city","postcode","country");
-	foreach ($GLOBALS["bestellungen"] as $bestellung) {
-		$rc=query("erp","BEGIN WORK","chkKunden");
-		if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		if ($bestellung["kdnr"]>0) { // Bestandskunde; kdnr == ID in customers
-			$msg="update ";
-			$kdnr=chkOldKd($bestellung);
-			if ($kdnr == -1) { //Kunde nicht gefunden, neu anlegen.
-				$msg="insert ";
-				$kdnr=insNewKd($bestellung);
-				$GLOBALS["neuKd"]++;
-			} else if (!$kdnr) {
-				echo $msg." ".$bestellung["customers_name"]." fehlgeschlagen!<br>";
-				$GLOBALS["gesKd"]++;
-				continue;
-			}
-		} else { // Neukunde
-			$msg="insert ";
-			$kdnr=insNewKd($bestellung);
-			$GLOBALS["neuKd"]++;
-		}
-		echo $bestellung["customers_company"]." ".$bestellung["customers_name"]." $kdnr<br>";
-		$GLOBALS["bestellungen"][$GLOBALS["gesKd"]]["kdnr"]=$kdnr;
-		$sql="delete from customers_number where customers_id=".$bestellung["customers_id"];
-        	$rc=query("shop",$sql,"chkKunde");
-        	$sql="insert into customers_number (customers_id,kdnr) values(".$bestellung["customers_id"].",".$kdnr.")";
-        	$rc=query("shop",$sql,"chkKunde");
-		if ($kdnr>0) {
-			foreach($felder as $feld) {
-				if ($bestellung["delivery_$feld"]<>$bestellung["customers_$feld"]) {
-					$rc=insShData($bestellung,$kdnr);
-					if ($rc>0) $GLOBALS["bestellungen"][$GLOBALS["gesKd"]]["shipto"]=$rc;
-					break;
-				}
-			}
-		}
-		if (!$kdnr || $rc === -99) {
-			echo $msg." ".$bestellung["customers_name"]." fehlgeschlagen! ($kdnr,$rc)<br>";
-			$rc=query("erp","ROLLBACK WORK","chkKunde");
-			if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		} else {
-			$rc=query("erp","COMMIT WORK","chkKunde");
-			if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		}
-		$GLOBALS["gesKd"]++;
-	}
-	return true;
-}
-
-function chkOldKd($data) {
-        $sql="select * from customer where id = ".$data["kdnr"];
-        $rs=getAll("erp",$sql,"chkKdData");
-        if (!$rs or count($rs)==0) { return -1; }; // Kunde nicht gefunden
-        if ($rs[0]["zipcode"]<>$data["customers_postcode"]) $set.="zipcode='".$data["customers_postcode"]."',";
-        if ($rs[0]["city"]<>$data["customers_city"]) $set.="city='".$data["customers_city"]."',";
-        if ($rs[0]["country"]<>$GLOBALS["taxarray"][$data["billing_country"]]["code"]) $set.="country='".$GLOBALS["taxarray"][$data["billing_country"]]["code"]."',";
-        if ($rs[0]["phone"]<>$data["customers_phone"])$set.="phone='".$data["customers_phone"]."',";
-        if ($rs[0]["email"]<>$data["customers_email_address"])$set.="email='".$data["customers_email_address"]."',";
-        if ($data["customers_company"]) {
-                if ($rs[0]["name"]<>$data["customers_company"]) $set.="name='".$data["customers_company"]."',";
-                if ($rs[0]["contact"]<>$data["customers_name"]) $set.="contact='".$data["customers_name"]."',";
-        } else {
-                if ($rs[0]["name"]<>$data["customers_name"]) $set.="name='".$data["customers_name"]."',";
-        }
-        if ($rs[0]["street"]<>$data["customers_street_address"]) $set.="street='".$data["customers_street_address"]."',";
-        if ($set) {
-        		$set=substr($set,0,-1);
-                $sql="update customer set $set where id=".$data["kdnr"];
-                $rc=query("erp",$sql,"chkKdData");
-                if ($rc === -99) {
-                        return false;
-                } else {
-                        return $data["kdnr"];
-                }
-        } else {
-                return $data["kdnr"];
-        }
-}
-
-/**********************************************
-* insShData($data,$id)
-*
-**********************************************/
-function insShData($data,$id) {
-        $set=$id;
-        if ($data["delivery_company"]) { $set.=",'".$data["delivery_company"]."','".$data["delivery_name"]."',"; }
-        else { $set.=",'".$data["delivery_name"]."','',"; }
-        $set.="'".$data["delivery_street_address"]."',";
-        $set.="'".$data["delivery_postcode"]."',";
-        $set.="'".$data["delivery_city"]."',";
-	if (in_array($data["delivery_country"],$GLOBALS["LAND"])) {
-		$set.="'".$GLOBALS["LAND"][$data["delivery_country"]]."',";
-	} else {
-		$set.="'".$data["delivery_country"]."',";
-	}
-        $set.="'".$data["customers_telephone"]."',";
-        $set.="'".$data["customers_email_address"]."'";
-        $sql="insert into shipto (trans_id,shiptoname,shiptodepartment_1,shiptostreet,shiptozipcode,shiptocity,";
-        $sql.="shiptocountry,shiptophone,shiptoemail,module) values ($set,'CT')";
-        $rc=query("erp",$sql,"insShData");
-	if ($rc === -99) return false;
-	$sql="select shipto_id from shipto where trans_id = $id and module='CT' order by itime desc limit 1";
-	$rs=getAll("erp",$sql,"insKdData");
-	if ($rs[0]["shipto_id"]>0) {
-		$sid=$rs[0]["shipto_id"];
-		$sql="update customers_number set shipto = $sid where kdnr = $id";
-        	$rc2=query("shop",$sql,"insShData");
-        	if ($rc2 === -99) {
-        		//$sql="delete from shipto where shipto_id=$sid";
-        		//$rc=query("shop",$sql,"insShData");
-			return false;
-		}
-		return $sid;
-	} else  {
-		echo "Fehler bei abweichender Anschrift ".$data["delivery_name"];
-		//$sql="delete from shipto where shipto_id=$sid";
-        	//$rc=query("shop",$sql,"insShData");
-		return false;
-	}
-}
-
-/**********************************************
-* insKdData($BID)
-*
-**********************************************/
-function insNewKd($data) {
-        $newID=uniqid(rand(time(),1));
-        //Kundennummer generieren
-        if ($GLOBALS["kdnum"]==1) { // von der ERP
-                $kdnr=$GLOBALS["preK"].getNextKnr();
-        } else {                    // durch Shop
-                $kdnr=$GLOBALS["preK"].$data["customers_id"];
-        }
-        $sql="select count(*) as cnt from customer where customernumber = '$kdnr'";
-        $rs=getAll("erp",$sql,"insKdData");
-        if ($rs[0]["cnt"]>0) {  // Kundennummer gibt es schon, eine neue aus ERP
-                $kdnr=$GLOBALS["preK"].getNextKnr();
-        }
-        $sql="insert into customer (name,customernumber) values ('$newID','$kdnr')";
-        $rc=query("erp",$sql,"insKdData");
-        if ($rc === -99) return false;
-        $sql="select * from customer where name = '$newID'";
-        $rs=getAll("erp",$sql,"insKdData");
-        if (!$rs) return false;
-        if ($data["customers_company"]) {
-                $set.="set name='".$data["customers_company"]."',contact='".$data["customers_name"]."',";
-        }else {
-		$tmp=strrpos($data["customers_name"]," ");
-		if ($tmp>0) {
-	                $set.="set name='".substr($data["customers_name"],$tmp+1).", ".substr($data["customers_name"],0,$tmp)."',";
-	                $set.="contact='".$data["customers_name"]."',";
-		} else {
-	                $set.="set name='".$data["customers_name"]."',";
-		}
-        }
-        $set.="street='".$data["customers_street_address"]."',";
-        $set.="zipcode='".$data["customers_postcode"]."',";
-        $set.="city='".$data["customers_city"]."',";
-        $set.="country='".$GLOBALS["taxarray"][$data["billing_country"]]["code"]."',";
-        $set.="phone='".$data["customers_telephone"]."',";
-        $set.="email='".$data["customers_email_address"]."',";
-        $tid=(in_array($data["billing_country"],array_keys($GLOBALS["taxarray"])))?$GLOBALS["taxarray"][$data["billing_country"]]["tax"]:3;
-        $set.="taxzone_id=$tid,";
-        $set.="taxincluded='f' ";
-        $sql="update customer ".$set;
-        $sql.="where id=".$rs[0]["id"];
-        $rc=query("erp",$sql,"insKdData");
-        if ($rc === -99) {
-		//$sql="delete from customer where id=".$rs[0]["id"];
-		//$rc=query("shop",$sql,"insNewKd");
-		return false;
-	} else { return $rs[0]["id"]; }
-}
-
-
-$LAND=array("Germany"=>"D","Austria"=>"A","Switzerland"=>"CH");
-$skosten=array("Versand"=>"ot_shipping","NachName"=>"ot_cod_fee","Paypal"=>"ot_cod_fee","Minder"=>"ot_loworderfee");
-$inclTax=checkTaxIncl();
-$TaxFactor=($inclTax)?getTaxRate():1;
-$bestellungen=getBestellung();
-$ok=count($bestellungen);
-$gesKd=0;
-$neuKd=0;
-if ($ok) {
-	echo "Es liegen $ok Bestellungen vor. <br>";
-	chkKunden();
-    	echo $gesKd." Kunde(n), davon ".$neuKd." neue(r) Kunde(n).<br>";
-    	foreach ($bestellungen as $bestellung) {
-        	insAuftrag($bestellung);
-    	}
-} else { echo "Es liegen keine Bestellungen vor!<br>"; };
-?>
-<!--a href='trans.php'>zur&uuml;ck</a-->
-</body>
-</html>
diff --git a/oscom/pixel_trans.gif b/oscom/pixel_trans.gif
deleted file mode 100644
index e7749f217..000000000
Binary files a/oscom/pixel_trans.gif and /dev/null differ
diff --git a/oscom/readme.first b/oscom/readme.first
deleted file mode 100644
index d50a7abfa..000000000
--- a/oscom/readme.first
+++ /dev/null
@@ -1,108 +0,0 @@
-Shop - Schnittstelle Lx-ERP <-> osCommerce
-
-Vorraussetzungen:
-	Lx-ERP Version >= 2.4.0 && < 2.6.x
-	osCommerce 2.2 ms 2
-	Pear DB
-
-Info:
-        Die Zusammenarbeit mit der Version 2.6.x wurde nicht getestet!
-
-        Die Anmeldung der Benutzer an LxO hat sich ge�ndert. Auch wurde  Lagerwesen eingef�hrt.
-        Damit die Schnittstelle mit Version 2.6.0 und neuer funktioniert, sollten hier Anpassungen
-        durchgef�hrt werden.
-
-
-Installation:
-Das tar-File unterhalb vom Webserververzeichnis oder dem ERP-Verzeichnis entpacken.
-
-	$ cd /var/www/html
-	$ tar xzf /pfad/zu/oscomm.tgz
-
-In das Verzeichnis oscomm wechseln und Schreibrechte auf die Datei conf.php und 
-das Verzeichnis tmp f�r den Webbenutzer (apache,www-data,httpd) vergeben.
-
-	$ chown apache conf.php
-	$ chmod 600 conf.php
-	$ chown apache tmp
-
-Im Browser folgende URL aufrufen:
-
-	http://webserver/pfad/oscomm/confedit.php
-
-	z.B.: http://localhost/oscomm/confedit.php
-
-Benutzer und Kennwort f�r die Erstinstallation sind:
-
-	oscom / oscom
-
-Die Maske sogf�lltig ausf�llen.
-
-	db-Host		db-Server f�r die jeweilige Anwendung
-	Database	Namen der Datenbankinstanzen
-	db-User		Username und Kennwort f�r die jeweilige Instanz
-	User-ID		Mit dieser ID soll in die ERP geschrieben werden
-	CSV-Dir		hier wird die csv-Datei erwartet (Schreibrechte!)
-	Image-Dir	hier liegen die Bilder
-	ftp-Host	Webserver der jeweiligen Anwendung
-	ftp-User	Name und Kennwort f�r ftp-Zugang
-	ID-xxxx		Interne ID der Waren. Lx-ERP:
-	Shopsprache	Die Id der Voreingestellten Sprache. Nur f�r diese 
-			werden die Artikel eingestellt.
-	Bildergr��e	in Byte
-	Preisgruppe	Welche Preisgruppe soll verwendet werden
-	Bestellnummern-
-	erweiterung	Zeichen die der Auftragsnummer vorangestellt werden
-
-Das Formular abschicken. 
-
-Sollen sp�ter �nderungen durchgef�hrt werden, so mu� bei der Anmeldung 
-der ERP-ftp-User als Benutzer verwendet werden.
-
-In der Shopinstanz mu� noch eine Tabelle angelegt werden. Das wird 
-normalerweise durch das Programm condedit.php erledigt. Sollte das aus 
-irgend einem Grund nicht funktionieren, f�hren Sie dazu die
-Datei oscom.sql als Datenbankbenutzer auf die Shopinstanz aus.
-
-	$ mysql -p -u dbuser dbinstanz < oscom.sql
-	Enter password:
-
-Ist diese Tabelle nicht angelegt, werden Kunden in der ERP immer wieder neu 
-angelegt.
-
-Fehlerquellen:
-Befinden sich ERP und Shop nicht auf dem gleichen Server, achten Sie darauf, das
-die entsprechende Datenbank von Aussen erreichbar ist. Dazu m�ssen folgende Ports 
-freigeschaltet werden:
-
-	MySQL		3306
-	PostgreSQL	5432
-
-Auch mu� auf dem Shopserver ein ftp-Dienst eingerichtet werden, wenn Bilder �ber-
-tragen werden sollen. Die Firewal ist entsprechend anzupassen.
-
-Arbeiten:
-In der ERP kann nun bei den Artikeln das H�ckchen Shop gesetzt werden.
-Bitte auch eine Warengruppe vergeben, da sonst alle Artikel in Default landen.
-Da die ERP nur eine Kategorieebene verwalten kann, mu� der ganze Kategorienpfad
-hintelegt werden. Die einzelnen Kategorien werden durch Ausrufezeichen (!) getrennt.
-
-	Hardware -> Monitore -> LCD = Hardware!Monitore!LCD
-
-Die URL f�r die Shopschnittstelle lautet:
-
-	http://webservername/pfad/oscom/trans.php
-
-
-Die Schnittstelle kann auch in die ERP integriert werden. Dazu installieren Sie
-die Schnittstelle wie beschrieben unterhalb der ERP. 
-Ersetzen Sie die menu.ini durch die Version im oscom-Verzeichnis.
-
-	$ cp /pfad/zu/oscom/menu.ini /pfad/zu/lx-erp
-
-Unter dem Men�punkt Shop stehen Ihnen nun die Module shopimport_db und oscomexport 
-zur Verf�gung.
-
-Copyright:
-Die Schnittstelle mit ihren einzelnen Bestandteilen steht unter "Artistic License".
-Das Copyright geh�rt Holger Lindemann. 
diff --git a/oscom/s2e.gif b/oscom/s2e.gif
deleted file mode 100644
index 684abd67e..000000000
Binary files a/oscom/s2e.gif and /dev/null differ
diff --git a/oscom/shopimport_csv.php b/oscom/shopimport_csv.php
deleted file mode 100644
index fd8f26e17..000000000
--- a/oscom/shopimport_csv.php
+++ /dev/null
@@ -1,172 +0,0 @@
-<?php
-/***************************************************************
-* $Id: shopimport_csv.php,v 1.2 2004/06/30 08:31:35 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.0
-*Shop: osCommerce 2.2
-***************************************************************/
-$login=$_GET["login"];
-require_once "DB.php";
-require_once "conf$login.php";
-$LAND=array("Germany"=>"D");
-$db=DB::connect($SHOPdns);
-if (!$db) dbFehler("",$db->getDebugInfo());
-if (DB::isError($db)) {
-	dbFehler("",$db->getDebugInfo());
-	die ($db->getDebugInfo());
-};
-
-function createCategory($name,$maingroup) {
-global $db,$langs;
-	$newID=uniqid(rand());
-	$sql="insert into categories (categories_image,parent_id,date_added) values ('$newID',$maingroup,now())";
-	$rc=$db->query($sql);
-	$sql="select * from categories where categories_image = '$newID'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$id=$rs[0]["categories_id"];
-	$sql="update categories set categories_image = null where categories_id=$id";
-	$rc=$db->query($sql);
-	echo "($name) ";
-	foreach ($langs as $LANG) {
-		$sql="insert into categories_description (categories_id,language_id,categories_name) values ($id,$LANG,'$name')";
-		$rc=$db->query($sql);
-		if (!$rc) break;
-	}
-	return ($rc)?$id:false;
-}
-function getCategory($name) {
-global $db;
-	if (empty($name)) $name="Default";
-	$tmp=split("!",$name);
-	$maingroup=0;
-	$found=true;
-	$i=0;
-	do {
-		$sql="select D.*,C.parent_id from categories C left join categories_description D on C.categories_id=D.categories_id where categories_name like '".$tmp[$i]."' and C.parent_id=$maingroup";
-		$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ($rs[0]["categories_id"]) {
-			$maingroup=$rs[0]["categories_id"];
-			echo $maingroup.":".$rs[0]["categories_name"]." ";
-			$i++;
-		} else {
-			$found=false;
-		}
-	} while ($rs and $found and $i<count($tmp));
-	for (;$i<count($tmp); $i++) {
-		$maingroup=createCategory($tmp[$i],$maingroup);
-	}
-	return $maingroup;
-}
-function insartikel($data) {
-global $db,$header,$tax,$defLang;
-	$newID=uniqid(rand());
-	$sql="insert into products (products_model,products_image) values ('".$data[array_search("products_model")]."','$newID')";
-	$rc=$db->query($sql);
-	$sql="select * from products where products_image='$newID'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$sql="update products set products_image=null,products_status=1 where products_id=".$rs[0]["products_id"];
-	$rc=$db->query($sql);
-	$sql="insert into products_description (products_id,language_id,products_name) values (".$rs[0]["products_id"].",$defLang,' ')";
-	$rc=$db->query($sql);
-	$sql="insert into products_to_categories (products_id,categories_id) values (".$rs[0]["products_id"].",".$data["categories_id"].")";
-	$rc=$db->query($sql);
-	echo " <b>insert</b> ";
-	updartikel($data,$rs[0]["products_id"]);
-}
-function updartikel($data,$id) {
-global $db,$header,$tax,$defLang;
-	$sql="update products set products_price=%01.2f,products_weight=%01.2f,products_tax_class_id=%d,products_last_modified=now(),products_quantity=%d   where products_id=%d";
-	$sql=sprintf($sql,$data[array_search("products_price",$header)],$data[array_search("products_weight",$header)],$tax[$data[array_search("products_tax",$header)]],$id,$data[array_search("products_quantity",$header)]);
-	$rc=$db->query($sql);
-	$sql="update products_description set products_name='%s',products_description='%s' where products_id=%d and language_id=$defLang";
-	$sql=sprintf($sql,$data[array_search("products_name",$header)],$data[array_search("products_description",$header)],$id);
-	$rc=$db->query($sql);
-	$sql="update products_to_categories set categories_id=".$data[array_search("categories_id",$header)]." where products_id=$id";
-	$rc=$db->query($sql);
-	echo "(".$id." ".$data[array_search("products_name",$header)].")+++<br>";
-}
-function chkartikel($data) {
-global $db,$header,$tax;
-	$sql="select * from products P left join products_description D on P.products_id=D.products_id left join products_to_categories C on P.products_id=C.products_id where  products_model like '".$data[array_search("products_model",$header)]."' and language_id=2";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs) {
-			 if ($rs[0]["products_price"]<>$data[array_search("products_price",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_weight"]<>$data[array_search("products_weight",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_name"]<>$data[array_search("products_name",$header)])		{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_description"]<>$data[array_search("products_description",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_tax_class_id"]<>$tax[$data[array_search("products_tax",$header)]])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["categories_id"]<>$data[array_search("categories_id",$header)])		{ updartikel($data,$rs[0]["products_id"]); }
-		else { echo "(".$rs[0]["products_id"]." ".$rs[0]["products_name"].")...<br>"; };
-	} else {
-		insartikel($data);
-	}
-}
-
-$sql="select languages_id from languages";
-$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$langs[]=$zeile["languages_id"];
-	}
-} else {
-	$langs[]=1;
-}
-$sql="select * from languages L left join configuration C on L.code=C.configuration_value where  configuration_key = 'DEFAULT_LANGUAGE'";
-$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($rs) {
-	$defLang=$rs[0]["languages_id"];
-} else {
-	$defLang=$SHOPlang;
-}
-$sql="select * from tax_rates";
-$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$tax[$zeile["tax_rate"]]=$zeile["tax_class_id"];
-	}
-} else {
-	$tax[0]="";
-}
-
-if ($_FILES["csv"]["name"] || ($_POST["nofile"] && file_exists($SHOPdir)) ) {
-	if ($_FILES["csv"]["tmp_name"]) {
-		move_uploaded_file($_FILES["csv"]["tmp_name"],$SHOPdir);
-	}
-	$f=fopen($SHOPdir,"r");
-	$header=fgetcsv($f,1000,";");
-	$header[]="categories_id";
-	$data=fgetcsv($f,1000,";");
-	while (!feof($f)) {
-		$catId=getCategory($data[array_search("categories_name",$header)]);
-		$data[]=$catId;
-		chkartikel($data);
-		$data=fgetcsv($f,1000,";");
-	}
-	fclose($f);
-	echo "<a href='trans.php'>zur&uuml;ck</a>";
-} else {
-?>
-<html>
-	<head>
-		<title>Datenaustausch ERP-osCommerce</title>
-	</head>
-<body>
-<center>
-<br>
-<h1>Artikelimport aus csv-Datei in osCommerce</h1><br>
-<form name="csv" action="shopimport_csv.php" enctype="multipart/form-data" method="post">
-	<INPUT TYPE="hidden" name="MAX_FILE_SIZE" value="500000">
-	<input type="checkbox" name="nofile" value="1">Auf dem Server vorhandene Daten importieren<br>
-	Datenfile f&uuml;r Import <input type="file" name="csv"><br>
-	<input type="submit" name="ok" value="ok">
-</form>
-</center>
-<a href="trans.php">zur&uuml;ck</a>
-</body>
-</html>
-<?
-}
-?>
diff --git a/oscom/shopimport_db.php b/oscom/shopimport_db.php
deleted file mode 100644
index 3ca4ddb2c..000000000
--- a/oscom/shopimport_db.php
+++ /dev/null
@@ -1,272 +0,0 @@
-<?php
-/***************************************************************
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.6.0
-*Shop: osCommerce 2.2
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-require_once "shoplib.php";
-$LAND=array("Germany"=>"D");
-$nun=date("d.m.y H:i:s");
-
-// Ab hier Artikelexport aus ERP
-function shopartikel() {
-global $pricegroup;
-	if ($pricegroup>0) {
-		$sql="SELECT P.partnumber,P.description,G.price as sellprice,P.sellprice as stdprice, ";
-		$sql.="PG.partsgroup,P.notes,P.image,P.onhand,G.pricegroup_id,P.buchungsgruppen_id as bugru FROM ";
-		$sql.="parts P left join partsgroup PG on ";
-		$sql.="PG.id=P.partsgroup_id left join prices G on G.parts_id=P.id ";
-		$sql.="where P.shop='t' and ";
-		$sql.="(G.pricegroup_id=$pricegroup or G.pricegroup_id is null) ";
-		$sql.="order by P.partnumber";
-	} else {
-		$sql="SELECT P.partnumber,P.description,P.weight,P.sellprice,PG.partsgroup,";
-		$sql.="P.notes,P.image,P.onhand,P.buchungsgruppen_id as bugru ";
-		$sql.="FROM parts P left join partsgroup PG on PG.id=P.partsgroup_id ";
-		$sql.="left join buchungsgruppen B on P.buchungsgruppen_id = B.id ";
-		$sql.="WHERE P.shop='t'";
-	}
-	$rs=getAll("erp",$sql,"shopartikel");
-	return $rs;
-}
-
-// Ab hier Import der Daten in den Shop
-function createCategory($name,$maingroup) {
-global $defLang;
-	$newID=uniqid(rand());
-	$sql="insert into categories (categories_image,parent_id,date_added) values ('$newID',$maingroup,now())";
-	$rc=query("shop",$sql,"createCategory");
-	$sql="select * from categories where categories_image = '$newID'";
-	$rs=getAll("shop",$sql,"createCategory");
-	$id=$rs[0]["categories_id"];
-	$sql="update categories set categories_image = 'pixel_trans.gif' where categories_id=$id";
-	$rc=query("shop",$sql,"createCategory");
-	echo "($name) ";
-	$sql="insert into categories_description (categories_id,language_id,categories_name) values ($id,$defLang,'$name')";
-	$rc=query("shop",$sql,"createCategory");
-	return ($rc)?$id:false;
-}
-function getCategory($name) {
-	if (empty($name)) $name="Default";
-	$tmp=split("!",$name);
-	$maingroup=0;
-	$found=true;
-	$i=0;
-	do {
-		$sql="select D.*,C.parent_id from categories C left join categories_description D on C.categories_id=D.categories_id ";
-		$sql.="where categories_name like '".$tmp[$i]."' and C.parent_id=$maingroup";
-		$rs=getAll("shop",$sql,"getCategory");
-		if ($rs[0]["categories_id"]) {
-			$maingroup=$rs[0]["categories_id"];
-			$i++;
-		} else {
-			$found=false;
-		}
-	} while ($rs and $found and $i<count($tmp));
-	for (;$i<count($tmp); $i++) {
-		$maingroup=createCategory($tmp[$i],$maingroup);
-	}
-	return $maingroup;
-}
-function bilder($width,$height,$dest) {
-	if (!function_exists("imagick_readimage")) { echo "Imagick-Extention nicht installiert"; return false; };
-	$handle=imagick_readimage("./tmp/tmp.file_org");
-	if (!$handle) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Lesen: $reason<BR>\n" ; flush();
-		return false;
-	}
-	if (!imagick_resize( $handle, $width, $height, IMAGICK_FILTER_UNKNOWN, 0)) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Resize: $reason<BR>\n" ;	flush();
-		return false;
-	}
-	if (!imagick_writeimage( $handle,"./tmp/tmp.file_$dest")) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Schreiben: $reason<BR>\n" ; 	flush();
-		return false;
-	}
-	return true;
-}
-function uploadImage($image,$id) {
-global $ERPftphost,$ERPftpuser,$ERPftppwd,$ERPimgdir,$maxSize,$SHOPftphost,$SHOPftpuser,$SHOPftppwd,$SHOPimgdir;
-	$tmp=split("/",$image);
-	$cnt=count($tmp)-1;
-	$name=(strrpos($image,"/")>0)?substr($image,strrpos($image,"/")+1):$image;
-	$ok=true;
-	if ($ERPftphost==$SHOPftphost and $ERPftphost=="localhost") {
-		$destdir=$SHOPimgdir."/".substr($image,0,strrpos($image,"/"));
-		$ret=exec("mkdir -p $destdir/".$tmp[$i],$out,$rc);
-		$rc=exec("cp $ERPimgdir/$image $SHOPimgdir/$image",$o2,$rc2);
-		if ($rc2>0) { $ok=false; echo "Kopieren nicht erfolgreich $image<br>"; }
-	} else if ($ERPftphost=="localhost") 	{
-		$rc3=exec("cp $ERPimgdir/$image ./tmp/tmp.file",$o2,$rc2);
-		if ($rc2>0) {
-			echo "Kopieren nicht erfolgreich. ";
-		} else {
-			$conn_id = ftp_connect($SHOPftphost);
-			ftp_login($conn_id,$SHOPftpuser,$SHOPftppwd);
-			ftp_chdir($conn_id,$SHOPimgdir);
-			for ($i=0; $i<$cnt; $i++) {
-				@ftp_mkdir($conn_id,$tmp[$i]);
-				@ftp_chdir($conn_id,$tmp[$i]);
-			}
-			$src=$SHOPimgdir."/".$image;
-			$upload=ftp_put($conn_id,"$src","tmp/tmp.file",FTP_BINARY);
-			if (!$upload) { $ok=false; echo "Ftp upload war fehlerhaft!";};
-			ftp_quit($conn_id);
-		}
-	} else if ($SHOPftphost=="localhost") {
-		$conn_id = ftp_connect($ERPftphost);
-		ftp_login($conn_id,$ERPftpuser,$ERPftppwd);
-		$src=$ERPimgdir."/".$image;
-		$upload=ftp_get($conn_id,"tmp/tmp.file","$src",FTP_BINARY);
-		if (!$upload) { $ok=false; echo "Ftp download war fehlerhaft!";};
-		ftp_quit($conn_id);
-		exec("cp tmp/tmp.file $SHOPimgdir/$image",$o2,$rc2);
-		if ($rc2) { $ok=false; echo "Kopieren nicht erfolgreich"; }
-	} else {
-		$conn_id = ftp_connect($ERPftphost);
-		ftp_login($conn_id,$ERPftpuser,$ERPftppwd);
-		$src=$ERPimgdir."/".$image;
-		$upload=ftp_get($conn_id,"tmp/tmp.file","$src",FTP_BINARY);
-		if (!$upload) { $ok=false; echo "Ftp download war fehlerhaft!";};
-		ftp_quit($conn_id);
-		$conn_id = ftp_connect($SHOPftphost);
-		ftp_login($conn_id,$SHOPftpuser,$SHOPftppwd);
-		ftp_chdir($conn_id,$SHOPimgdir);
-		for ($i=0; $i<$cnt; $i++) {
-			@ftp_mkdir($conn_id,$tmp[$i]);
-			@ftp_chdir($conn_id,$tmp[$i]);
-		}
-		$src=$SHOPimgdir."/".$image;
-		$upload=ftp_put($conn_id,"$src","tmp/tmp.file",FTP_BINARY);
-		if (!$upload) { $ok=false; echo "Ftp upload war fehlerhaft!";};
-		ftp_quit($conn_id);
-	}
-	if ($ok) {
-		$sql="update products set products_image='%s',products_last_modified=now() where products_id=%d";
-		$sql=sprintf($sql,$image,$id);
-		$rc=query("shop",$sql,"uploadImage");
-	}
-}
-function insartikel($data) {
-global $header,$defLang;
-	echo " insert ";
-	$newID=uniqid(rand());
-	$sql="insert into products (products_model,products_image) values ('".$data["partnumber"]."','$newID')";
-	$rc=query("shop",$sql,"insartikel");
-	if ($rc === -99) { echo "Fehler.<br>"; return false; };
-	$sql="select * from products where products_image='$newID'";
-	$rs=getAll("shop",$sql,"insartikel");
-	$sql="update products set products_image='pixel_trans.gif' where products_id=".$rs[0]["products_id"];
-	$rc=query("shop",$sql,"insartikel");
-	if ($rc === -99) { echo "Fehler.<br>"; return false; };
-	$sql="insert into products_description (products_id,language_id,products_name) values (".$rs[0]["products_id"].",$defLang,' ')";
-	$rc=query("shop",$sql,"insartikel");
-	if ($rc === -99) { echo "Fehler.<br>"; return false; };
-	$sql="insert into products_to_categories (products_id,categories_id) values (".$rs[0]["products_id"].",".$data["categories_id"].")";
-	$rc=query("shop",$sql,"insartikel");
-	if ($rc === -99) { echo "Fehler.<br>"; return false; };
-	if (updartikel($data,$rs[0]["products_id"])) {
-		return $rs[0]["products_id"];
-	} else {
-		return false;
-	}
-}
-function updartikel($data,$id) {
-global $header,$defLang,$tax;
-	$sql="update products set products_status=1,products_price=%01.2f,products_weight=%01.2f,products_tax_class_id=%d,";
-	$sql.="products_last_modified=now(),products_quantity=%d where products_id=%d";
-	$sql=sprintf($sql,$data["preis"],$data["weight"],$tax[sprintf("%1.4f",$data["rate"])],$data["onhand"],$id);
-	$rc=query("shop",$sql,"updartikel");
-	if ($rc === -99) { echo "Fehler <br>"; return false; };
-	$sql="update products_description set products_name='%s',products_description='%s' where products_id=%d and language_id=$defLang";
-	$sql=sprintf($sql,$data["description"],$data["notes"],$id);
-	$rc=query("shop",$sql,"updartikel");
-	if ($rc === -99) { echo "Fehler <br>"; return false; };
-	$sql="update products_to_categories set categories_id=".$data["categories_id"]." where products_id=$id";
-	$rc=query("shop",$sql,"updartikel");
-	if ($rc === -99) { echo "Fehler <br>"; return false; };
-	echo "+++<br>";
-	return true;
-}
-function chkartikel($data) {
-global $header,$shop2erp,$erptax,$defLang;
-	if ($data["partnumber"]=="") { echo "Artikelnummer fehlt!<br>"; return;};
-	$sql="select * from products P left join products_description D on P.products_id=D.products_id left join products_to_categories C on ";
-	$sql.="P.products_id=C.products_id where  products_model like '".$data["partnumber"]."' and language_id=$defLang";
-	echo "(".$data["partnumber"]."->".$rs[0]["products_id"].":".$data["description"].")";
-    if ($data["image"]) {
-            $data["picname"]=(strrpos($data["image"],"/")>0)?substr($data["image"],strrpos($data["image"],"/")+1):$data["image"];
-    } else if ($nopic) {
-            $data["picname"]=(strrpos($nopic,"/")>0)?substr($nopic,strrpos($nopic,"/")+1):$nopic;
-            $data["image"]=$nopic;
-    }
-	$data["onhand"]=floor($data["onhand"]);
-	$data["rate"]=$erptax[$data["bugru"]]["rate"];
-	$data["preis"]=($data["sellprice"]>0)?$data["sellprice"]:$data["stdprice"];
-	$rs=getAll("shop",$sql,"chkartikel");
-	if ($rs) {
-		$rc=updartikel($data,$rs[0]["products_id"]);
-		if ($rs[0]["products_image"]<>$data["image"] and $data["picname"] and $rc) uploadImage($data["image"],$rs[0]["products_id"]);
-	} else {
-		$id=insartikel($data);
-		if ($data["image"] and $id) uploadImage($data["image"],$id);
-	}
-}
-if ($SHOPlang>0) {
-	$defLang=$SHOPlang;
-} else {
-	$sql="select * from languages L left join configuration C on L.code=C.configuration_value where  configuration_key = 'DEFAULT_LANGUAGE'";
-	$rs=getAll("shop",$sql,"SHOPlang");
-	if ($rs) {
-		$defLang=$rs[0]["languages_id"];
-	} else {
-		$defLang=1;
-	}
-}
-
-$sql="select * from tax_rates";
-$rs=getAll("shop",$sql,"tax_rates");
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$tax[$zeile["tax_rate"]]=$zeile["tax_class_id"];
-	}
-} else {
-	$tax[0]="";
-}
-
-
-/*******************************************
-* Steuern
-*******************************************/
-//Steuertabelle ERP
-$sql ="select  BG.id as bugru,T.rate,TK.startdate from buchungsgruppen BG left join chart C ";
-$sql.="on BG.income_accno_id_0=C.id left join taxkeys TK on TK.chart_id=C.id left join tax T ";
-$sql.="on T.id=TK.tax_id where TK.startdate <= now()";
-$rs=getAll("erp",$sql,"Tax ERP");
-$erptax=array();
-foreach ($rs as $row) {
-        if ($erptax[$row["bugru"]]["startdate"]<$row["startdate"]) {
-                $erptax[$row["bugru"]]["startdate"]=$row["startdate"];
-                $erptax[$row["bugru"]]["rate"]=$row["rate"]*100;
-        }
-}
-
-
-$artikel=shopartikel();
-echo "Artikelexport ERP -&gt; osCommerce :".count($artikel)." Artikel markiert.<br>";
-if ($artikel) {
-	foreach ($artikel as $data) {
-		$data["categories_id"]=getCategory($data["partsgroup"]);
-		chkartikel($data);
-	}
-	require ("diff.php");
-}
-
-?>
diff --git a/oscom/shoplib.php b/oscom/shoplib.php
deleted file mode 100644
index 70094c8cb..000000000
--- a/oscom/shoplib.php
+++ /dev/null
@@ -1,185 +0,0 @@
-<?php
-
-$login=$_GET["login"];
-$debug=false;
-require_once "DB.php";
-if (file_exists ("conf$login.php")) {
-echo "User";
-        require "conf$login.php";
-} else {
-echo "Global";
-        require "conf.php";
-}
-
-
-$landarray=array("DEUTSCHLAND"=>"D","STEREICH"=>"A","OESTEREICH"=>"A","SCHWEIZ"=>"CH");
-$EU=2;  //EU ohne UStID, 1 = EU mit UStID
-$taxarray=array(
-	'Germany'=>array('code'=>'DE','tax'=>0),		'Austria'=>array('code'=>'AU','tax'=>$EU), 			'Belgium'=>array('code'=>'BE','tax'=>$EU),
-	'Bulgaria'=>array('code'=>'BG','tax'=>$EU),		'Czech Republic'=>array('code'=>'CZ','tax'=>$EU), 	'Denmark'=>array('code'=>'DK','tax'=>$EU),
-	'Estonia'=>array('code'=>'EE','tax'=>$EU),		'Spain'=>array('code'=>'ES','tax'=>$EU), 			'Finland'=>array('code'=>'FI','tax'=>$EU),
-	'France'=>array('code'=>'FR','tax'=>$EU), 		'United Kingdom'=>array('code'=>'GB','tax'=>$EU), 	'Greece'=>array('code'=>'GR','tax'=>$EU),
-	'Hungary'=>array('code'=>'HU','tax'=>$EU),		'Ireland'=>array('code'=>'IE','tax'=>$EU), 			'Italy'=>array('code'=>'IT','tax'=>$EU),
-	'Luxembourg'=>array('code'=>'LU','tax'=>$EU),	'Malta'=>array('code'=>'MT','tax'=>$EU), 			'Netherlands'=>array('code'=>'NL','tax'=>$EU),
-	'Poland'=>array('code'=>'PL','tax'=>$EU),		'Portugal'=>array('code'=>'PT','tax'=>$EU), 		'Romania'=>array('code'=>'RO','tax'=>$EU),
-	'Sweden'=>array('code'=>'SE','tax'=>$EU), 		'Slovenia'=>array('code'=>'SI','tax'=>$EU), 		'Slovakia (Slovak Republic)'=>array('code'=>'SK','tax'=>$EU),
-	'Cyprus'=>array('code'=>'CY','tax'=>$EU), 		'Lithuania'=>array('code'=>'LT','tax'=>$EU), 		'Latvia'=>array('code'=>'LV','tax'=>$EU));
-
-$defaultland="D";
-$taxid=0;
-$log=false;
-$erp=false;
-$shop=false;
-
-
-$ERPdns= array('phptype'  => 'pgsql',
-               'username' => $ERPuser,
-               'password' => $ERPpass,
-               'hostspec' => $ERPhost,
-               'database' => $ERPdbname,
-               'port'     => $ERPport);
-
-$SHOPdns=array('phptype'  => 'mysql',
-               'username' => $SHOPuser,
-               'password' => $SHOPpass,
-               'hostspec' => $SHOPhost,
-               'database' => $SHOPdbname,
-               'port'     => $SHOPport,
-	       'AutoCommit' => 0);
-
-/****************************************************
-* Debugmeldungen in File schreiben
-****************************************************/
-if ($debug) { $log=fopen("tmp/shop.log","a"); } // zum Debuggen
-else { $log=false; };
-
-/****************************************************
-* Shopverbindung aufbauen
-****************************************************/
-$shop=DB::connect($SHOPdns);
-if (!$shop) shopFehler("",$shop->getDebugInfo());
-if (DB::isError($shop)) {
-	$nun=date("Y-m-d H:i:s");
-	if ($log) fputs($log,$nun.": Shop-Connect\n");
-	shopFehler("",$shop->getDebugInfo());
-	die ($shop->getDebugInfo());
-};
-
-/****************************************************
-* ERPverbindung aufbauen
-****************************************************/
-$erp=DB::connect($ERPdns);
-if (!$erp) shopFehler("",$erp->getDebugInfo());
-if (DB::isError($erp)) {
-	$nun=date("Y-m-d H:i:s");
-	if ($log) fputs($log,$nun.": ERP-Connect\n");
-	shopFehler("",$erp->getDebugInfo());
-	die ($erp->getDebugInfo());
-} else {
-	$erp->autoCommit(true);
-};
-
-
-/****************************************************
-* SQL-Befehle absetzen
-****************************************************/
-function query($db,$sql,$function="--") {
-	$nun=date("d.m.y H:i:s");
-	//if ($db<>"shop") { echo "$sql!$db!<br>"; flush(); };
-	if ($GLOBALS["log"]) fputs($GLOBALS["log"],$nun.": ".$function."\n".$sql."\n");
-	$rc=$GLOBALS[$db]->query($sql);
- 	if ($GLOBALS["log"]) fputs($GLOBALS["log"],print_r($rc,true)."\n");
- 	if ($rc!==1) {
-		return -99;
-	} else {
-                if ($GLOBALS["log"]) fputs($GLOBALS["log"],print_r($rs,true)."\n");
-		return true;
-	}
-}
-
-/****************************************************
-* Datenbank abfragen
-****************************************************/
-function getAll($db,$sql,$function="--") {
-	$nun=date("d.m.y H:i:s");
-	if ($GLOBALS["log"]) fputs($GLOBALS["log"],$nun.": ".$function."\n".$sql."\n");
-	$rs=$GLOBALS[$db]->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs["message"]<>"") {
-	       	if ($GLOBALS["log"]) fputs($GLOBALS["log"],print_r($rs,true)."\n");
-		return false;
-	} else {
-	       	if ($GLOBALS["log"]) fputs($GLOBALS["log"],print_r($rs,true)."\n");
-       	 	return $rs;
-	}
-}
-
-/****************************************************
-* shopFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function shopFehler($sql,$err) {
-global $showErr;
-	if ($showErr)
-		echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-
-/****************************************************
-* Nächste Auftragsnummer (ERP) holen
-****************************************************/
-function getNextAnr() {
-	$sql="select * from defaults";
-	$sql1="update defaults set sonumber=";
-	$rs2=getAll("erp",$sql,"getNextAnr");
-	if ($rs2[0]["sonumber"]) {
-		$auftrag=$rs2[0]["sonumber"]+1;
-		$rc=query("erp",$sql1.$auftrag,"getNextAnr");
-		if ($rc === -99) {
-			echo "Kann keine Auftragsnummer erzeugen - Abbruch";
-			exit();
-		}
-		return $auftrag;
-	} else {
-		return false;
-	}
-}
-
-/****************************************************
-* Nächste Kundennummer (ERP) holen
-****************************************************/
-function getNextKnr() {
-	$sql="select * from defaults";
-	$sql1="update defaults set customernumber='";
-	$rs2=getAll("erp",$sql,"getNextKnr");
-	if ($rs2[0]["customernumber"]) {
-		$kdnr=$rs2[0]["customernumber"]+1;
-		$rc=query("erp",$sql1.$kdnr."'","getNextKnr");
-		if ($rc === -99) {
-			echo "Kann keine Kundennummer erzeugen - Abbruch";
-			exit();
-		}
-		return $kdnr;
-	} else {
-		return false;
-	}
-}
-
-
-$buchungsgruppen=array();
-$warengruppen=array();
-
-function getBugru() {
-	$sql ="select B.id,tax.rate from buchungsgruppen B left join chart on income_accno_id_0=chart.id left join taxkeys T on ";
-	$sql.="T.chart_id=income_accno_id_0 left join tax on tax.id=T.tax_id where T.startdate<=now()";
-	$rs=getAll("erp",$sql,"getBugru");
-	if ($rs) foreach ($rs as $row) {
-		$steuer=sprintf("%0.2f",$row["rate"]*100);
-		$GLOBALS["buchungsgruppen"][$steuer]=$row["id"];
-	}
-}
-
-$wg=1000;
-
-getBugru();
-?>
diff --git a/oscom/tmp/.dummy b/oscom/tmp/.dummy
deleted file mode 100644
index e69de29bb..000000000
diff --git a/oscom/trans.php b/oscom/trans.php
deleted file mode 100644
index 1efd47746..000000000
--- a/oscom/trans.php
+++ /dev/null
@@ -1,114 +0,0 @@
-<?
-/***************************************************************
-* $Id: trans.php,v 1.1 2004/06/29 08:50:30 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.0
-*Shop: osCommerce 2.2
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-require_once "DB.php";
-require_once "conf.php";
-$LAND=array("Germany"=>"D");
-$db=DB::connect($SHOPdns);
-if (DB::isError($db)||!$db) { $shop="<font color='red'>Fehler</font>"; } else { $shop="ok"; };
-$db2=DB::connect($ERPdns);
-if (DB::isError($db2)||!$db2) { $erp="<font color='red'>Fehler</font>"; } else { $erp="ok"; };
-
-?>
-<html>
-	<head>
-		<title>Datenaustausch ERP-osCommerce</title>
-	</head>
-<body>
-<center>
-<table>
-	<tr>
-		<td colspan="2">
-			Eine direkte Verbindung beider Datenbanken ist erforderlich!<br>
-			Folgende Verbindungsdaten wurden gefunden:
-		</td>
-	</tr>
-	<tr>
-		<td>
-			<b>Lx-ERP</b>
-		</td>
-		<td><?= $erp ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank-Server</td>
-		<td><?= $ERPhost ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank</td>
-		<td><?= $ERPdbname ?></td>
-	</tr>
-	<tr>
-		<td>
-			<b>osCommerce</b>
-		</td>
-		<td><?= $shop ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank-Server</td>
-		<td><?= $SHOPhost ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank</td>
-		<td><?= $SHOPdbname ?></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td align="center"><a href="shopimport_db.php"><img src="e2s.gif" border="0"></a></td>
-		<td align="center"><a href="oscomexport.php"><img src="s2e.gif" border="0"></a></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			F&uuml;r den Export der Artikeldaten aus der ERP in eine CSV-Datei<br>
-			oder den Import der Artikeldaten in den Shop ist nur die Verbindung<br>
-			zur entsprechenden	Datenbank notwendig.<br>
-			Die CSV-Dateien werden in den konfigurierten Verzeichnissen erwartet.<br>
-			Der Webserver ben&ouml;tigt hier Schreibrechte.
-		</td>
-	</tr>
-	<tr>
-		<td>
-			<b>Lx-ERP</b>
-		</td>
-		<td><a href="<?= $ERPdir ?>"><?= $ERPdir ?></a></td>
-	</tr>
-	<tr>
-		<td>
-			<b>osCommerce</b>
-		</td>
-		<td><a href="<?= $SHOPdir ?>"><?= $SHOPdir ?></a></td>
-	</tr>
-	<tr>
-		<td align="center"><a href="erpexport.php"><img src="e2c.gif" border="0"></a></td>
-		<td align="center"><a href="shopimport_csv.php"><img src="c2s.gif" border="0"></a></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			Copyright (c) 2004 Lx-System - Version: 1.0 - <a href="mailto:info@lx-system.de">info@lx-system.de</a>
-		</td>
-	</tr>
-</table>
-</center>
-</body>
-</html>
diff --git a/pepper/c2s.gif b/pepper/c2s.gif
deleted file mode 100644
index 1f900541d..000000000
Binary files a/pepper/c2s.gif and /dev/null differ
diff --git a/pepper/conf.php b/pepper/conf.php
deleted file mode 100644
index 9ea233e63..000000000
--- a/pepper/conf.php
+++ /dev/null
@@ -1,56 +0,0 @@
-<?
-// Verbindung zur ERP-db
-$ERPuser="lxoffice";
-$ERPpass="geheim";
-$ERPhost="localhost";
-$ERPdbname="lxerp1";
-$ERPdns="pgsql://$ERPuser:$ERPpass@$ERPhost/$ERPdbname";
-$ERPusr["Name"]="demo";
-$ERPusr["ID"]="376";
-$ERPdir="tmp/shopartikel.csv";
-$ERPimgdir="/usr/lib/lx-office-erp";
-$maxSize="";
-$ERPftphost="localhost";
-$ERPftpuser="pepper";
-$ERPftppwd="pepper";
-//Verbindung zur osCommerce-db
-$SHOPuser="root";
-$SHOPpass="27123";
-$SHOPhost="localhost";
-$SHOPdbname="TestLocal";
-$SHOPdns="mysql://$SHOPuser:$SHOPpass@$SHOPhost/$SHOPdbname";
-$SHOPdir="tmp/shopartikel.csv";
-$SHOPimgdir="/var/www/TestLocal/shop/ProdukteBilder";
-$SHOPftphost="localhost";
-$SHOPftpuser="pepper";
-$SHOPftppwd="pepper";
-$div16["ID"]="391";
-$div07["ID"]="";
-$versand["ID"]="411";
-$nachn["ID"]="411";
-$minder["ID"]="391";
-$treuh["ID"]="391";
-$paypal["ID"]="391";
-$div16["NR"]="1002";
-$div07["NR"]="";
-$versand["NR"]="1003";
-$nachn["NR"]="1003";
-$minder["NR"]="1002";
-$treuh["NR"]="1002";
-$paypal["NR"]="1002";
-$div16["TXT"]="Diverse";
-$div07["TXT"]="";
-$versand["TXT"]="Versandkosten";
-$nachn["TXT"]="Versandkosten";
-$minder["TXT"]="Diverse";
-$treuh["TXT"]="Diverse";
-$paypal["TXT"]="Diverse";
-$bgcol[1]="#ddddff";
-$bgcol[2]="#ddffdd";
-$preA="P_";
-$preK="P_";
-$auftrnr="1";
-$kdnum="1";
-$pricegroup="382";
-$showErr="true";
-?>
\ No newline at end of file
diff --git a/pepper/confedit.php b/pepper/confedit.php
deleted file mode 100644
index 57a74e5af..000000000
--- a/pepper/confedit.php
+++ /dev/null
@@ -1,368 +0,0 @@
-<?
-// $Id: confedit.php 2009/02/10 14:41:30 hli Exp $
-if (!isset($_SERVER['PHP_AUTH_USER'])) {
-       Header("WWW-Authenticate: Basic realm=\"Configurations-Editor\"");
-       Header("HTTP/1.0 401 Unauthorized");
-       echo "Sie m&uuml;ssen sich autentifizieren\n";
-       exit;
-} else {
-	$login=($_GET["login"])?$_GET["login"]:$_POST["login"];
-	if (file_exists ("conf$login.php")) {
-		require "conf$login.php";
-	} else {
-		require "conf.php";
-	}
-	if ($_SERVER['PHP_AUTH_USER']<>$ERPftpuser || $_SERVER['PHP_AUTH_PW']<>$ERPftppwd) {
-		Header("WWW-Authenticate: Basic realm=\"My Realm\"");
-		Header("HTTP/1.0 401 Unauthorized");
-		echo "Sie m&uuml;ssen sich autentifizieren\n";
-		exit;
-	}
-	require_once "DB.php";
-	function unit($sel) {
-	global $dbP;
-		$sql="select name from units order by sortkey";
-		$pgs=$dbP->getall($sql);
-		if ($sel=='') $sel=$pgs[0][0];
-		if ($pgs) foreach ($pgs as $row) {
-			echo "\t<option value=".$row[0];
-			if ($sel==$row[0]) echo " selected";
-			echo ">".$row[0]."\n";
-		}
-	}
-	function pg($sel) {
-	global $dbP;
-		$sql="select id,pricegroup from pricegroup";
-		$pgs=$dbP->getall($sql);
-		echo "\t<option value=0";
-		if ($sel==0) echo " selected";
-		echo ">Standard VK\n";
-		if ($pgs) foreach ($pgs as $row) {
-			echo "\t<option value=".$row[0];
-			if ($sel==$row[0]) echo " selected";
-			echo ">".$row[1]."\n";
-		}
-	}
-	if ($_POST["ok"]=="sichern") {
-		$ok=true;
-        $dsnP = array(
-				'phptype'  => 'pgsql',
-				'username' => $_POST["ERPuser"],
-				'password' => $_POST["ERPpass"],
-				'hostspec' => $_POST["ERPhost"],
-				'database' => $_POST["ERPdbname"],
-				'port'     => $_POST["ERPport"]
-        );
-		$dbP=@DB::connect($dsnP);
-		if (DB::isError($dbP)||!$dbP) {
-			$ok=false;
-			echo "Keine Verbindung zur ERP<br>";
-			echo $dbP->userinfo;
-			$dbP=false;		
-		}
-		else {
-			$sql="SELECT id,description,buchungsgruppen_id FROM parts where partnumber = '%s'";
-			$rs=$dbP->getall(sprintf($sql,$_POST["div16NR"]));
-			$_POST["div16ID"]=$rs[0][0];
-			$div16txt=addslashes($rs[0][1]);
-		    $rs=$dbP->getall(sprintf($sql,$_POST["div07NR"]));
-			$_POST["div07ID"]=$rs[0][0];
-			$div07txt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["versandNR"]));
-			$_POST["versandID"]=$rs[0][0];
-			$versandtxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["nachnNR"]));
-			$_POST["nachnID"]=$rs[0][0];
-			$nachntxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["minderNR"]));
-			$_POST["minderID"]=$rs[0][0];
-			$mindertxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["paypalNR"]));
-			$_POST["paypalID"]=$rs[0][0];
-			$paypaltxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["treuhNR"]));
-			$_POST["treuhID"]=$rs[0][0];
-			$treuhtxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall("select id from employee where login = '".$_POST["ERPusrN"]."'");
-			$_POST["ERPusrID"]=$rs[0][0];
-		}
-        $dsnM = array(
-				'phptype'  => 'mysql',
-				'username' => $_POST["SHOPuser"],
-				'password' => $_POST["SHOPpass"],
-				'hostspec' => $_POST["SHOPhost"],
-				'database' => $_POST["SHOPdbname"],
-				'port'     => $_POST["SHOPport"]
-        );
-		$dbM=@DB::connect($dsnM);
-		if (DB::isError($dbM)||!$dbM) {
-			//$ok=false;
-			echo "Keine Verbindung zum Shop<br>";
-			echo $dbM->userinfo;
-			$dbM=false;
-		};		
-		if (ok) {
-			$f=fopen("conf$login.php","w");
-			$v="1.5";
-			$d=date("Y/m/d H:i:s");
-			fputs($f,"<?\n// Verbindung zur ERP-db\n");
-			fputs($f,"\$ERPuser=\"".$_POST["ERPuser"]."\";\n");
-			fputs($f,"\$ERPpass=\"".$_POST["ERPpass"]."\";\n");
-			fputs($f,"\$ERPhost=\"".$_POST["ERPhost"]."\";\n");
-			fputs($f,"\$ERPdbname=\"".$_POST["ERPdbname"]."\";\n");
-			fputs($f,"\$ERPdns=\"pgsql://\$ERPuser:\$ERPpass@\$ERPhost/\$ERPdbname\";\n");
-			fputs($f,"\$ERPusr[\"Name\"]=\"".$_POST["ERPusrN"]."\";\n");
-			fputs($f,"\$ERPusr[\"ID\"]=\"".$_POST["ERPusrID"]."\";\n");
-			fputs($f,"\$ERPdir=\"".$_POST["ERPdir"]."\";\n");
-			fputs($f,"\$ERPimgdir=\"".$_POST["ERPimgdir"]."\";\n");
-			fputs($f,"\$maxSize=\"".$_POST["maxSize"]."\";\n");
-			fputs($f,"\$ERPftphost=\"".$_POST["ERPftphost"]."\";\n");
-			fputs($f,"\$ERPftpuser=\"".$_POST["ERPftpuser"]."\";\n");
-			fputs($f,"\$ERPftppwd=\"".$_POST["ERPftppwd"]."\";\n");
-			fputs($f,"//Verbindung zur osCommerce-db\n");
-			fputs($f,"\$SHOPuser=\"".$_POST["SHOPuser"]."\";\n");
-			fputs($f,"\$SHOPpass=\"".$_POST["SHOPpass"]."\";\n");
-			fputs($f,"\$SHOPhost=\"".$_POST["SHOPhost"]."\";\n");
-			fputs($f,"\$SHOPdbname=\"".$_POST["SHOPdbname"]."\";\n");
-			fputs($f,"\$SHOPdns=\"mysql://\$SHOPuser:\$SHOPpass@\$SHOPhost/\$SHOPdbname\";\n");
-			fputs($f,"\$SHOPdir=\"".$_POST["SHOPdir"]."\";\n");
-			fputs($f,"\$SHOPimgdir=\"".$_POST["SHOPimgdir"]."\";\n");
-			fputs($f,"\$SHOPftphost=\"".$_POST["SHOPftphost"]."\";\n");
-			fputs($f,"\$SHOPftpuser=\"".$_POST["SHOPftpuser"]."\";\n");
-			fputs($f,"\$SHOPftppwd=\"".$_POST["SHOPftppwd"]."\";\n");
-			fputs($f,"\$div16[\"ID\"]=\"".$_POST["div16ID"]."\";\n");
-			fputs($f,"\$div07[\"ID\"]=\"".$_POST["div07ID"]."\";\n");
-			fputs($f,"\$versand[\"ID\"]=\"".$_POST["versandID"]."\";\n");
-			fputs($f,"\$nachn[\"ID\"]=\"".$_POST["nachnID"]."\";\n");
-			fputs($f,"\$minder[\"ID\"]=\"".$_POST["minderID"]."\";\n");
-			fputs($f,"\$treuh[\"ID\"]=\"".$_POST["treuhID"]."\";\n");
-			fputs($f,"\$paypal[\"ID\"]=\"".$_POST["paypalID"]."\";\n");
-			fputs($f,"\$div16[\"NR\"]=\"".$_POST["div16NR"]."\";\n");
-			fputs($f,"\$div07[\"NR\"]=\"".$_POST["div07NR"]."\";\n");
-			fputs($f,"\$versand[\"NR\"]=\"".$_POST["versandNR"]."\";\n");
-			fputs($f,"\$nachn[\"NR\"]=\"".$_POST["nachnNR"]."\";\n");
-			fputs($f,"\$minder[\"NR\"]=\"".$_POST["minderNR"]."\";\n");
-			fputs($f,"\$treuh[\"NR\"]=\"".$_POST["treuhNR"]."\";\n");
-			fputs($f,"\$paypal[\"NR\"]=\"".$_POST["paypalNR"]."\";\n");
-			fputs($f,"\$div16[\"TXT\"]=\"".$div16txt."\";\n");
-			fputs($f,"\$div07[\"TXT\"]=\"".$div07txt."\";\n");
-			fputs($f,"\$versand[\"TXT\"]=\"".$versandtxt."\";\n");
-			fputs($f,"\$nachn[\"TXT\"]=\"".$nachntxt."\";\n");
-			fputs($f,"\$minder[\"TXT\"]=\"".$mindertxt."\";\n");
-			fputs($f,"\$treuh[\"TXT\"]=\"".$treuhtxt."\";\n");
-			fputs($f,"\$paypal[\"TXT\"]=\"".$paypaltxt."\";\n");
-			fputs($f,"\$bgcol[1]=\"#ddddff\";\n");
-			fputs($f,"\$bgcol[2]=\"#ddffdd\";\n");
-			fputs($f,"\$preA=\"".$_POST["preA"]."\";\n");
-			fputs($f,"\$preK=\"".$_POST["preK"]."\";\n");
-			fputs($f,"\$auftrnr=\"".$_POST["auftrnr"]."\";\n");
-			fputs($f,"\$utftrans=\"".$_POST["utftrans"]."\";\n");
-			fputs($f,"\$kdnum=\"".$_POST["kdnum"]."\";\n");
-			fputs($f,"\$mwst=\"".$_POST["mwst"]."\";\n");
-			fputs($f,"\$pricegroup=\"".$_POST["pricegroup"]."\";\n");
-			fputs($f,"\$unit=\"".$_POST["unit"]."\";\n");
-			fputs($f,"\$showErr=\"true\";\n");
-			fputs($f,"?>");
-			fclose($f);
-			require "conf.php";
-		} else {
-			$ERPuser=$_POST["ERPuser"];
-			$ERPpass=$_POST["ERPpass"];
-			$ERPhost=$_POST["ERPhost"];
-			$ERPdbname=$_POST["ERPdbname"];
-			$ERPusrN=$_POST["ERPusrN"];
-			$ERPdir=$_POST["ERPdir"];
-			$ERPimgdir=$_POST["ERPimgdir"];
-			$maxSize=$_POST["maxSize"];
-			$ERPftphost=$_POST["ERPftphost"];
-			$ERPftpuser=$_POST["ERPftpuser"];
-			$ERPftppwd=$_POST["ERPftppwd"];
-			$SHOPuser=$_POST["SHOPuser"];
-			$SHOPpass=$_POST["SHOPpass"];
-			$SHOPhost=$_POST["SHOPhost"];
-			$SHOPdbname=$_POST["SHOPdbname"];
-			$SHOPdir=$_POST["SHOPdir"];
-			$SHOPimgdir=$_POST["SHOPimgdir"];
-			$SHOPftphost=$_POST["SHOPftphost"];
-			$SHOPftpuser=$_POST["SHOPftpuser"];
-			$SHOPftppwd=$_POST["SHOPftppwd"];
-			$div16NR=$_POST["div16NR"];
-			$div07NR=$_POST["div07NR"];
-			$versandNR=$_POST["versandNR"];
-			$nachnNR=$_POST["nachnNR"];
-			$treuhNR=$_POST["treuhNR"];
-			$minderNR=$_POST["minderNR"];
-			$paypalNR=$_POST["paypalNR"];
-			$preA=$_POST["preA"];
-			$preK=$_POST["preK"];
-			$mwst=empty($_POST["mwst"])?1:$_POST["mwst"];
-			$kdnum=$_POST["kdnum"];
-			$pricegroup=$_POST["pricegroup"];
-			$unit=$_POST["unit"];
-			$auftrnr=$_POST["auftrnr"];
-			$utftrans=$_POST["utftrans"];
-		}
-	}	else {
-		if (file_exists ("conf$login.php")) {
-			require "conf$login.php";
-		} else {
-			require "conf.php";
-		}
-        	$dsnP = array(
-                    'phptype'  => 'pgsql',
-                    'username' => $ERPuser,
-                    'password' => $ERPpass,
-                    'hostspec' => $ERPhost,
-                    'database' => $ERPdbname,
-                    'port'     => $ERPport
-        	);
-		$dbP=@DB::connect($dsnP);
-		if (DB::isError($dbP)||!$dbP) {
-			echo "Keine Verbindung zur ERP<br>";
-			$dbP=false;
-			//echo $dbP->userinfo;
-		}
-	}
-	?>
-<html>
-<body>
-<center>
-<table style="background-color:#cccccc" border="0">
-<form name="ConfEdit" method="post" action="confedit.php">
-<input type="hidden" name="div16ID" value="<?= $div16["ID"] ?>">
-<input type="hidden" name="div07ID" value="<?= $div07["ID"] ?>">
-<input type="hidden" name="minderID" value="<?= $minder["ID"] ?>">
-<input type="hidden" name="versandID" value="<?= $versand["ID"] ?>">
-<input type="hidden" name="nachnID" value="<?= $nachn["ID"] ?>">
-<input type="hidden" name="paypalID" value="<?= $paypal["ID"] ?>">
-<input type="hidden" name="treuhID" value="<?= $treuh["ID"] ?>">
-<input type="hidden" name="ERPusrID" value="<?= $ERPusr["ID"] ?>">
-
-<tr><th>Daten</th><th>Lx-ERP</th><th></th><th>Shop</th></tr>
-<tr>
-	<td>db-Host</td>
-	<td colspan="2"><input type="text" name="ERPhost" size="25" value="<?= $ERPhost ?>"></td>
-	<td><input type="text" name="SHOPhost" size="25" value="<?= $SHOPhost ?>"></td>
-</tr>
-<tr>
-	<td>Database</td>
-	<td colspan="2"><input type="text" name="ERPdbname" size="20" value="<?= $ERPdbname ?>"></td>
-	<td><input type="text" name="SHOPdbname" size="20" value="<?= $SHOPdbname ?>"></td>
-</tr>
-<tr>
-	<td>db-User Name</td>
-	<td colspan="2"><input type="text" name="ERPuser" size="15" value="<?= $ERPuser ?>"></td>
-	<td><input type="text" name="SHOPuser" size="15" value="<?= $SHOPuser ?>"></td>
-</tr>
-<tr>
-	<td>db-User PWD</td>
-	<td colspan="2"><input type="text" name="ERPpass" size="15" value="<?= $ERPpass ?>"></td>
-	<td><input type="text" name="SHOPpass" size="15" value="<?= $SHOPpass ?>"></td>
-</tr>
-<tr>
-	<td>UTF8-Transl.</td>
-	<td colspan="2"><input type="checkbox" name="utftrans" <?= (empty($utftrans)?"":"checked") ?>></td>
-	<td>Preise <input type="radio" name="mwst" value="1" <?= ($mwst==1)?"checked":"" ?>> incl.
-	    <input type="radio" name="mwst" value="0" <?= ($mwst<>1)?"checked":"" ?>> excl. MwSt</td>
-</tr>
-<tr>
-	<td>User-ID</td>
-	<td colspan="2"><input type="text" name="ERPusrN" size="10" value="<?= $ERPusr["Name"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($ERPusr["ID"])?"":"checked") ?>></td>
-	<td></td>
-</tr>
-<tr>
-	<td>CSV-Dir</td>
-	<td colspan="2"><input type="text" name="ERPdir" size="30" value="<?= $ERPdir ?>"></td>
-	<td><input type="text" name="SHOPdir" size="30" value="<?= $SHOPdir ?>"></td>
-</tr>
-<tr>
-	<td>Image-Dir</td>
-	<td colspan="2"><input type="text" name="ERPimgdir" size="30" value="<?= $ERPimgdir ?>"></td>
-	<td><input type="text" name="SHOPimgdir" size="30" value="<?= $SHOPimgdir ?>"></td>
-</tr>
-<tr>
-	<td>FTP-Host</td>
-	<td colspan="2"><input type="text" name="ERPftphost" size="20" value="<?= $ERPftphost ?>"></td>
-	<td><input type="text" name="SHOPftphost" size="20" value="<?= $SHOPftphost ?>"></td>
-</tr>
-<tr>
-	<td>FTP-User</td>
-	<td colspan="2"><input type="text" name="ERPftpuser" size="15" value="<?= $ERPftpuser ?>"></td>
-	<td><input type="text" name="SHOPftpuser" size="15" value="<?= $SHOPftpuser ?>"></td>
-</tr>
-<tr>
-	<td>FTP-User PWD</td>
-	<td colspan="2"><input type="text" name="ERPftppwd" size="15" value="<?= $ERPftppwd ?>"></td>
-	<td><input type="text" name="SHOPftppwd" size="15" value="<?= $SHOPftppwd ?>"></td>
-</tr>
-<tr>
-	<td>ID Diverse 16%</td>
-	<td><input type="text" name="div16NR" size="10" value="<?= $div16["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($div16["ID"])?"":"checked") ?>></td>
-	<td>ID Diverse 7%</td>
-	<td><input type="text" name="div07NR" size="10" value="<?= $div07["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($div07["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Versand</td>
-	<td><input type="text" name="versandNR" size="10" value="<?= $versand["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($versand["ID"])?"":"checked") ?>></td>
-	<td>ID Nachname</td>
-	<td><input type="text" name="nachnNR" size="10" value="<?= $nachn["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($nachn["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Paypal</td>
-	<td><input type="text" name="paypalNR" size="10" value="<?= $paypal["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($paypal["ID"])?"":"checked") ?>></td>
-	<td>ID Treuhand</td>
-	<td><input type="text" name="treuhNR" size="10" value="<?= $treuh["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($treuh["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Mindermenge</td>
-	<td><input type="text" name="minderNR" size="10" value="<?= $minder["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($minder["ID"])?"":"checked") ?>></td>
-	<td></td>	
-</tr>
-<tr>
-	<td>Std-Einheit</td>
-	<td><select name="unit">
-<? unit($unit); ?>
-	    </select></td>
-	<td>Preisgruppe</td>
-	<td><select name="pricegroup">
-<? pg($pricegroup); ?>
-	    </select></td>
-<tr>
-	<td colspan="2">Auftragsnummern durch</td>
-	<td><input type="radio" name="auftrnr" value="1" <?= ($auftrnr==1)?"checked":"" ?>> LxO</td>
-	<td><input type="radio" name="auftrnr" value="0" <?= ($auftrnr<>1)?"checked":"" ?>> Shop</td>
-</tr>
-<tr>
-	<td colspan="2">Kundennummern durch</td>
-	<td><input type="radio" name="kdnum" value="1" <?= ($kdnum==1)?"checked":"" ?>> LxO</td>
-	<td><input type="radio" name="kdnum" value="0" <?= ($kdnum<>1)?"checked":"" ?>> Shop</td>
-</tr>
-<tr>
-	<td colspan="2">Nummernerweiterung</td>
-	<td>Auftrag<input type="text" name="preA" size="5" value="<?= $preA ?>"></td>
-	<td>Kunde<input type="text" name="preK" size="5" value="<?= $preK ?>"></td>
-</tr>
-<!--tr>
-	<td>Bildergr&ouml;sse (byte)</td>
-	<td><input type="text" name="maxSize" size="10" value="<?= $maxSize ?>"></td>
-	<td></td>
-</tr-->
-
-
-
-
-<tr><td colspan="4" align="center"><input type="submit" name="ok" value="sichern"></td></tr>
-</form>
-</table>
-</center>
-</body>
-</html>
-<? } ?>
diff --git a/pepper/diff.php b/pepper/diff.php
deleted file mode 100644
index c4a3a6d31..000000000
--- a/pepper/diff.php
+++ /dev/null
@@ -1,82 +0,0 @@
-<?
-// $Id: diff.php,v 1.1 2004/12/17 13:50:15 hli Exp $
-require_once "DB.php";
-require_once "conf.php";
-if (!$db) {
-	$db=DB::connect($SHOPdns);
-	if (!$db) dbFehler("",$db->getDebugInfo());
-	if (DB::isError($db)) {
-		dbFehler("",$db->getDebugInfo());
-		die ($db->getDebugInfo());
-	};
-	$db2=DB::connect($ERPdns);
-	if (!$db2) dbFehler("",$db2->getDebugInfo());
-	if (DB::isError($db2)) {
-		dbFehler("",$db2->getDebugInfo());
-		die ($db2->getDebugInfo());
-	};
-}
-if ($_POST["ok"]) {
-	$sql="select Kategorie_ID from kategorien where  Unterkategorie_von = '@PhPepperShop@'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$no=$rs[0]["Kategorie_ID"];
-	foreach($_POST as $key=>$val) {
-		if ($key=="ok") continue;
-		if ($key=="alle") continue;
-		$sql="update artikel_kategorie set FK_Kategorie_ID=$no where FK_Artikel_ID=$val";
-		echo "$key ";
-		if ($db->query($sql)) { echo "deaktiviert<br>"; }
-		else { echo "konnte nicht deaktiviert werden<br>"; };
-	}
-} else {
-$sql="select Kategorie_ID from kategorien where  Unterkategorie_von = '@PhPepperShop@'";
-$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($rs) {
-	$no="K.FK_Kategorie_ID<>".$rs[0]["Kategorie_ID"];
-} else {
-	$no="1";
-}
-$sql="select partnumber from parts where shop='1' order by partnumber";
-$erp=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($erp) foreach ($erp as $zeile) { $arE[]=$zeile["partnumber"]; };
-$sql="select Name,Artikel_ID,Artikel_NR from artikel A left join artikel_kategorie K on A.Artikel_ID=K.FK_Artikel_ID where $no";
-$shop=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-if ($shop) foreach ($shop as $zeile) {
-	$arS[]=$zeile["Artikel_NR"];
-	$arID[$zeile["Artikel_NR"]]=array("id"=>$zeile["Artikel_ID"],"name"=>$zeile["Name"]);
-}
-$result=@array_diff($arS,$arE);
-if ($result) {
-?>
-<html>
-<head><title>Artikelpflege</title>
-<script language="JavaScript">
-<!--
-	function sel() {
-		val=document.doppel.alle.checked;
-		cnt=document.doppel.length;
-		for (i=0; i<cnt; i++) {
-			document.doppel.elements[i].checked=val;
-		}
-	}
-//-->
-</script>
-</head>
-<body>
-Folgende Artikel sind in der ERP nicht mehr als Shopartikel markiert.<br>
-Markieren Sie die Artikel, die deaktiviert werden sollen.<br>
-<form name='doppel' method='post' action='diff.php'>
-<table>
-<?
-foreach ($result as $data) {
-	echo "\t<tr><td><input type='checkbox' name='".$data."' value='".$arID[$data]["id"]."'></td><td>".$data."</td><td>".$arID[$data]["name"]."</td></tr>\n";
-}
-?>
-	<tr><td><input type='checkbox' name='alle' value='1' onClick="sel()"></td><td></td><td>alle Artikel</td></tr>
-	<tr><td colspan='3'><input type='submit' name='ok' value='ok'></td></tr>
-</table>
-<form>
-<? }
-	else { "Artikelbestand identisch"; };
-} ?>
-<a href="trans.php">zur&uuml;ck</a>
diff --git a/pepper/e2c.gif b/pepper/e2c.gif
deleted file mode 100644
index 692eb8b87..000000000
Binary files a/pepper/e2c.gif and /dev/null differ
diff --git a/pepper/e2s.gif b/pepper/e2s.gif
deleted file mode 100644
index 1227d9801..000000000
Binary files a/pepper/e2s.gif and /dev/null differ
diff --git a/pepper/erpexport.php b/pepper/erpexport.php
deleted file mode 100644
index 8cbd711c5..000000000
--- a/pepper/erpexport.php
+++ /dev/null
@@ -1,216 +0,0 @@
-<?
-/***************************************************************
-* $Id: erpexport.php  2006/02/06 13:50:30 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.1
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-?>
-<html>
-	<head><title>Lx-ERP Export der Shopartikel</title>
-	<link type="text/css" REL="stylesheet" HREF="css/main.css"></link>
-	<script language="JavaScript">
-	<!--
-		function pepper() {
-			document.fld.PN.value="Artikel-Nr"; document.fld.partnumber.checked=true;
-			document.fld.BEZ.value="Name"; document.fld.desctiption.checked=true;
-			document.fld.GEWICHT.value="Gewicht"; document.fld.weight.checked=true;
-			document.fld.MWST.value="MwSt-Satz"; document.fld.rate.checked=true;
-			document.fld.VK.value="Preis"; document.fld.sellprice.checked=true;
-			document.fld.PG.value="Kategorien"; document.fld.partsgroup.checked=true;
-			document.fld.BESCHR.value="Beschreibung"; document.fld.notes.checked=true;
-			document.fld.PG.value="Lagerbestand"; document.fld.onhand.checked=true;
-			document.fld.encl.value="";
-			document.fld.deli.value=";";
-			document.fld.crln.value="\\n";
-			document.fld.head.checked=true;
-			document.fld.shop.value="pepper";
-		}
-	//-->
-	</script>
-<body>
-
-<?php
-require_once "DB.php";
-require_once "conf.php";
-
-$db=DB::connect($ERPdns);
-if (!$db) dbFehler("",$db->getDebugInfo());
-if (DB::isError($db)) {
-	dbFehler("",$db->getDebugInfo());
-	die ($db->getDebugInfo());
-};
-/****************************************************
-* dbFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function dbFehler($sql,$err) {
-global $showErr;
-	if ($showErr)
-		echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-
-function shopartikel() {
-global $db;
-	$sql ="SELECT P.partnumber,P.description,P.unit,P.weight,t.rate,P.sellprice,P.listprice,P.priceupdate,PG.partsgroup,P.notes,P.image FROM ";
-	$sql.="parts P left join partsgroup PG on  PG.id=P.partsgroup_id ";
-	$sql.="left join chart c on c.id = P.income_accno_id ";
-	$sql.="left join tax T on T.taxkey=C.taxkey_id ";
-	$sql.="where shop = 't'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	return $rs;
-}
-if ($_POST["export"]) {
-	$data=shopartikel();
-	$delim=($_POST["deli"])?$_POST["deli"]:",";
-	if (get_magic_quotes_gpc()) {
-		$crln = stripslashes($_POST["crln"]);
-	}
-	$crln = str_replace('\\r', "\015", $crln);
-	$crln = str_replace('\\n', "\012", $crln);
-	$crln = str_replace('\\t', "\011", $crln);
-	$encl=$_POST["encl"];
-	$i=0;
-	$f=fopen($ERPdir,"w");
-	if ($_POST["partnumber"])	{$header.=$_POST["PN"].$delim; };
-	if ($_POST["desctiption"])	{$header.=$_POST["BEZ"].$delim; };
-	if ($_POST["unit"])			{$header.=$_POST["EINHEIT"].$delim; };
-	if ($_POST["weight"])		{$header.=$_POST["GEWICHT"].$delim; };
-	if ($_POST["onhand"])		{$header.=$_POST["LAGER"].$delim; };
-	if ($_POST["rate"])			{$header.=$_POST["MWST"].$delim; };
-	if ($_POST["sellprice"])	{$header.=$_POST["VK"].$delim; };
-	if ($_POST["listprice"])	{$header.=$_POST["EK"].$delim; };
-	if ($_POST["priceupdate"])	{$header.=$_POST["PDATE"].$delim; };
-	if ($_POST["partsgroup"])	{$header.=$_POST["PG"].$delim; };
-	if ($_POST["notes"])		{$header.=$_POST["BESCHR"].$delim; };
-	if ($_POST["image"])		{$header.=$_POST["IMAGE"].$delim; };
-	$header=substr($header,0,-1);
-?>
-<table class="liste">
-<!-- BEGIN Artikel -->
-<?
-function downloadImage($image,$name) {
-global $ERPftphost,$ERPftpuser,$ERPftppwd,$ERPimgdir, $maxSize, $iconSize;
-	$conn_id = ftp_connect($ERPftphost);
-	ftp_login($conn_id,$ERPftpuser,$ERPftppwd);
-	$src=$ERPimgdir."/".$image;
-	$typ=substr($image,strrpos($image,"."));
-	echo "tmp/".$name."_gr$typ $src";
-	$upload=ftp_get($conn_id,"tmp/".$name."_gr$typ","$src",FTP_BINARY);
-	ftp_quit($conn_id);
-	if (!$upload) { echo "Ftp download war fehlerhaft!"; return false; };
-	echo "convert  -resize $iconSize tmp/".$name."_gr$typ tmp/".$name."_kl$typ";
-	exec("convert  -resize $iconSize tmp/".$name."_gr$typ tmp/".$name."_kl$typ",$aus,$rc);
-	print_r($aus); echo "!$rc!";
-}
-	$i=0;
-	$f=fopen($ERPdir,"w");
-	if ($_POST["head"]) fputs($f,$header.$crln);
-	foreach($data as $zeile) {
-		$file=""; $html="";
-		if ($_POST["shop"]=="pepper") {
-			if (preg_match("/^\[.*\].*/",$zeile["partsgroup"])) { $PG=$zeile["partsgroup"]; }
-			else { $PG="[".$zeile["partsgroup"]."]"; };
-			$mwst=$zeile["rate"]*100;
-		} else if ($_POST["shop"]=="oscomm") {
-			$mwst=sprintf("%01.4f",($zeile["rate"]*100));
-			$PG=$zeile["partsgroup"];
-		} else {
-			$PG=$zeile["partsgroup"];
-			$mwst=$zeile["rate"]*100;
-		};
-		$LineCol = $bgcol[$i%2+1];
-		if ($_POST["partnumber"])	{$file.=$encl.$zeile["partnumber"].$encl.$delim; $html.="<td>".$zeile["partnumber"]."</td>";};
-		if ($_POST["desctiption"])	{$file.=$encl.strtr($zeile["description"],chr(13).chr(10),"  ").$encl.$delim; $html.="<td>".$zeile["description"]."</td>";};
-		if ($_POST["unit"])			{$file.=$encl.$zeile["unit"].$encl.$delim; $html.="<td>".$zeile["unit"]."</td>";};
-		if ($_POST["onhand"])			{$file.=$encl.$zeile["onhand"].$encl.$delim; $html.="<td>".$zeile["onhand"]."</td>";};
-		if ($_POST["weight"])		{$file.=$encl.$zeile["weight"].$encl.$delim; $html.="<td>".$zeile["weight"]."</td>";};
-		if ($_POST["rate"])			{$file.=$encl.$mwst.$encl.$delim; $html.="<td>".$mwst."</td>";};
-		if ($_POST["sellprice"])	{$file.=$encl.(sprintf("%02.2f",$zeile["sellprice"])).$encl.$delim; $html.="<td>".(sprintf("%02.2f",$zeile["sellprice"]))."</td>";};
-		if ($_POST["listprice"])	{$file.=$encl.(sprintf("%02.2f",$zeile["listprice"])).$encl.$delim; $html.="<td>".(sprintf("%02.2f",$zeile["listprice"]))."</td>";};
-		if ($_POST["priceupdate"])	{$file.=$encl.$zeile["priceupdate"].$encl.$delim; $html.="<td>".$zeile["priceupdate"]."</td>";};
-		if ($_POST["partsgroup"])	{$file.=$encl.$PG.$encl.$delim; $html.="<td>".$zeile["partsgroup"]."</td>";};
-		if ($_POST["notes"])		{$file.=$encl.strtr($zeile["notes"],chr(13).chr(10),"  ").$encl.$delim; $html.="<td>".$zeile["notes"]."</td>";};
-		if ($_POST["image"])		{$file.=$encl.$zeile["image"].$encl.$delim; $html.="<td>".$zeile["image"]."</td>";};
-		$i++;
-		fputs($f,substr($file,0,-1).$crln);
-		if ($zeile["image"] && $_POST["image"]) { downloadImage($zeile["image"],$zeile["partnumber"]); }
-		if ($_POST["show"]) {
-?>
-	<tr  class="smal" onMouseover="this.bgColor='#FF0000';" onMouseout="this.bgColor='<?= $LineCol ?>';" bgcolor="<?= $LineCol ?>">
-		<?= $html ?>
-	</tr>
-<? 		}
-	}
-?>
-<!-- END Artikel -->
-</table>
-Anzahl der Artikel: <?= $i ?><br>
-Export am : <?= date("d.m.Y : H:i") ?><br>
-download <a href="tmp/shopartikel.csv">Exportfile</a><br><hr>
-<?
-	fclose($f);
-} // if ($export)
-?>
-Export der Shopartikel aus Lx-ERP <br>
-M&ouml;gliche Felder
-<form name="fld" action="erpexport.php" method="post">
-<input type="hidden" name="shop" value="">
-<table>
-	<tr>
-		<td><input type="checkbox" name="partnumber" value="1">Artikelnummer</td>
-		<td><input type="checkbox" name="desctiption" value="1">Bezeichnung</td>
-		<td><input type="checkbox" name="unit" value="1">Einheit</td>
-		<td><input type="checkbox" name="weight" value="1">Gewicht</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="PN" size="23"></td>
-		<td><input type="text" name="BEZ" size="23"></td>
-		<td><input type="text" name="EINHEIT" size="23"></td>
-		<td><input type="text" name="GEWICHT" size="23"></td>
-	</tr>
-	<tr><td colspan=5></td></tr>
-	<tr>
-		<td><input type="checkbox" name="sellprice" value="1">Verkaufspreis</td>
-		<td><input type="checkbox" name="listprice" value="1">Listenpreis</td>
-		<td><input type="checkbox" name="onhand" value="1">Lagerbestand</td>
-		<td><input type="checkbox" name="rate" value="1">MwSt</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="VK" size="23"></td>
-		<td><input type="text" name="EK" size="23"></td>
-		<td><input type="text" name="LAGER" size="23"></td>
-		<td><input type="text" name="MWST" size="23"></td>
-	</tr>
-	<tr><td colspan=5></td></tr>
-	<tr>
-		<td><input type="checkbox" name="partsgroup" value="1">Gruppe</td>
-		<td><input type="checkbox" name="notes" value="1">Beschreibung</td>
-		<td><input type="checkbox" name="image" value="1">Bild</td>
-		<td><input type="checkbox" name="show" value="1" checked>HTML-Anzeige</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="PG" size="23"></td>
-		<td><input type="text" name="BESCHR" size="23"></td>
-		<td><input type="text" name="IMAGE" size="23"></td>
-		<td></td>
-	</tr>
-	<tr>
-		<td>Feldtrenner <input type="text" name="deli" size="2" value=","></td>
-		<td>Feldumrahmung <input type="text" name="encl" size="2" value="&quot;"></td>
-		<td>Zeilenende <input type="text" name="crln" size="2" value="\n"></td>
-		<td><input type="checkbox" name="head" value="1" checked>Headline</td>
-	</tr>
-	<tr>
-		<td colspan=5><input type="submit" name="export" value="Export"> <input type="button" name="pep" value="Peppershop" onClick="pepper()"> <input type="button" name="osc" value="osCommerce" onClick="oscomm()"></td>
-	</tr>
-</table>
-<a href="trans.php">zur&uuml;ck</a>
-</form>
-</body>
-</html>
diff --git a/pepper/export_to_erp/export_to_erp.php b/pepper/export_to_erp/export_to_erp.php
deleted file mode 100644
index b5d832320..000000000
--- a/pepper/export_to_erp/export_to_erp.php
+++ /dev/null
@@ -1,291 +0,0 @@
-<?
-/***************************************************************
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.1
-*Shop: PHPeppershop 1.5
-*ERP: kivitendo ERP
-***************************************************************/
-// -----------------------------------------------------------------------
-// Damit jedes andere Modul ueberpruefen kann ob dieses hier schon "included" ist
-// wird folgende Vairable auf true gesetzt (Name = Ext. Modulname + Dateiname ohne .php)
-$erp_export_erp_export = true;
-
-?>
-<html>
-	<head><title>Lx-ERP Export der Shopartikel</title>
-	<link type="text/css" REL="stylesheet" HREF="css/main.css"></link>
-	<script language="JavaScript">
-	<!--
-		function pepper() {
-		}
-	//-->
-	</script>
-<body>
-
-<?php
-$inip=get_cfg_var("include_path");
-ini_set("include_path",$inip.":/usr/share/pear/:.");
-
-require_once "DB.php";
-require_once "conf.php";
-
-$db=DB::connect($SHOPdns);
-if (!$db) dbFehler("",$db->getDebugInfo());
-if (DB::isError($db)) {
-	dbFehler("",$db->getDebugInfo());
-	die ($db->getDebugInfo());
-};
-$db2=DB::connect($ERPdns);
-if (!$db2) dbFehler("",$db2->getDebugInfo());
-if (DB::isError($db2)) {
-	dbFehler("",$db2->getDebugInfo());
-	die ($db2->getDebugInfo());
-};
-/****************************************************
-* dbFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function dbFehler($sql,$err) {
-global $showErr;
-	if ($showErr)
-		echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-function checkBestellung($status) {
-global $db;
-	if ($status=="B") { $where="";}  // B = alle Bestellungeb, N = neue, Y = alte
-	else { $where="where Bestellung_bezahlt = '$status'";}
-	$sql="select * from bestellung $where order by Datum";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	return (count($rs)>0)?count($rs):false;
-}
-function getBestellKunde($BID) {
-global $db;
-	$sql="select * from kunde left join bestellung_kunde on Kunden_ID=FK_Kunden_ID where  FK_Bestellungs_ID=$BID";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	return $rs[0]["Kunden_Nr"];
-}
-function sonderkosten($transID,$data,$id,$f) {
-global $db2,$versand,$nachn,$minder,$treuh,$paypal;
-	$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-	$sql.=$transID.",".${$id}["ID"].",'".${$id}["TXT"]."',1,".$data.",'mal',0,0)";
-	fputs($f,"$transID,".${$id}["ID"].",'".${$id}["TXT"]."',1,$data\n");
-	if (!$db2->query($sql)) { return false; }
-	else { return true; };
-}
-function insBestArtikel($zeile,$transID) {
-global $db,$db2,$div07,$div16,$f,
-	$versandID,$nachnID,$minderID,$treuhID,$paypalID;
-	$BID=$zeile["Bestellungs_ID"];
-	$sql ="select * from artikel left join artikel_bestellung on Artikel_ID=FK_Artikel_ID ";
-	$sql.="left join bestellung on Bestellungs_ID=FK_Bestellungs_ID where Bestellungs_ID=$BID";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$ok=true;
-	foreach ($rs as $zeile) {
-		$sql="select * from parts where partnumber='".$zeile["Artikel_Nr"]."'";
-		$rs2=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ( $rs2[0]["id"]) {$artID=$rs2[0]["id"]; }
-		else { $artID=($zeile["MwSt_Satz"]=="7")?$div07["ID"]:$div16["ID"]; };
-		//$preis=round($zeile["Preis"]/($zeile["MwSt_Satz"]+100)*100,2);
-		$preis=$zeile["Preis"];
-		$notes=$zeile["Artikelname"];
-		$vari=split(chr(254),$zeile["Variation"]);
-		if ($vari) { for($cnt=0; $cnt<count($vari); $cnt++) {
-				$notes.="\n".$vari[$cnt];
-				$cnt++;
-				$preis+=trim($vari[$cnt]) * $zeile["Anzahl"];
-			}
-		};
-		$opts=split(chr(254),$zeile["Optionen"]);
-		if ($opts) { for($cnt=0; $cnt<count($opts); $cnt++) {
-				$notes.="\n".$opts[$cnt];
-				$cnt++;
-				$preis+=trim($opts[$cnt]) * $zeile["Anzahl"];
-			}
-		}		
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$transID.",".$artID.",'".$notes."',".$zeile["Anzahl"].",".$preis.",'Stck',0,0)";
-		if (!$db2->query($sql)) { $ok=false; break; };
-		fputs($f,$transID.",".$artID.",'".$zeile["Artikelname"]."',".$zeile["Anzahl"].",".$preis."\n");
-		echo "-".$artID." ".$zeile["Anzahl"]." x ".$preis." ".$zeile["Artikelname"]."<br>";
-	}
-	if ($zeile["Versandkosten"]) {
-		$rc=sonderkosten($transID,$zeile["Versandkosten"],"versand",$f);
-	}
-	if ($zeile["Nachnamebetrag"]) {
-		$rc=sonderkosten($transID,$zeile["Nachnamebetrag"],"nachn",$f);
-	}	
-	if ($zeile["Mindermengenzuschlag"]) {
-		$rc=sonderkosten($transID,$zeile["Mindermengenzuschlag"],"minder",$f);
-	}	
-	if ($zeile["Treuhandkosten"]) {
-		$rc=sonderkosten($transID,$zeile["Treuhandkosten"],"treuh",$f);
-	}	
-	if ($zeile["Paypalkosten"]) {
-		$rc=sonderkosten($transID,$zeile["Paypalkosten"],"paypal",$f);
-	}	
-	if ($ok) {
-		$sql="update bestellung set Bestellung_bezahlt='Y' WHERE Bestellungs_ID =$BID";
-		$rc=$db->query($sql);
-		fputs($f,"ok\n");
-		return true;
-	} else {
-		$sql="delete from orderitems where trans_id=$transID";
-		$rc=$db->query($sql);
-		$sql="delete from oe where id=$transID";
-		$rc=$db->query($sql);
-		fputs($f,"Fehler (insBestArtikel)!!!!\n");
-		return false;
-	}
-}
-function getBestellung_() {
-global $db,$db2,$ERPusr,$f;
-	$sql="select * from bestellung where Bestellung_bezahlt='N' order by Bestellungs_ID";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$ok=true;
-	foreach ($rs as $zeile) {
-		$kdnr=getBestellKunde($zeile["Bestellungs_ID"]);
-		$newID=uniqid (rand());
-		$sql="insert into oe (notes) values ('$newID')";
-		$rc=$db2->query($sql);
-		$sql="select * from oe where notes = '$newID'";
-		$rs2=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-		$Bezahlung=$zeile["Bezahlungsart"];
-		if ($Bezahlung=="Lastschrift") {
-			$sql="select * from kunde where Kunden_Nr=$kdnr";
-			$kd=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-			$Bezahlung.="\nKontoinhaber: ".$kd[0]["kontoinhaber"]."\n";
-			$Bezahlung.="Bankname: ".$kd[0]["bankname"]."\n";
-			$Bezahlung.="Blz: ".$kd[0]["blz"]."\n";
-			$Bezahlung.="KontoNr: ".$kd[0]["kontonummer"];
-		}
-		$sql ="update oe set ordnumber=".$zeile["Bestellungs_ID"].", transdate='".$zeile["Datum"]."', intnotes='".$zeile["Anmerkung"];
-		$sql.="', customer_id=$kdnr, amount=".($zeile["Rechnungsbetrag"]+$zeile["MwSt"]).", netamount=".$zeile["Rechnungsbetrag"];
-		$sql.=", reqdate='".$zeile["Datum"]."', notes='$Bezahlung', taxincluded='f', curr='EUR',employee_id=".$ERPusr["ID"].", vendor_id=0 ";
-		$sql.="where id=".$rs2[0]["id"];
-		$rc=$db2->query($sql);
-		fputs($f,"ordnumber=".$zeile["Bestellungs_ID"].", transdate='".$zeile["Datum"]."', customer_id=$kdnr, amount=".($zeile["Rechnungsbetrag"]+$zeile["MwSt"]).", notes=".$zeile["Bezahlungsart"]."\n");
-		echo $rs2[0]["id"]."<br>";
-		if (!insBestArtikel($zeile,$rs2[0]["id"])) { $ok=false; break; };
-	}
-	return $ok;
-}
-function chkKdData($data) {
-global $db2;
-	$sql="select * from customer where id = ".$data["Kunden_Nr"];
-	$rs=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs[0]["zipcode"]<>$data["Plz"]) $set.="zipcode='".$data["Plz"]."',";
-	if ($rs[0]["city"]<>$data["Ort"]) $set.="city='".$data["Ort"]."',";
-	if ($rs[0]["land"]<>$data["Land"]) $set.="land='".$data["Land"]."',";
-	if ($rs[0]["phone"]<>$data["Tel"])$set.="phone='".$data["Tel"]."',";
-	if ($rs[0]["fax"]<>$data["Fax"])  $set.="fax='".$data["Fax"]."',";
-	if ($rs[0]["email"]<>$data["Email"])$set.="email='".$data["Email"]."',";
-	if ($rs[0]["notes"]<>$data["Beschreibung"])$set.="notes='".$data["Beschreibung"]."',";
-	if ($data["Firma"]) {
-		if ($rs[0]["name"]<>$data["Firma"]) $set.="set name='".$data["Firma"]."',";
-		if ($rs[0]["name2"]<>$data["Anrede"]." ".$data["Vorname"]." ".$data["Nachname"]) $set.="name2='".$data["Anrede"]." ".$data["Vorname"]." ".$data["Nachname"]."',";
-	} else {
-		if ($rs[0]["name"]<>$data["Nachname"].", ".$data["Vorname"]) $set.="set name='".$data["Nachname"].", ".$data["Vorname"]."',";
-	}
-	if ($data["Strasse"]) {
-		if ($rs[0]["street"]<>$data["Strasse"]) $set.="street='".$data["Strasse"]."',";
-	} else if ($data["Postfach"]) {
-		if ($rs[0]["street"]<>$data["Postfach"]) $set.="street='".$data["Postfach"]."',";
-	};
-	if ($set) {
-		$sql="update customer set ".substr($set,0,-1)." where id=".$rs[0]["id"];
-		$rc=$db2->query($sql);
-	}
-}
-function insKdData($data) {
-global $db2;
-	$newID=$data["Kunden_ID"];
-	$sql="insert into customer (name) values ('$newID')";
-	$rc=$db2->query($sql);
-	$sql="select * from customer where name = '$newID'";
-	$rs=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($data["Firma"]) { $set.="set name='".$data["Firma"]."',name2='".$data["Anrede"]." ".$data["Vorname"]." ".$data["Nachname"]."',"; }
-	else { $set.="set name='".$data["Nachname"].", ".$data["Vorname"]."',"; }
-	if ($data["Strasse"]) { $set.="street='".$data["Strasse"]."',"; }
-	else if ($data["Postfach"]) { $set.="street='".$data["Postfach"]."',"; };
-	$set.="zipcode='".$data["Plz"]."',";
-	$set.="city='".$data["Ort"]."',";
-	$set.="land='".$data["Land"]."',";
-	$set.="phone='".$data["Tel"]."',";
-	$set.="fax='".$data["Fax"]."',";
-	$set.="email='".$data["Email"]."',";
-	$set.="notes='".$data["Beschreibung"]."',";
-	$set.="taxincluded='f' ";
-	$sql="update customer ".$set;
-	$sql.="where id=".$rs[0]["id"];
-	$rc=$db2->query($sql);
-	return $rs[0]["id"];
-}
-function checkKunde() {
-global $db,$f;
-	$sql="select * from kunde left join bestellung_kunde on FK_Kunden_ID=Kunden_ID left join bestellung on Bestellungs_ID=FK_Bestellungs_ID where Bestellung_bezahlt='N'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$ok=true;
-	$anzahl=count($rs);
-	$neu=0; $old=0;
-	foreach ($rs as $zeile) {
-		if ($zeile["Kunden_Nr"]>0) {
-			chkKdData($zeile);
-			$old++;
-		} else {
-			$zeile["Kunden_Nr"]=insKdData($zeile);
-			if ($zeile["Kunden_Nr"]>0) {
-				$sql="update kunde set Kunden_Nr='".$zeile["Kunden_Nr"]."' where k_ID=".$zeile["k_ID"];
-				$rc=$db->query($sql);
-			} else {
-				$ok=false; break;
-			}
-			$neu++;
-		}
-		fputs($f,$zeile["Nachname"]." ".$zeile["Firma"]."\n");
-		fputs($f,"\n----------------------------------------\n\n");
-	}
-	return ($ok)?array($anzahl,$neu,$old):false;
-}
-
-function savedata($str) {
-global $f;
-	foreach ($str as $val) {
-		$str.=$val.",";
-	}
-	fputs($f,substr($str,0,-1)."\n");
-}
-
-$f=fopen("./module/export_to_erp/tmp/".date("y-m-dH:i").".shop","w");
-$ok=checkBestellung("N");
-if ($ok) {
-	echo "Es liegen $ok Bestellungen vor. <br>";
-	fputs($f,"Es liegen $ok Bestellungen vor. \n");
-	$ok=checkKunde();
-	if ($ok) {
-		echo $ok[0]." Kunden, davon ".$ok[1]." neue(r) Kunde(n).<br>";
-		fputs($f,$ok[0]." Kunden, davon ".$ok[1]." neue(r) Kunde(n).\n");
-		$ok=getBestellung_();
-		if ($ok) { echo "Daten transferiert!";  fputs($f,"Daten transferiert!\n");}
-		else { echo "Fehler (Bestellungen)! ! ! ";   fputs($f,"Fehler (Bestellungen)! ! !\n");};
-	} else {
-		 echo "Fehler (Kunden)! ! ! ";   fputs($f,"Fehler (Kunden)! ! !\n");
-	}
-} else { echo "Keine Bestellungen!<br>";  fputs($f,"keine Bestellungen\n");};
-
-fclose($f);
-
-if ($backlink == 6) {
-    echo "<button type='button' onClick='self.location.href=\"./module_admin_aufruf.php?darstellen=6\"'>Zur&uuml;ck zur Moduladministration</button>";
-}
-else {
-    echo "<button type='button' onClick='self.location.href=\"./module_admin_aufruf.php?darstellen=1&".urlencode($window_source)."=".urlencode($previous_selected_module)."\"'>Zur&uuml;ck zur Modulverwaltung</button>";
-}
-
-?>
-</body>
-</html>
diff --git a/pepper/export_to_erp/initialize_module.php b/pepper/export_to_erp/initialize_module.php
deleted file mode 100644
index 5cb9ddb7e..000000000
--- a/pepper/export_to_erp/initialize_module.php
+++ /dev/null
@@ -1,253 +0,0 @@
-<?php
-// Filename: initialize_module.php
-//
-// Modul: Externes PhPepperShopmodul: log_viewer
-//
-// Autoren: Jos� Fontanil & Reto Glanzmann
-//
-// Zweck: Definition des Log-Viewer Moduls
-//
-// Sicherheitsstatus:                     *** ADMIN ***
-//
-// Version: 1.5
-//
-// CVS-Version / Datum: $Id: initialize_module.php,v 1.1 2004/06/29 08:47:16 hli Exp $ $Dl: 26.05.04 11:20:43$
-//
-// -----------------------------------------------------------------------
-// PhPepperShop Shopsystem
-// Copyright (C) 2001-2004  Jose Fontanil, Reto Glanzmann
-// 
-// Lizenz
-// ======
-// 
-// Die verbindliche PhPepperShop Lizenz ist in folgender 
-// Datei definiert: PhPepperShop_license.txt
-// -----------------------------------------------------------------------
-// API Version der hier verwendeten PhPepperShop Modulschnittstelle:
-$pps_module_api = '1.0';
-
-// Informationen zu externen PhPepperShop Modulen:
-// ===============================================
-// Module bestehen meistens aus zwei Verzeichnissen: {shopdir}/shop/module/modul_name
-// und {shopdir}/shop/Admin/module/modul_name. Im Admin-Modulverzeichnis muss mindestens
-// diese Datei (initialize_module.php) vorhanden sein. Es gibt auch reine Administrations-
-// module, welche nur Dateien im Admin-Unterverzeichnis haben und keine Dateien im kunden-
-// seitigen Verzeichnis benoetigen.
-// - Ein Modul kann aber ohne weiteres auch eigene Unterverzeichnisse besitzen, sowie auch
-//   Submodule haben.
-// - Damit Module Daten persistent speichern koennen, duerfen sie waehrend der Installation
-//   eigene Tabellen erstellen und bestehende um eigene Attribute erweitern. Bei einer De-
-//   installation werden diese Datenbankerweiterungen wieder entfernt.
-// - User-Security Scripte befinden sich in {shopdir}/shop/module/modul_name,
-//   die Admin-Security-Scripts befinden sich im Admin-Pendant.
-// - Module koenne (zumindest im Moment) noch keine eigenen Interfaces haben.
-// - Module koennen weitere Module als Voraussetzung angeben.
-
-// Definition der Variablen:
-// =========================
-// Die weiter unten definierten Variablen dienen der Beschreibung des Moduls. Diese muss
-// sehr ausfuehrlich sein, damit das automatisierte Installations- und Deinstallationsscript
-// durchlaufen kann. Nomenklatur:
-// x.) Bezeichnung    : Leitet eine weitere Definition ein. x ist eine Laufnummer
-// ! Beschreibung     : Beschreibung umschreibt Hinweise zum Thema der Bezeichnung
-// --> Einschraenkung : Mit --> werden ZWINGEND ZU BEFOLGENDE Einschraenkungen der Bezeichnung genannt
-
-// --------------------------------------------------------------------------------------
-// ******************************* DEFINITION DES MODULS *******************************
-// --------------------------------------------------------------------------------------
-
-//  1.) Name des Moduls (entspricht dem Verzeichnisname des Moduls)
-//      --> Der Name eines externen PhPepperShop Moduls darf hoechstens 40 Zeichen lang sein.
-//      --> Der Name muss mindestens 3 Zeichen lang sein.
-//      --> Er darf NUR aus alphanummerischen Zeichen und dem Underscore Zeichen (_) bestehen.
-//      --> Dieser Name ist gleichzeitig auch der Name des Verzeichnisses des Moduls.
-$moduldef['modulname'] = 'export_to_erp';
-
-// 2.) Bezeichnung des Moduls
-//      ! Dies ist die Bezeichnung des Moduls und unterliegt somit weniger Restriktionen als der Modulname
-//      --> Der Name darf hoechstens 40 Zeichen lang sein
-//      --> Der Name muss mindestens 3 Zeichen lang sein.
-$moduldef['modulbezeichnung'] = 'ERP Export';
-
-// 3.) Versionschecknummern
-//      ! Diese Nummern definieren die zu verwendende PhPepperShop Versionen. Die Versionisierung
-//        ist wie folgt: Die erste und zweite Nummer (durch Punkt getrennt) ergeben ein Release.
-//        Jedes unterstuetzte Release muss explizit angegeben werden. Die dritte (durch einen
-//        Punkt getrennte Nummer (eigentlich ein String), definiert Versionen des Releases. Alle
-//        Versionen eines Releases sind kompatibel, es sei denn man definiert auch die Versions-
-//        Nummer, dann sind alle aelteren Versionen des angegebenen Releases inkompatibel.
-//        Bsp. 1.4;1.5     = Das Modul ist kompatibel zu den Releases 1.4 und 1.5. Dies schliesst auch
-//                           alle Versionen der beiden Releases mit ein: 1.4.003, 1.4.004, 1.5.1, ...
-//        Bsp. 1.4.005;1.5 = Hier sind alle Versionen von 1.4 mit und nach 1.4.005 kompatibel und
-//                           alle Versionen von 1.5.
-//      ! Achtung: Man sollte keine zukuenftigen Releases angeben!
-//      --> Einzelne Versionen via Strichpunkt getrennt eingeben.
-$moduldef['versionschecknummern'] = '1.4.008;1.5';
-
-//  4.) Kurzbeschreibung
-//      ! Formatierungen sollen via HTML-Tags eingegeben werden.
-$moduldef['kurzbeschreibung'] = 'Eportiert Kundendaten und Bestellungen f&uuml;r kivitendo ERP.
-				 Neukunden werden in der ERP angelegt und die ERP-KdNr in Kundendaten eingepflegt,
-				 bei Bestandskunden werden die Kundendaten abgeglichen.
-				 Das Feld "Bestellung_bezahlt" ist der Merker f&uuml;r neue Bestellungen.
-                                ';
-
-//  5.) Weiterfuehrender Link
-//      ! Wenn dieser (optionale) Link angegeben ist, so kann der Shopadmin hier weitere Infos zum Modul holen.
-//      --> Das Schema muss vor der URL angegeben werden (Schema = http:// oder https://, ...)
-$moduldef['weitere_infos_link'] = 'http://www.lx-office.org/';
-
-//  6.) Version dieses Moduls
-$moduldef['modulversion'] = '0.3';
-
-//  7.) Releasedatum dieser Modulversion
-//      --> Format: TT.MM.JJJJ
-$moduldef['releasedatum'] = '17.12.2004';
-
-//  8.) Informationen zu den Entwicklern
-//      ! Beispiel: Jos� Fontanil <fontajos@phpeppershop.com>. Strings in <> werden als E-Mail angezeigt.
-$moduldef['entwickler_infos'] = 'Holger Lindemann, Lx-System';
-
-//  9.) Ist Submodul von
-//      ! Hier kann man den Modulnamen (nicht die Modulbezeichnung!) des Hauptmoduls angeben, falls dieses
-//        Modul hier ein Submodul des Hauptmoduls ist.
-//      --> Der Name eines externen PhPepperShop Moduls darf hoechstens 40 Zeichen lang sein.
-//      --> Der Name muss mindestens 3 Zeichen lang sein.
-//      --> Er darf nur aus alphanummerischen Zeichen und dem Underscore Zeichen (_) bestehen.
-//      --> Dieser Name ist gleichzeitig auch der Name des Verzeichnisses des HAUPTmoduls.
-$moduldef['submodule_of'] = '';
-
-// 10.) Fingerprint
-//      ! Im Moment noch nicht benutzt - Spaeter wird hier ein MD5 Digest hinterlegbar sein, welcher dem
-//        Shopadministrator erlaubt die Integritaet eines Moduls zu ueberpruefen.
-//      --> MD5 Digest (32 Chars Laenge, Hexadezimales Alphabet)
-$moduldef['fingerprint'] = '32fedef6229faab095a47718bac5d666';
-
-// 11.) Unterstuetzte Locales (Sprachen und optional Laender) - dient (vorerst) nur zur Anzeige fuer den Shopadmin
-//      --> Format: ISO-639-1 fuer alleinstehende Sprachen (Bsp. de;en;fr;sp;...)
-//      --> Format: ISO-639-2 fuer Sprachen inkl. Laender (Bsp. de_CH;de_DE;en_GB;en_US)
-//      --> Wenn das Modul weder Sprach-, noch Laenderabhaengig ist kann all angegeben werden.
-//      --> Die einzelnen Angaben koennen Strichpunkt separiert eingegeben werden. ISO-639-1 und -2 koennen gemixt werden.
-$moduldef['locales'] = 'all';
-
-// 12.) Interfaces, bei welchen sich das Modul registrieren soll
-//      ! Dies ist ein etwas komplexerer Eingabetyp - es ist ein mehrdimensionaler Array - mehr nicht.
-//      ! Pro Interface, bei welchem sich das Modul registrieren will, sind vier Angaben noetig:
-//        (1) Interface_ID, (2) Datei, worin sich die auszufuehrende Funktion befindet,
-//        (3) Name der auszufuehrenden Funktion, (4) Filtertyp
-//      --> Format: array('i_id'=>'w','file'=>'x','func'=>'y','filter'=>'z')
-//          --> w = Interface_ID, Format: positive Integerzahl (max. Digits == 11)
-//          --> x = Dateiname, Format: Dateiname.Extension (kein Pfad)
-//          --> y = Funktionsname, Format: Name der Funktion ohne Klammern mit Argumenten
-//          --> z = Filtertyp, Format: one_way oder filter
-// Registrierung beim ersten Interface:
-$moduldef['interfaces'] = array();
-
-// 13.) Eigene Tabellen, welche angelegt werden sollen
-//      ! Hier werden die eigens fuer dieses Modul zu erstellenden Tabellen angegeben
-//      ! Wenn keine Tabellen erstellt werden muessen, einfach leerer Array definieren
-//      --> Achtung: Eine Tabelle muss mindestens EIN Attribut besitzen, sonst wird sie nicht angelegt.
-//      --> Format: array('table_name'=>'x','table_beschreibung'=>'y','attribute'=>z)
-//          --> x = Name der Tabelle: MySQL Restriktionen (max. 64 Zeichen, keine Sonderzeichen, ...)
-//          --> y = Beschreibung der Tabelle: Alphanummerische Zeichen, Kurzbeschrieb des Zwecks
-//          --> z = Die Attribute der Tabelle, Format:
-//                  array('name'=>a,'typ'=>b,'laenge'=>c,'zusatz'=>d,'null'=>e,'default'=>f,'extra'=>g,
-//                        'primary'=>h,'index'=>i,'unique'=>j,'volltext'=>k,'beschreibung'=>l)
-//                  --> a = Name des Attributs: (Alphanummerische Zeichen, siehe reservierte Woerter von MySQL)
-//                  --> b = Typ: Datentyp dieses Tabellenattributs (z.B. int, varchar, text, ...)
-//                  --> c = Laenge: Positive Integerzahl oder leer lassen (manchmal auch als maxlength interpretiert)
-//                  --> d = Zusatz: '' | 'BINARY' | 'UNSIGNED' | 'UNSIGNED ZEROFILL'
-//                  --> e = Null Setting: 'NULL | 'NOT NULL'
-//                  --> f = Default: Defaultwert bei Neuerstellung in einer Zeile (max. Zeichenlaenge = 255)
-//                  --> g = Extra: '' | 'auto_increment'
-//                  --> h = Primary: '0' = ist NICHT Primary Key | '1' = IST Primary Key
-//                  --> i = Index: '0' = Nein | '1' = Ja
-//                  --> j = Unique: '0' = Nein | '1' = Ja
-//                  --> k = Volltext Index: '0' = Nein | '1' = Ja (nicht bei allen Typen moeglich)
-//                  --> l = Beschreibung: Wird nur hier und im Modulprozess verwendet (max. Chars = 255)
-// Beschreibung der ersten eigenen Tabelle:
-$moduldef['eigene_tabellen'] = array();
-
-// 14.) Zu erweiternde, schon bestehende Tabellen
-//      ! Hier werden die Tabellen beschrieben, welche schon existieren und durch weitere Attribute
-//        erweitert werden sollen.
-//      ! Wenn keine Tabellen erweitert werden sollen, einfach leerer Array definieren
-//      --> Format: Dasselbe Format wie bei $moduldef['eigene_tabellen']. Die Beschreibung
-//                  einer schon bestehenden Tabelle wird ignoriert, der Name muss aber stimmen.
-$moduldef['erweiterte_tabellen'] = array();
-
-// 15.) Submodule
-//      ! Wenn dieses Modul aus mehreren weiteren Modulen besteht, so koennen diese hier angegeben werden.
-//      ! Wenn keine Submodule existieren, einfach einen leeren String angeben.  (Strichpunkt getrennte Liste)
-//      --> Format: 'submodul_name_1;submodul_name2;...;submodul_namex'
-$moduldef['submodule'] = '';
-
-// 16.) Vorausgesetzte Module
-//      ! Hier werden Module angegeben, welche korrekt installiert vorhanden sein muessen, damit dieses
-//        Modul ueberhaupt erst installiert wird. (Strichpunkt getrennte Liste)
-//      ! Wenn keine solchen Module gibt, einfach einen leeren String uebergeben
-//      --> Format: 'required_modul_name_1;required_modul_name2;...;required_modul_namex'
-$moduldef['required_modules'] = '';
-
-// 17.) Security ID
-//      ! Mit der Security_ID kann man dem Modul den Zugang zu verschiedenen Interfaces sperren.
-//        Auf diese Weise kann ein kompromittiertes Modul nur begrenzt Schaden anrichten.
-//      ! Die niedrigste Stufe der Security_ID ist = 1, die h�chste Stufe = 32768. Je hoeher die
-//        angegebene Security_ID ist, desto h�her ist auch die Zahl der erlaubten Interfaces
-//      ! Welches Interface, welche minimale Security_ID erfordert um benutzt werden zu koennen,
-//        ist in der Tabelle module_interfaces mit den Interfaceeintraegen ersichtlich.
-//      --> Format: 'required_modul_name_1;required_modul_name2;...;required_modul_namex'
-$moduldef['security_id'] = '1';
-
-// 18.) Valid Hosts
-//      ! Erweiterte Security wird es in der naechsten API-Version noch mit der valid_hosts Angabe geben.
-//        Die Datenbank ist dafuer schon vorbereitet. (all = Alle Hosts, im Moment die Standardeinstellung)
-//        Ausgewertet wird die Angabe aber noch nicht.
-//      --> Format: all = Alle hosts | localhost = nur dieser Rechner | mehrere Rechner via ; getrennt angeben
-$moduldef['valid_hosts'] = 'all';
-
-// 19.) Name des Administrationsmenus
-//      ! Im Administrationstool hat das Verwaltungsmenu dieses Moduls einen Namen, hier kann man
-//        einen Namen definieren, wenn man keinen angibt, wird einfach die Modulbezeichnung verwendet
-//      --> Format: Maximale Laenge 40 Zeichen, moeglichst keine Sonderzeichen verwenden
-$moduldef['admin_menu_name'] = 'ERP Export';
-
-// 20.) URL zur Datei, wo das Admin-Verwaltungsmenu liegt
-//      ! Diese URL ist entweder absolut oder (besser) relativ zum {shopdir}/shop/Admin/module/modul_name Verzeichnis
-//        Die hier angegebene Datei wird 'verlinkt' und mit dem in 'admin_menu_name' Namen versehen.
-//        Info: Achtung: Jeder Link in dieser Datei muss folgende GET-Parameter mitgeben:
-//        - darstellen=".$HTTP_GET_VARS['darstellen']
-//        - installed_selection=".$HTTP_GET_VARS['installed_selection']
-//        - backlink=".$HTTP_GET_VARS['backlink']
-//      --> Format: URL
-//$moduldef['admin_menu_link'] = 'show_log_viewer.php';
-$moduldef['admin_menu_link'] = 'export_to_erp.php';
-
-// 21.) URL zum Icon des Adminmenus
-//      ! Diese URL ist relativ zum {shopdir}/shop/Admin/ Verzeichnis (sonst gibt es einen include-Fehler
-//        Die hier angegebene Datei wird 'verlinkt' und mit dem in 'admin_menu_name' Namen versehen.
-//      --> Format: URL
-//      --> Format Icon: 48px x 48px, GIF oder PNG oder JPG.
-$moduldef['admin_menu_img'] = 'modul_admin_img.gif';
-
-// --------------------------------------------------------------------------------------
-// ***************************** ENDE DEFINITION DES MODULS *****************************
-// --------------------------------------------------------------------------------------
-
-
-// Bitte unterhalb dieser Zeile keine Aenderungen mehr vornehmen.
-
-
-// -----------------------------------------------------------------------
-// Damit jedes andere Modul ueberpruefen kann ob dieses hier schon "included" ist
-// wird folgende Vairable auf true gesetzt (Name = Ext. Modulname + Dateiname ohne .php)
-$module_name_inkl_prefix = $module_modulname.'_initialize_module';
-$$module_name_inkl_prefix = true;
-
-// 'Mitsenden' der hier verwendeten API-Version
-$moduldef['pps_module_api'] = $pps_module_api;
-
-// Moduldefinitionsarray loeschen und somit den Speicher wieder freigeben
-
-// End of file -----------------------------------------------------------
-?>
diff --git a/pepper/export_to_erp/modul_admin_img.gif b/pepper/export_to_erp/modul_admin_img.gif
deleted file mode 100644
index ad36d0ca3..000000000
Binary files a/pepper/export_to_erp/modul_admin_img.gif and /dev/null differ
diff --git a/pepper/export_to_erp/tmp/.dummy b/pepper/export_to_erp/tmp/.dummy
deleted file mode 100644
index e69de29bb..000000000
diff --git a/pepper/handbuch.pdf b/pepper/handbuch.pdf
deleted file mode 100644
index b238af379..000000000
Binary files a/pepper/handbuch.pdf and /dev/null differ
diff --git a/pepper/menu.ini b/pepper/menu.ini
deleted file mode 100644
index 6db3fde22..000000000
--- a/pepper/menu.ini
+++ /dev/null
@@ -1,12 +0,0 @@
-
-[Shop]
-
-[Shop--Warenexport]
-module=pepper/shopimport_db.php
-
-[Shop--Bestellungen]
-module=pepper/pepperexport.php
-
-[Shop--Konfiguration]
-module=pepper/confedit.php
-
diff --git a/pepper/pepperexport.php b/pepper/pepperexport.php
deleted file mode 100644
index b6173c7e1..000000000
--- a/pepper/pepperexport.php
+++ /dev/null
@@ -1,335 +0,0 @@
-<?
-/***************************************************************
-* $Id: pepperexport.php 2009/02/10 14:41:11 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.4.0
-*Shop: PHPeppershop 2.0
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-?>
-<html>
-	<head><title>Lx-ERP Export der Shopartikel</title>
-	<link type="text/css" REL="stylesheet" HREF="css/main.css"></link>
-<body>
-
-<?php
-$login=($_GET["login"])?$_GET["login"]:$_POST["login"];
-if (file_exists ("conf$login.php")) {
-	require "conf$login.php";
-} else {
-	require "conf.php";
-}
-require_once "DB.php";
-$db=DB::connect($SHOPdns);
-if (!$db) dbFehler("",$db->getDebugInfo());
-if (DB::isError($db)) {
-	dbFehler("",$db->getDebugInfo());
-	die ($db->getDebugInfo());
-};
-$db2=DB::connect($ERPdns);
-if (!$db2) dbFehler("",$db2->getDebugInfo());
-if (DB::isError($db2)) {
-	dbFehler("",$db2->getDebugInfo());
-	die ($db2->getDebugInfo());
-};
-function query($db,$sql) {
-global $utftrans;
-		if ($utftrans) $sql=utf8_encode($sql);
-		$rc=$db->query($sql);
-		if (DB::isError($rc)) {
-            dbFehler($sql,$rc->userinfo);
-			return false;
-		}
-		return $rc;
-}
-/****************************************************
-* dbFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function dbFehler($sql,$err) {
-global $showErr;
-	if ($showErr)
-		echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-function checkBestellung($status) {
-global $db;
-	if ($status=="B") { $where="";}  // B = alle Bestellungeb, N = neue, Y = alte
-	else { $where="where Bestellung_bezahlt = '$status'";}
-	$sql="select * from bestellung $where and Datum is not null  and Bestellung_abgeschlossen = 'Y' order by Datum";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	return (count($rs)>0)?count($rs):false;
-}
-function getBestellKunde($BID) {
-global $db;
-	$sql="select * from kunde left join bestellung_kunde on Kunden_ID=FK_Kunden_ID where  FK_Bestellungs_ID=$BID";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	return $rs[0]["Kunden_Nr"];
-}
-function sonderkosten($transID,$data,$id,$f) {
-global $db2,$versand,$nachn,$minder,$treuh,$paypal,$unit;
-	$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-	$sql.=$transID.",".${$id}["ID"].",'".${$id}["TXT"]."',1,".$data.",'".$unit."',0,0)";
-	fputs($f,"$transID,".${$id}["ID"].",'".${$id}["TXT"]."',1,$data\n");
-	if (!query($sql)) { return false; }
-	else { return true; };
-}
-function insBestArtikel($zeile,$transID) {
-global $db,$db2,$div07,$div16,$f,
-	$versandID,$nachnID,$minderID,$treuhID,$paypalID;
-	$BID=$zeile["Bestellungs_ID"];
-	$sql ="select * from artikel left join artikel_bestellung on Artikel_ID=FK_Artikel_ID ";
-	$sql.="left join bestellung on Bestellungs_ID=FK_Bestellungs_ID where Bestellungs_ID=$BID";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$ok=true;
-	foreach ($rs as $zeile) {
-		$sql="select * from parts where partnumber='".$zeile["Artikel_Nr"]."'";
-		$rs2=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ( $rs2[0]["id"]) {$artID=$rs2[0]["id"]; }
-		else { $artID=($zeile["MwSt_Satz"]=="7")?$div07["ID"]:$div16["ID"]; };
-		//$preis=round($zeile["Preis"]/($zeile["MwSt_Satz"]+100)*100,2);
-		$preis=$zeile["Preis"];
-		$notes=$zeile["Artikelname"];
-		$vari=split(chr(254),$zeile["Variation"]);
-		if ($vari) { for($cnt=0; $cnt<count($vari); $cnt++) {
-				$notes.="\n".$vari[$cnt];
-				$cnt++;
-				$preis+=trim($vari[$cnt]) * $zeile["Anzahl"];
-			}
-		};
-		$opts=split(chr(254),$zeile["Optionen"]);
-		if ($opts) { for($cnt=0; $cnt<count($opts); $cnt++) {
-				$notes.="\n".$opts[$cnt];
-				$cnt++;
-				$preis+=trim($opts[$cnt]) * $zeile["Anzahl"];
-			}
-		}
-		if ($zeile["Zusatztexte"]) {
-			$zusatz=strtr($zeile["Zusatztexte"],"þ","\n");
-			$notes.="\n".$zusatz;
-		}
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$transID.",".$artID.",'".$notes."',".$zeile["Anzahl"].",".$preis.",'Stck',0,0)";
-		$rc=query($db2,$sql);
-
-		if (!$rc) { $ok=false; break; };
-		fputs($f,$transID.",".$artID.",'".$zeile["Artikelname"]."',".$zeile["Anzahl"].",".$preis."\n");
-		echo " - Artikel:[ BuNr.:$artID ArtNr:<b> ".$zeile["Anzahl"]." x ".$zeile["Artikel_Nr"]."</b> :".$zeile["Artikelname"]." ]<br>";
-	}
-	if ($zeile["Versandkosten"] && $ok) {
-		$ok=sonderkosten($transID,$zeile["Versandkosten"],"versand",$f);
-	}
-	if ($zeile["Nachnamebetrag"] && $ok) {
-		$ok=sonderkosten($transID,$zeile["Nachnamebetrag"],"nachn",$f);
-	}
-	if ($zeile["Mindermengenzuschlag"] && $ok) {
-		$ok=sonderkosten($transID,$zeile["Mindermengenzuschlag"],"minder",$f);
-	}
-	if ($zeile["Treuhandkosten"] && $ok) {
-		$ok=sonderkosten($transID,$zeile["Treuhandkosten"],"treuh",$f);
-	}
-	if ($zeile["Paypalkosten"] && $ok) {
-		$ok=sonderkosten($transID,$zeile["Paypalkosten"],"paypal",$f);
-	}
-	if ($ok) {
-		$sql="update bestellung set Bestellung_bezahlt='Y' WHERE Bestellungs_ID =$BID";
-		$rc=query($db,$sql);
-		fputs($f,"ok\n");
-		return true;
-	} else {
-		$sql="delete from orderitems where trans_id=$transID";
-		$rc=query($db,$sql);
-		$sql="delete from oe where id=$transID";
-		$rc=query($db,$sql);
-		fputs($f,"Fehler (insBestArtikel)!!!!\n");
-		return false;
-	}
-}
-function getNextAnr() {
-global $db2;
-	$sql="select * from defaults";
-	$sql1="update defaults set sonumber=";
-	$rc=query($db2,"BEGIN");
-	$rs2=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-	$auftrag=$rs2[0]["sonumber"]+1;
-	$rc=query($db2,$sql1.$auftrag);
-	$rc=query($db2,"COMMIT");
-	return $auftrag;
-}
-function getNextKnr() {
-global $db2;
-	$sql="select * from defaults";
-	$sql1="update defaults set customernumber='";
-	$rc=query($db2,"BEGIN");
-	$rs2=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-	$kdnr=$rs2[0]["customernumber"]+1;
-	$rc=query($db2,$sql1.$kdnr."'");
-	$rc=query($db2,"COMMIT");
-	return $kdnr;
-}
-function getBestellung() {
-global $db,$db2,$ERPusr,$f,$preA,$auftrnr;
-	$sql="select * from bestellung where Bestellung_bezahlt='N' order by Bestellungs_ID";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$ok=true;
-	foreach ($rs as $zeile) {
-		$kdnr=getBestellKunde($zeile["Bestellungs_ID"]);
-		echo "Kunde:[ Buchungsnummer:$kdnr ] ";
-		$newID=uniqid (rand());
-		if (ereg("&r=([0-9]+)",$zeile["Bestellung_string"],$refnr)) {
-                        $refnr=$refnr[1];
-                } else {
-                        $refnr=$zeile["Bestellungs_ID"];
-                }
-                if ($auftrnr) {
-                        $anr=$preA.getNextAnr();
-                } else {
-                        $anr=$preA.$refnr;
-                }
-                $sql="insert into oe (notes,ordnumber,cusordnumber) values ('$newID','$anr','$refnr')";
-		$rc=query($db2,$sql);
-		$sql="select * from oe where notes = '$newID'";
-		$rs2=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-		$Bezahlung=$zeile["Bezahlungsart"];
-		if ($Bezahlung=="Lastschrift") {
-			$sql="select * from kunde where Kunden_Nr=$kdnr";
-			$kd=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-			$Bezahlung.="\nKontoinhaber: ".$kd[0]["kontoinhaber"]."\n";
-			$Bezahlung.="Bankname: ".$kd[0]["bankname"]."\n";
-			$Bezahlung.="Blz: ".$kd[0]["blz"]."\n";
-			$Bezahlung.="KontoNr: ".$kd[0]["kontonummer"];
-		}
-		$sql ="update oe set transdate='".$zeile["Datum"]."', intnotes='".$zeile["Anmerkung"];
-		$sql.="', customer_id=$kdnr, amount=".$zeile["Rechnungsbetrag"].", netamount=".($zeile["Rechnungsbetrag"]-$zeile["MwSt"]);
-		$sql.=", reqdate='".$zeile["Datum"]."', notes='$Bezahlung', taxincluded='f', curr='EUR',employee_id=".$ERPusr["ID"].", vendor_id=0 ";
-		$sql.="where id=".$rs2[0]["id"];
-		$rc=query($db2,$sql);
-		fputs($f,"ordnumber=".$zeile["Bestellungs_ID"].", transdate='".$zeile["Datum"]."', customer_id=$kdnr, amount=".($zeile["Rechnungsbetrag"]+$zeile["MwSt"]).", notes=".$zeile["Bezahlungsart"]."\n");
-		echo "Auftrag:[ Buchungsnummer:".$rs2[0]["id"]." AuftrNr:<b>".$anr."</b> ]<br>";
-		if (!insBestArtikel($zeile,$rs2[0]["id"])) { $ok=false; echo " Fehler<br>"; break; } else { echo " ok<br>"; };
-	}
-	return $ok;
-}
-function chkKdData($data) {
-global $db2;
-	$sql="select * from customer where id = ".$data["Kunden_Nr"];
-	$rs=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs[0]["zipcode"]<>$data["PLZ"]) $set.="zipcode='".$data["PLZ"]."',";
-	if ($rs[0]["city"]<>$data["Ort"]) $set.="city='".$data["Ort"]."',";
-	if ($rs[0]["country"]<>$data["Land"]) $set.="country='".$data["Land"]."',";
-	if ($rs[0]["phone"]<>$data["Tel"])$set.="phone='".$data["Tel"]."',";
-	if ($rs[0]["fax"]<>$data["Fax"])  $set.="fax='".$data["Fax"]."',";
-	if ($rs[0]["email"]<>$data["Email"])$set.="email='".$data["Email"]."',";
-	if ($rs[0]["notes"]<>$data["Beschreibung"])$set.="notes='".$data["Beschreibung"]."',";
-	if ($data["Firma"]) {
-		if ($rs[0]["name"]<>$data["Firma"]) $set.="set name='".$data["Firma"]."',";
-		if ($rs[0]["contact"]<>$data["Vorname"]." ".$data["Nachname"]) $set.="contact='".$data["Vorname"]." ".$data["Nachname"]."',";
-	} else {
-		if ($rs[0]["name"]<>$data["Nachname"].", ".$data["Vorname"]) $set.="set name='".$data["Nachname"].", ".$data["Vorname"]."',";
-	}
-	if ($data["Strasse"]) {
-		if ($rs[0]["street"]<>$data["Strasse"]) $set.="street='".$data["Strasse"]."',";
-	} else if ($data["Postfach"]) {
-		if ($rs[0]["street"]<>$data["Postfach"]) $set.="street='".$data["Postfach"]."',";
-	};
-	if ($set) {
-		$sql="update customer set ".substr($set,0,-1)." where id=".$rs[0]["id"];
-		$rc=query($db2,$sql);
-	}
-}
-function insKdData($data) {
-global $db2,$preK,$kdnum;
-	$newID=$data["Kunden_ID"];
-	if ($kdnum==1) {
-		$kdnr=$preK.getNextKnr();
-	} else {
-		$kdnr=$preK.$data["customers_id"];
-	}
-	$sql="insert into customer (name,customernumber) values ('$newID','$kdnr')";
-	$rc=query($db2,$sql);
-	$sql="select * from customer where name = '$newID'";
-	$rs=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($data["Firma"]) { $set.="set name='".$data["Firma"]."',contact='".$data["Vorname"]." ".$data["Nachname"]."',"; }
-	else { $set.="set name='".$data["Nachname"].", ".$data["Vorname"]."',"; }
-	if ($data["Strasse"]) { $set.="street='".$data["Strasse"]."',"; }
-	else if ($data["Postfach"]) { $set.="street='".$data["Postfach"]."',"; };
-	$set.="zipcode='".$data["PLZ"]."',";
-	$set.="city='".$data["Ort"]."',";
-	$set.="country='".$data["Land"]."',";
-	$set.="phone='".$data["Tel"]."',";
-	$set.="fax='".$data["Fax"]."',";
-	$set.="email='".$data["Email"]."',";
-	$set.="notes='".$data["Beschreibung"]."',";
-	$set.="taxincluded='f' ";
-	$sql="update customer ".$set;
-	$sql.="where id=".$rs[0]["id"];
-	$sql=utf8_encode($sql);
-	echo $sql."<br>";
-	$rc=query($db2,$sql);
-		if (DB::isError($rc)) {
-            print_r($rc); echo "<br>";
-		}
-	return $rs[0]["id"];
-}
-function checkKunde() {
-global $db,$f;
-	$sql="select * from kunde left join bestellung_kunde on FK_Kunden_ID=Kunden_ID left join bestellung on Bestellungs_ID=FK_Bestellungs_ID where Bestellung_bezahlt='N'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	$ok=true;
-	$anzahl=count($rs);
-	$neu=0; $old=0;
-	foreach ($rs as $zeile) {
-		if ($zeile["Kunden_Nr"]>0) {
-			chkKdData($zeile);
-			$old++;
-		} else {
-			$zeile["Kunden_Nr"]=insKdData($zeile);
-			if ($zeile["Kunden_Nr"]>0) {
-				$sql="update kunde set Kunden_Nr='".$zeile["Kunden_Nr"]."' where k_ID=".$zeile["k_ID"];
-				$rc=query($db,$sql);
-			} else {
-				$ok=false; break;
-			}
-			$neu++;
-		}
-		fputs($f,$zeile["Nachname"]." ".$zeile["Firma"]."\n");
-		fputs($f,"\n----------------------------------------\n\n");
-	}
-	return ($ok)?array($anzahl,$neu,$old):false;
-}
-
-function savedata($str) {
-global $f;
-	foreach ($str as $val) {
-		$str.=$val.",";
-	}
-	fputs($f,substr($str,0,-1)."\n");
-}
-
-$f=fopen("tmp/".date("y-m-dH:i").".shop","w");
-$ok=checkBestellung("N");
-if ($ok) {
-	echo "Es liegen $ok Bestellungen vor. <br>";
-	fputs($f,"Es liegen $ok Bestellungen vor. \n");
-	$ok=checkKunde();
-	if ($ok) {
-		echo $ok[0]." Kunden, davon ".$ok[1]." neue(r) Kunde(n).<br>";
-		fputs($f,$ok[0]." Kunden, davon ".$ok[1]." neue(r) Kunde(n).\n");
-		$ok=getBestellung();
-		if ($ok) { echo "Daten transferiert!";  fputs($f,"Daten transferiert!\n");}
-		else { echo "Fehler (Bestellungen)! ! ! ";   fputs($f,"Fehler (Bestellungen)! ! !\n");};
-	} else {
-		 echo "Fehler (Kunden)! ! ! ";   fputs($f,"Fehler (Kunden)! ! !\n");
-	}
-} else { echo "Keine Bestellungen!<br>";  fputs($f,"keine Bestellungen\n");};
-
-fclose($f);
-
-?>
-<!--br><a href="trans.php">zur&uuml;ck</a-->
-</body>
-</html>
diff --git a/pepper/readme.first b/pepper/readme.first
deleted file mode 100644
index d5eebeb9c..000000000
--- a/pepper/readme.first
+++ /dev/null
@@ -1,93 +0,0 @@
-Shop - Schnittstelle Lx-ERP <-> PHPeppershop
-
-
-Info:
-	Die Zusammenarbeit mit der Version 2.6.x wurde nicht getestet! 
-	-geht ;=)
-
-	Die Anmeldung der Benutzer an LxO hat sich ge�ndert. Auch wurde  Lagerwesen eingef�hrt.
-	Damit die Schnittstelle mit Version 2.6.0 und neuer funktioniert, sollten hier Anpassungen
-	durchgef�hrt werden.
-
-Update:
-        Die Schnittstelle meldet sich unabh�ngig mit den hinterlegten Daten an.
-        Da nicht auf L�ger gebucht (Auftrag ohne Lagerbewegung) wird, ist auch hier i
-        nichts zu ber�chsichtigen.
-        Warenbestand in "parts" ist der Gesamtbestand. Nicht unbedingt der Bestand f�r
-        den Shop. Sollte vielleicht noch angepasst werden.
-	
-
-Vorraussetzungen:
-	Lx-ERP Version >= 2.4.0 
-	PHPeppershop 2
-	Pear DB, PHP-ImageMagick
-
-Installation:
-Das tar-File unterhalb vom Webserververzeichnis oder vom ERP-Verzeichnis entpacken.
-
-	$ cd /var/www/html
-	$ tar xzf /pfad/zu/pepper.tgz
-
-In das Verzeichnis oscomm wechseln und Schreibrechte auf die Datei conf.php und 
-die Verzeichnisse pepper und tmp f�r den Webbenutzer (apache,www-data,httpd) vergeben.
-
-	$ chown apache pepper
-	$ chown apache pepper/conf.php
-	$ chmod 600 pepper/conf.php
-	$ chown apache pepper/tmp
-
-Bitte zuerst einen Benutzer f�r die ERP anlegen, der mit der Schnittstelle benutzt 
-werden soll. Dann noch die Artikel 'Diverse 16%', 'Versandkosten' und 'Nachname' anlegen.
-Sollen 'PayPal','Mindermengenzuschlag' und '7%'-Artikel extra verwendet werden, legen Sie
-auch diese Artikel zun�chst an.
-
-Im Browser dann folgende URL aufrufen:
-
-	http://webserver/pfad/pepperm/confedit.php
-
-	z.B.: http://localhost/pepperm/confedit.php
-
-Benutzer und Kennwort f�r die Erstinstallation sind:
-
-	pepper / pepper
-
-Die Maske sogf�lltig ausf�llen.
-
-	db-Host		db-Server f�r die jeweilige Anwendung
-	Database	Namen der Datenbankinstanzen
-	db-User		Username und Kennwort f�r die jeweilige Instanz
-	User-ID		Mit dieser ID soll in die ERP geschrieben werden
-	CSV-Dir		hier wird die csv-Datei erwartet (Schreibrechte!)
-	Image-Dir	hier liegen die Bilder
-	ftp-Host	Webserver der jeweiligen Anwendung
-	ftp-User	Name und Kennwort f�r ftp-Zugang
-	ID-xxxx		Interne ID der Waren. Lx-ERP:
-	Shopsprache	Die Id der Voreingestellten Sprache. Nur f�r diese 
-				werden die Artikel eingestellt.
-	Bildergr��e	in Byte
-
-Das Formular abschicken. 
-
-Sollen sp�ter �nderungen durchgef�hrt werden, so mu� bei der Anmeldung 
-der ERP-ftp-User als Benutzer verwendet werden.
-
-
-
-Fehlerquellen:
-Befinden sich ERP und Shop nicht auf dem gleichen Server, achten Sie darauf, das
-die entsprechende Datenbank von Aussen erreichbar ist. Dazu m�ssen folgende Ports 
-freigeschaltet werden:
-
-	MySQL		3306
-	PostgreSQL	5432
-
-Auch mu� auf dem Shopserver ein ftp-Dienst eingerichtet werden, wenn Bilder �ber-
-tragen werden sollen. Die Firewal ist entsprechend anzupassen.
-
-Arbeiten:
-In der ERP kann nun bei den Artikeln das H�ckchen Shop gesetzt werden.
-Bitte auch eine Warengruppe vergeben, da sonst alle Artikel in Default landen.
-Da die ERP nur eine Kategorieebene verwalten kann, mu� der ganze Kategorienpfad
-hintelegt werden. Die einzelnen Kategorien werden durch Ausrufezeichen (!) getrennt.
-Die Hauptkategorie wird durch "[" und "]" eingeklammert.
-
diff --git a/pepper/s2e.gif b/pepper/s2e.gif
deleted file mode 100644
index 836133323..000000000
Binary files a/pepper/s2e.gif and /dev/null differ
diff --git a/pepper/shopimport_db.php b/pepper/shopimport_db.php
deleted file mode 100644
index af1254ab0..000000000
--- a/pepper/shopimport_db.php
+++ /dev/null
@@ -1,285 +0,0 @@
-<?php
-/***************************************************************
-* $Id: shopimport_db.php,v 1.5 2006/02/06 13:49:11 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.0
-*Shop: PHPeppershop 2.0
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-$login=($_GET["login"])?$_GET["login"]:$_POST["login"];
-if (file_exists ("conf$login.php")) {
-	require "conf$login.php";
-} else {
-	require "conf.php";
-}
-require_once "DB.php";
-
-$db=DB::connect($SHOPdns);
-if (!$db) dbFehler("",$db->getDebugInfo());
-if (DB::isError($db)) {
-	dbFehler("",$db->getDebugInfo());
-	die ($db->getDebugInfo());
-};
-$db2=DB::connect($ERPdns);
-if (!$db2) dbFehler("",$db2->getDebugInfo());
-if (DB::isError($db2)) {
-	dbFehler("",$db2->getDebugInfo());
-	die ($db2->getDebugInfo());
-};
-/****************************************************
-* dbFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function dbFehler($sql,$err) {
-global $showErr;
-    if ($showErr)
-           echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-function getBugru() {
-global $db2;
-	if (!$db2) return;
-		$sql ="select  BG.id as bugru,(T.rate * 100) as rate,TK.startdate from buchungsgruppen BG ";
-		$sql.="left join chart C on BG.income_accno_id_0=C.id left join taxkeys TK ";
-		$sql.="on TK.chart_id=C.id left join tax T on T.id=TK.tax_id where ";
-		$sql.="TK.startdate <= now() order by BG.id, TK.startdate";
-		$rs=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ($rs) foreach ($rs as $row) {
-			$bugru[$row["bugru"]]=$row["rate"];
-	}
-	return $bugru;
-}
-// Ab hier Artikelexport aus ERP
-function shopartikel() {
-global $db2,$pricegroup;
-	if ($pricegroup>0) {
-		$sql="SELECT P.partnumber,P.description,P.weight,buchungsgruppen_id as bugru,G.price as sellprice,P.sellprice as stdprice, ";
-		$sql.="PG.partsgroup,P.notes,P.image,P.onhand FROM ";
-		$sql.="parts P left join partsgroup PG on PG.id=P.partsgroup_id left join prices G on G.parts_id=P.id ";
-		$sql.="where P.shop='t'  and (G.pricegroup_id=$pricegroup or G.pricegroup_id is null)";
-	} else {
-		$sql="SELECT P.partnumber,P.description,P.weight,buchungsgruppen_id as bugru,P.sellprice,PG.partsgroup,P.notes,P.image,P.onhand FROM ";
-		$sql.="parts P left join partsgroup PG on ";
-		$sql.="PG.id=P.partsgroup_id where P.shop='t'";
-	}
-	$rs=$db2->getAll($sql,DB_FETCHMODE_ASSOC);
-	return $rs;
-}
-
-// Ab hier Import der Daten in den Shop
-function createCategory($name,$maingroup,$tab,$PID) {
-global $db,$langs;
-	$newID=uniqid(rand());
-	$sql="insert into kategorien (Bild_gross,Bild_last_modified) values ('$newID',now())";
-	$rc=$db->query($sql);
-	$sql="select * from kategorien where Bild_gross = '$newID'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs) {
-		$id=$rs[0]["Kategorie_ID"];
-		$u=($maingroup=="Null")?"is Null":"=$maingroup";
-		$sql="select max(Positions_Nr) as Max from kategorien where  Unterkategorie_von $u";
-		$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-		$pos=$rs[0]["Max"]+1;
-		//$sql="update kategorien set Unterkategorie_von=%s, Name='%s', Positions_Nr=%d,MwSt_Satz=%0.2f, Details_anzeigen='N', Bild_gross = Null where kategorie_ID=%d";
-                $sql="update kategorien set Unterkategorie_von=%s, Name='%s', Tab_text='%s', ist_sichtbar='Y',";
-                $sql.="Positions_Nr=%d,MwSt_Satz=%0.2f, Details_anzeigen='N', Bild_gross = Null, Parent_ID=%d where kategorie_ID=%d";
-		echo "($name) ";
-		//$rc=$db->query(sprintf($sql,$maingroup,$name,$pos,$mwst,$id));
-                $rc=$db->query(sprintf($sql,$maingroup,$name,$tab,$pos,$mwst,$PID,$id));
-		return ($rc)?$id:false;
-	} else {
-		return false;
-	}
-}
-function getCategory($name) {
-global $db;
-	if (empty($name)) $name="Default";
-	$name = utf8_decode($name);
-	preg_match("/^(\[(.*)\])?([^!]+)!?(.*)/",$name,$ref);
-	if ($ref[1]<>""){
-		$tab=$ref[2];
-		$main=$ref[3];
-		if ($ref[4]<>"") {
-			$sub=$ref[4];
-		} else {
-			$sub=false;
-		}
-	} else if ($ref[3]<>"" and $ref[3]<>$ref[0]) {
-		$tab=false;
-		$main=$ref[3];
-		if ($ref[4]<>"") {
-			$sub=$ref[4];
-		} else {
-			$sub=false;
-		}
-	} else  {
-		$tab=false;
-		$sub=false;
-		if (substr($name,0,1)=="[") {
-			$main="Default";			
-		} else {
-			$main=$name;
-		}
-	}
-	$found=true;
-	// suche die Hauptgruppe
-	$sql="select * from kategorien where Name like '".$main."' and  Unterkategorie_von is Null";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs[0]["Kategorie_ID"]) {  // gefunden
-		$maingroup=$rs[0]["Kategorie_ID"];
-	} else {					// nicht gefunden, anlegen
-		$maingroup=createCategory($main,"Null","$tab",0);
-	}
-	echo $maingroup.":".$main." ";
-	if ($sub && $maingroup) {
-		// suche Unterkategorie wenn eine gegeben
-		$sql="select * from kategorien where Name like '$sub' and  Unterkategorie_von = '$main'";
-		$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ($rs[0]["Kategorie_ID"]) {  // gefunden
-			$maingroup=$rs[0]["Kategorie_ID"];
-		} else {					// nicht gefunden, anlegen
-			$maingroup=createCategory($sub,"'$main'","",$maingroup);
-		}
-	};
-	echo $sub." ";
-	return $maingroup;
-}
-function bilder($width,$height,$dest) {
-	if (!class_exists("Imagick")) { echo "Imagick-Extention nicht installiert"; return false; };
-	$handle= new Imagick();
-   	if (!$handle->readImage("./tmp/tmp.file_org")) return false;
-    $d = $handle->getImageGeometry();
-    if ($d["width"]<$d["height"]) {
-        $f = $d["width"]/$d["height"];
-        $w = floor($width*$f);
-        $h = $height;
-    } else {
-        $f = $d["height"]/$d["width"];
-        $w = $width;
-        $h = floor($height*$f);
-    }
-	$handle->thumbnailImage( $w, $h);
-	return $handle->writeImage( "./tmp/tmp.file_$dest");
-}
-function uploadImage($image,$ArtNr) {
-global $db,$ERPftphost,$ERPftpuser,$ERPftppwd,$ERPimgdir,
-		   $SHOPftphost,$SHOPftpuser,$SHOPftppwd,$SHOPimgdir,$iconsize;
-	if ($ERPftphost=="localhost") {
-		echo exec("cp $ERPimgdir/$image ./tmp/tmp.file_org",$aus,$rc2);
-		if ($rc2>0) { echo "[Downloadfehler: $image]<br>"; return false; };
-	} else {
-		$conn_id = ftp_connect($ERPftphost);
-		ftp_login($conn_id,$ERPftpuser,$ERPftppwd);
-		$src=$ERPimgdir."/".$image;
-		$upload=ftp_get($conn_id,"tmp/tmp.file_org","$src",FTP_BINARY);
-		if (!$upload) { echo "[Ftp Downloadfehler! $image]<br>"; return false;};
-		ftp_quit($conn_id);
-	};
-	bilder($iconsize,$iconsize,"smal");
-	bilder(550,550,"big");
-	$rc=preg_match("#(.+/)?([^\.]+)\.(.+)$#",$image,$treffer);
-	$gr=$treffer[2]."_gr.".$treffer[3];
-	$kl=$treffer[2]."_kl.".$treffer[3];
-	if ($SHOPftphost=="localhost") {
-		$dst=$SHOPimgdir."/".$gr;
-		exec("cp ./tmp/tmp.file_big $dst",$aus,$rc2);
-		if ($rc2>0) { echo "[Uploadfehler: $dst]<br>";  return false; };
-		$dst=$SHOPimgdir."/".$kl;
-		exec("cp ./tmp/tmp.file_smal $dst",$aus,$rc2);
-		if ($rc2>0) { echo "[Uploadfehler: $dst]<br>"; return false; };
-	} else {
-		$conn_id = ftp_connect($SHOPftphost);
-		ftp_login($conn_id,$SHOPftpuser,$SHOPftppwd);
-		ftp_chdir($conn_id,$SHOPimgdir);
-		$upload=ftp_put($conn_id,$SHOPimgdir."/$gr","tmp/tmp.file_big",FTP_BINARY);
-		if (!$upload) { echo "[Ftp Uploadfehler! $gr]<br>"; return false; };
-		$upload=ftp_put($conn_id,$SHOPimgdir."/$kl","tmp/tmp.file_smal",FTP_BINARY);
-		if (!$upload) { echo "[Ftp Uploadfehler! $kl]<br>"; return false; };
-		ftp_quit($conn_id);
-	}
-	$sql="update artikel set Bild_gross='$gr', Bild_klein='$kl' where Artikel_ID=$ArtNr";
-	$rc=$db->query($sql);
-}
-function insartikel($data) {
-global $db;
-	$newID=uniqid(rand());
-	$sql="insert into artikel (Artikel_Nr,Name) values ('".$data["partnumber"]."','$newID')";
-	$rc=$db->query($sql);
-	$sql="select * from artikel where Name='$newID'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs) {
-		$sql="insert into artikel_kategorie (FK_Artikel_ID,FK_Kategorie_ID) values (".$rs[0]["Artikel_ID"].",".$data["categories_id"].")";
-		$rc=$db->query($sql);
-		echo " insert ";
-		updartikel($data,$rs[0]["Artikel_ID"]);
-	} else { return false; }
-}
-function updartikel($data,$id) {
-global $db,$bugru,$mwst;
-	$sql ="update artikel set Preis=%01.2f,Gewicht=%0.2f,MwSt_Satz=%0.2f,letzteAenderung=now(),";
-	$sql.="Name='%s',Beschreibung='%s',Lagerbestand=%d  where Artikel_ID=%d";
-	$preis=($data["sellprice"]>0)?$data["sellprice"]:$data["stdprice"];
-	if ($mwst) $preis+=$preis/100*$bugru[$data["bugru"]];
-	$sql=sprintf($sql,$preis,$data["weight"],$bugru[$data["bugru"]],utf8_decode($data["description"]),utf8_decode($data["notes"]),$data["onhand"],$id);
-	$rc=$db->query($sql);
-	$sql="update artikel_kategorie set FK_Kategorie_ID=".$data["categories_id"]." where FK_Artikel_ID=$id";
-	$rc=$db->query($sql);
-	echo "+++<br>";
-}
-function chkartikel($data) {
-global $db,$shop2erp,$mwst;
-	if ($data["partnumber"]=="") { echo "Artikelnummer fehlt!<br>"; return false;};
-	$sql="select * from artikel A left join artikel_kategorie K on A.Artikel_id=K.FK_Artikel_ID where Artikel_Nr like '".$data["partnumber"]."'";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	echo "(".$data["partnumber"]."->".$rs[0]["Artikel_ID"].":".$data["description"].")";
-	if ($rs) {
-		if ($data["image"]) {
-			$rc=preg_match("#(.+/)?([^\.]+)\.(.+)$#",$data["image"],$treffer);
-			if ($treffer) {	$data["picname"]=$treffer[2]."_gr.".$treffer[3]; }
-			else {	$data["picname"]=""; };
-		}
-		$preis=($data["sellprice"]>0)?$data["sellprice"]:$data["stdprice"];
-		if ($mwst) $preis+=$preis/100*$bugru[$data["bugru"]];
-		     if ($rs[0]["Preis"]<>$preis)						{ updartikel($data,$rs[0]["Artikel_ID"]); }
-		else if ($rs[0]["Gewicht"]<>$data["weight"])			{ updartikel($data,$rs[0]["Artikel_ID"]); }
-		else if ($rs[0]["Name"]<>$data["description"])			{ updartikel($data,$rs[0]["Artikel_ID"]); }
-		else if ($rs[0]["Beschreibung"]<>$data["notes"])		{ updartikel($data,$rs[0]["Artikel_ID"]); }
-		else if ($rs[0]["MwSt_Satz"]<>$tax[sprintf("%1.4f",$data["rate"])])	{ updartikel($data,$rs[0]["Artikel_ID"]); }
-		else if ($rs[0]["FK_Kategorie_ID"]<>$data["$categories_id"])		{ updartikel($data,$rs[0]["Artikel_ID"]); }
-		else if ($rs[0]["Lagerbestand"]<>$data["onhand"])		{ updartikel($data,$rs[0]["Lagerbestand"]); }
-		else { echo "...<br>"; };
-		if ($rs[0]["Bild_gross"]<>$data["picname"] and $data["picname"])	{ uploadImage($data["image"],$rs[0]["Artikel_ID"]); }
-		else if ($rs[0]["Bild_gross"] and !$data["picname"]) 		{
-			$sql="update artikel set Bild_gross='', Bild_klein='' where Artikel_ID=".$rs[0]["Artikel_ID"];
-			$rc=$db->query($sql);
-		}
-	} else {
-		$Artikel_ID=insartikel($data);
-		if ($data["image"]) 	uploadImage($data["image"],$Artikel_ID); 
-	}
-}
-
-$artikel=shopartikel();
-echo "Artikelexport ERP -&gt; PHPepper :".count($artikel)." Artikel markiert.<br>";
-flush();
-if ($artikel) {
-    $bugru=getBugru();
-	$sql="select Thumbnail_Breite from shop_settings";
-	$rs=$db->getAll($sql,DB_FETCHMODE_ASSOC);
-	if ($rs) {
-		$iconsize=$rs[0]["Thumbnail_Breite"];
-	} else {
-		$iconsize=100;
-	}
-	foreach ($artikel as $data) {
-		$data["categories_id"]=getCategory($data["partsgroup"]);
-		$x=chkartikel($data);
-	}
-	require ("diff.php");
-}
-
-?>
diff --git a/pepper/tmp/.dummy b/pepper/tmp/.dummy
deleted file mode 100644
index e69de29bb..000000000
diff --git a/pepper/trans.php b/pepper/trans.php
deleted file mode 100644
index 099bee21e..000000000
--- a/pepper/trans.php
+++ /dev/null
@@ -1,108 +0,0 @@
-<?
-/***************************************************************
-* $Id: trans.php,v 1.1 2004/12/17 13:50:30 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.1
-*Shop: PHPepper 1.5
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-require_once "DB.php";
-require_once "conf.php";
-$LAND=array("Germany"=>"D");
-$db=DB::connect($SHOPdns);
-if (DB::isError($db)||!$db) { $shop="<font color='red'>Fehler</font>"; } else { $shop="ok"; };
-$db2=DB::connect($ERPdns);
-if (DB::isError($db2)||!$db2) { $erp="<font color='red'>Fehler</font>"; } else { $erp="ok"; };
-
-?>
-<html>
-	<head>
-		<title>Datenaustausch ERP-PHPeppershop</title>
-	</head>
-<body>
-<center>
-<table>
-	<tr>
-		<td colspan="2">
-			Eine direkte Verbindung beider Datenbanken ist erforderlich!<br>
-			Folgende Verbindungsdaten wurden gefunden:
-		</td>
-	</tr>
-	<tr>
-		<td>
-			<b>Lx-ERP</b>
-		</td>
-		<td><?= $erp ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank-Server</td>
-		<td><?= $ERPhost ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank</td>
-		<td><?= $ERPdbname ?></td>
-	</tr>
-	<tr>
-		<td>
-			<b>PHPepper</b>
-		</td>
-		<td><?= $shop ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank-Server</td>
-		<td><?= $SHOPhost ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank</td>
-		<td><?= $SHOPdbname ?></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td align="center"><a href="shopimport_db.php"><img src="e2s.gif" border="0"></a></td>
-		<td align="center"><a href="pepperexport.php"><img src="s2e.gif" border="0"></a></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			F&uuml;r den Export der Artikeldaten aus der ERP in eine CSV-Datei<br>
-			oder den Import der Artikeldaten in den Shop ist nur die Verbindung<br>
-			zur entsprechenden	Datenbank notwendig.<br>
-			Die CSV-Dateien werden in den konfigurierten Verzeichnissen erwartet.<br>
-			Der Webserver ben&ouml;tigt hier Schreibrechte.
-		</td>
-	</tr>
-	<tr>
-		<td>
-			<b>Lx-ERP</b>
-		</td>
-		<td><a href="<?= $ERPdir ?>"><?= $ERPdir ?></a></td>
-	</tr>
-	<tr>
-		<td align="center"><a href="erpexport.php"><img src="e2c.gif" border="0"></a></td>
-		<td align="center"></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			Copyright (c) 2004 Lx-System - Version: 1.0 - <a href="mailto:info@lx-system.de">info@lx-system.de</a>
-		</td>
-	</tr>
-</table>
-</center>
-</body>
-</html>
diff --git a/xtcom/Shop.png b/xtcom/Shop.png
deleted file mode 100644
index aa2b8741c..000000000
Binary files a/xtcom/Shop.png and /dev/null differ
diff --git a/xtcom/artistic_license b/xtcom/artistic_license
deleted file mode 100644
index d0ac87759..000000000
--- a/xtcom/artistic_license
+++ /dev/null
@@ -1,51 +0,0 @@
-The Artistic License
-
-Preamble
-
-The intent of this document is to state the conditions under which a Package may be copied, such that the Copyright Holder maintains some semblance of artistic control over the development of the package, while giving the users of the package the right to use and distribute the Package in a more-or-less customary fashion, plus the right to make reasonable modifications.
-
-Definitions:
-
-    * "Package" refers to the collection of files distributed by the Copyright Holder, and derivatives of that collection of files created through textual modification.
-    * "Standard Version" refers to such a Package if it has not been modified, or has been modified in accordance with the wishes of the Copyright Holder.
-    * "Copyright Holder" is whoever is named in the copyright or copyrights for the package.
-    * "You" is you, if you're thinking about copying or distributing this Package.
-    * "Reasonable copying fee" is whatever you can justify on the basis of media cost, duplication charges, time of people involved, and so on. (You will not be required to justify it to the Copyright Holder, but only to the computing community at large as a market that must bear the fee.)
-    * "Freely Available" means that no fee is charged for the item itself, though there may be fees involved in handling the item. It also means that recipients of the item may redistribute it under the same conditions they received it.
-
-1. You may make and give away verbatim copies of the source form of the Standard Version of this Package without restriction, provided that you duplicate all of the original copyright notices and associated disclaimers.
-
-2. You may apply bug fixes, portability fixes and other modifications derived from the Public Domain or from the Copyright Holder. A Package modified in such a way shall still be considered the Standard Version.
-
-3. You may otherwise modify your copy of this Package in any way, provided that you insert a prominent notice in each changed file stating how and when you changed that file, and provided that you do at least ONE of the following:
-
-    a) place your modifications in the Public Domain or otherwise make them Freely Available, such as by posting said modifications to Usenet or an equivalent medium, or placing the modifications on a major archive site such as ftp.uu.net, or by allowing the Copyright Holder to include your modifications in the Standard Version of the Package.
-
-    b) use the modified Package only within your corporation or organization.
-
-    c) rename any non-standard executables so the names do not conflict with standard executables, which must also be provided, and provide a separate manual page for each non-standard executable that clearly documents how it differs from the Standard Version.
-
-    d) make other distribution arrangements with the Copyright Holder.
-
-4. You may distribute the programs of this Package in object code or executable form, provided that you do at least ONE of the following:
-
-    a) distribute a Standard Version of the executables and library files, together with instructions (in the manual page or equivalent) on where to get the Standard Version.
-
-    b) accompany the distribution with the machine-readable source of the Package with your modifications.
-
-    c) accompany any non-standard executables with their corresponding Standard Version executables, giving the non-standard executables non-standard names, and clearly documenting the differences in manual pages (or equivalent), together with instructions on where to get the Standard Version.
-
-    d) make other distribution arrangements with the Copyright Holder.
-
-5. You may charge a reasonable copying fee for any distribution of this Package. You may charge any fee you choose for support of this Package. You may not charge a fee for this Package itself. However, you may distribute this Package in aggregate with other (possibly commercial) programs as part of a larger (possibly commercial) software distribution provided that you do not advertise this Package as a product of your own.
-
-6. The scripts and library files supplied as input to or produced as output from the programs of this Package do not automatically fall under the copyright of this Package, but belong to whomever generated them, and may be sold commercially, and may be aggregated with this Package.
-
-7. C or perl subroutines supplied by you and linked into this Package shall not be considered part of this Package.
-
-8. The name of the Copyright Holder may not be used to endorse or promote products derived from this software without specific prior written permission.
-
-9. THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-
-The End
-
diff --git a/xtcom/c2s.gif b/xtcom/c2s.gif
deleted file mode 100644
index 2c2b55db7..000000000
Binary files a/xtcom/c2s.gif and /dev/null differ
diff --git a/xtcom/conf.php b/xtcom/conf.php
deleted file mode 100644
index 95d7935ed..000000000
--- a/xtcom/conf.php
+++ /dev/null
@@ -1,67 +0,0 @@
-<?
-// Verbindung zur ERP-db
-$ERPuser="lxoffice";
-$ERPpass="geheim";
-$ERPhost="localhost";
-$ERPport="5432";
-$ERPdbname="stable";
-$ERPusr["Name"]="hli";
-$ERPusr["ID"]="376";
-$ERPdir="tmp/shopartikel.csv";
-$ERPimgdir="/var/www/stable";
-$maxSize="";
-$ERPftphost="localhost";
-$ERPftpuser="xtcom";
-$ERPftppwd="xtcom";
-//Verbindung zur osCommerce-db
-$SHOPuser="root";
-$SHOPpass="db4web";
-$SHOPhost="localhost";
-$SHOPport="3306";
-$SHOPdbname="xtc304";
-$SHOPdns="mysql://$SHOPuser:$SHOPpass@$SHOPhost/$SHOPdbname";
-$SHOPdir="tmp/shopartikel.csv";
-$SHOPimgdir="/var/www/xtcommerce304/images/product_images";
-$SHOPftphost="localhost";
-$SHOPftpuser="xtcom";
-$SHOPftppwd="xtcom";
-$div16["ID"]="413";
-$div07["ID"]="414";
-$versand["ID"]="1568";
-$nachn["ID"]="";
-$minder["ID"]="";
-$paypal["ID"]="";
-$div16["NR"]="div16";
-$div07["NR"]="div07";
-$versand["NR"]="versand";
-$nachn["NR"]="";
-$minder["NR"]="";
-$paypal["NR"]="";
-$div16["TAX"]="16.00000";
-$div07["TAX"]="7.00000";
-$versand["TAX"]="16.00000";
-$nachn["TAX"]="";
-$minder["TAX"]="";
-$paypal["TAX"]="";
-$div16["TXT"]="Diverse Artikel 16% MWSt.";
-$div07["TXT"]="Diverse Artikel 7% MWSt.";
-$versand["TXT"]="Versandkosten";
-$nachn["TXT"]="";
-$minder["TXT"]="";
-$paypal["TXT"]="";
-$bgcol[1]="#ddddff";
-$bgcol[2]="#ddffdd";
-$preA="xtc";
-$preK="xtc";
-$auftrnr="1";
-$debug=true;
-$kdnum="1";
-$stdprice="0";
-$altprice="0";
-$KDGrp="2";
-$nopic="";
-$showErr="true";
-$Language[0]=array("ERP"=>0,"SHOP"=>2);
-$SHOPdefaultlang="2";
-$SpracheAlle="true";
-?>
\ No newline at end of file
diff --git a/xtcom/confedit.php b/xtcom/confedit.php
deleted file mode 100644
index a3d864804..000000000
--- a/xtcom/confedit.php
+++ /dev/null
@@ -1,536 +0,0 @@
-<?
-if (!isset($_SERVER['PHP_AUTH_USER'])) {
-	Header("WWW-Authenticate: Basic realm=\"Configurations-Editor\"");
-	Header("HTTP/1.0 401 Unauthorized");
-	echo "Sie m&uuml;ssen sich autentifizieren\n";
-	exit;
-} else {
-	$login=($_GET["login"])?$_GET["login"]:$_POST["login"];
-	if (file_exists ("conf$login.php")) {
-		require "conf$login.php";
-	} else {
-		require "conf.php";
-	}
-	if ($_SERVER['PHP_AUTH_USER']<>$ERPftpuser || $_SERVER['PHP_AUTH_PW']<>$ERPftppwd) {
-		Header("WWW-Authenticate: Basic realm=\"My Realm\"");
-		Header("HTTP/1.0 401 Unauthorized");
-		echo "Sie m&uuml;ssen sich autentifizieren\n";
-		exit;
-	}
-	require_once "DB.php";
-	function pg($sel) {
-	global $dbP;
-		echo "\t<option value=0";
-		if ($sel==0) echo " selected";
-		echo ">Standard VK\n";
-		$sql="select id,pricegroup from pricegroup";
-		if (!$dbP) return;
-		$pgs=$dbP->getall($sql);
-		if ($pgs) foreach ($pgs as $row) {
-			echo "\t<option value=".$row[0];
-			if ($sel==$row[0]) echo " selected";
-			echo ">".$row[1]."\n";
-		}
-	}
-    /**
-     * TODO: short description.
-     * 
-     * @param string $sel 
-     * 
-     * @return TODO
-     */
-    function charset($sel) {
-        $chars = array('','latin9','utf-8');
-        foreach ($chars as $c) {
-           echo "\t<option value='$c' ";
-		   if ($sel==$c) echo " selected";
-		   echo ">$c\n";
-        }
-    }
-	function shoplang($sel,$default) {
-	global $dbM;
-		if (!$dbM) return;
-		$sql="SELECT L.*, C.configuration_value FROM languages L LEFT JOIN configuration C ";
-		$sql.="ON L.code = C.configuration_value";
-		$rs=$dbM->getAll($sql,DB_FETCHMODE_ASSOC);
-	        if (!$rs) {
-        	      echo "\t\t<option value='0'>keine Sprachen\n";
-	        } else {
-			echo "\t\t<option value='0' ".(($sel==0)?"selected":"").">nicht verwenden\n";
-			foreach ($rs as $row) {
-				if ($default["id"]<>$row["languages_id"]) {
-					echo "\t\t<option value='".$row["languages_id"]."' ";
-					echo (($row["languages_id"]==$sel)?"selected":"").">";
-					echo ($row["code"]==$row["configuration_value"])?"!":" ";
-					echo $row["name"]."\n";
-				}
-			}
-		}
-	}
-	function erplang($sel) {
-	global $dbP;
-		if (!$dbP) return;
-		$sql="select * from language";
-		$rs=$dbP->getAll($sql,DB_FETCHMODE_ASSOC);
-	        if (!$rs) {
-        	      echo "\t\t<option>keine Sprachen\n";
-	        } else {
-			//echo "\t\t<option value='0' ".(($sel==0)?"selected":"").">Standard\n";
-			foreach ($rs as $row) {
-				echo "\t\t<option value='".$row["id"]."' ";
-				echo ($sel==$row["id"])?"selected":"";
-				echo ">".$row["description"]."\n";
-			}
-		}
-	}
-	function getERPlangs() {
-	global $dbP;
-		if (!$dbP) return;
-		$sql="select * from language";
-		$rs=$dbP->getAll($sql,DB_FETCHMODE_ASSOC);
-		return $rs;
-	}
-	function getShopDefault() {
-	global $dbM;
-		if (!$dbM) return;
-		$sql="select * from languages L left join configuration C on L.code=C.configuration_value ";
-		$sql.="where  configuration_key = 'DEFAULT_LANGUAGE'";
-		$rs=$dbM->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ($rs) {
-		        return array("id"=>$rs[0]["languages_id"],"name"=>$rs[0]["name"]);
-		} else  {
-			return 0;
-		}
-	}
-	function getBugru() {
-	global $dbP;
-		if (!$dbP) return;
-		$sql ="select  BG.id as bugru,(T.rate * 100) as rate,TK.startdate from buchungsgruppen BG ";
-		$sql.="left join chart C on BG.income_accno_id_0=C.id left join taxkeys TK ";
-		$sql.="on TK.chart_id=C.id left join tax T on T.id=TK.tax_id where ";
-		$sql.="TK.startdate <= now() order by BG.id, TK.startdate";
-		$rs=$dbP->getAll($sql,DB_FETCHMODE_ASSOC);
-		if ($rs) foreach ($rs as $row) {
-			$bugru[$row["bugru"]]=$row["rate"];
-		}
-		return $bugru;
-	}
-	if ($_POST["ok"]=="sichern") {
-		$ok=true;
-                $dsnP = array(
-                    'phptype'  => 'pgsql',
-                    'username' => $_POST["ERPuser"],
-                    'password' => $_POST["ERPpass"],
-                    'hostspec' => $_POST["ERPhost"],
-                    'database' => $_POST["ERPdbname"],
-                    'port'     => $_POST["ERPport"]
-                );
-		$dbP=@DB::connect($dsnP);
-		if (DB::isError($dbP)||!$dbP) {
-			$ok=false;
-			echo "Keine Verbindung zur ERP<br>";
-			echo $dbP->userinfo;
-			$dbP=false;
-		} else {
-			$bugru=getBugru();
- 			$sql="SELECT id,description,buchungsgruppen_id FROM parts where partnumber = '%s'";
-			$rs=$dbP->getall(sprintf($sql,$_POST["div16NR"]));
-			$_POST["div16ID"]=$rs[0][0];
-			$div16txt=addslashes($rs[0][1]);
-			$_POST["div16TAX"]=$bugru[$rs[0][2]];
-			$rs=$dbP->getall(sprintf($sql,$_POST["div07NR"]));
-			$_POST["div07ID"]=$rs[0][0];
-			$_POST["div07TAX"]=$bugru[$rs[0][2]];
-			$div07txt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["versandNR"]));
-			$_POST["versandID"]=$rs[0][0];
-			$_POST["versandTAX"]=$bugru[$rs[0][2]];
-			$versandtxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["nachnNR"]));
-			$_POST["nachnID"]=$rs[0][0];
-			$_POST["nachnTAX"]=$bugru[$rs[0][2]];
-			$nachntxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["minderNR"]));
-			$_POST["minderID"]=$rs[0][0];
-			$_POST["minderTAX"]=$bugru[$rs[0][2]];
-			$mindertxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall(sprintf($sql,$_POST["paypalNR"]));
-			$_POST["paypalID"]=$rs[0][0];
-			$_POST["paypalTAX"]=$bugru[$rs[0][2]];
-			$paypaltxt=addslashes($rs[0][1]);
-			$rs=$dbP->getall("select id from employee where login = '".$_POST["ERPusrN"]."'");
-			$_POST["ERPusrID"]=$rs[0][0];
-		}
-                $dsnM = array(
-                    'phptype'  => 'mysql',
-                    'username' => $_POST["SHOPuser"],
-                    'password' => $_POST["SHOPpass"],
-                    'hostspec' => $_POST["SHOPhost"],
-                    'database' => $_POST["SHOPdbname"],
-                    'port'     => $_POST["SHOPport"]
-                );
-		$dbM=@DB::connect($dsnM);
-		if (DB::isError($dbM)||!$dbM) {
-			//$ok=false;
-			echo "Keine Verbindung zum Shop<br>";
-			echo $dbM->userinfo;
-			$dbM=false;
-		};
-		if ($ok) {
-			$ShopDefaultLang=getShopDefault();
-			$f=fopen("conf$login.php","w");
-			$v="2.0";
-			$d=date("Y/m/d H:i:s");
-			fputs($f,"<?\n// Verbindung zur ERP-db\n");
-			fputs($f,"\$ERPuser=\"".$_POST["ERPuser"]."\";\n");
-			fputs($f,"\$ERPpass=\"".$_POST["ERPpass"]."\";\n");
-			fputs($f,"\$ERPhost=\"".$_POST["ERPhost"]."\";\n");
-			fputs($f,"\$ERPport=\"".$_POST["ERPport"]."\";\n");
-			fputs($f,"\$ERPdbname=\"".$_POST["ERPdbname"]."\";\n");
-			fputs($f,"\$ERPusr[\"Name\"]=\"".$_POST["ERPusrN"]."\";\n");
-			fputs($f,"\$ERPusr[\"ID\"]=\"".$_POST["ERPusrID"]."\";\n");
-			fputs($f,"\$ERPdir=\"".$_POST["ERPdir"]."\";\n");
-			fputs($f,"\$ERPimgdir=\"".$_POST["ERPimgdir"]."\";\n");
-			fputs($f,"\$maxSize=\"".$_POST["maxSize"]."\";\n");
-			fputs($f,"\$ERPftphost=\"".$_POST["ERPftphost"]."\";\n");
-			fputs($f,"\$ERPftpuser=\"".$_POST["ERPftpuser"]."\";\n");
-			fputs($f,"\$ERPftppwd=\"".$_POST["ERPftppwd"]."\";\n");
-			fputs($f,"//Verbindung zur osCommerce-db\n");
-			fputs($f,"\$SHOPuser=\"".$_POST["SHOPuser"]."\";\n");
-			fputs($f,"\$SHOPpass=\"".$_POST["SHOPpass"]."\";\n");
-			fputs($f,"\$SHOPhost=\"".$_POST["SHOPhost"]."\";\n");
-			fputs($f,"\$SHOPport=\"".$_POST["SHOPport"]."\";\n");
-			fputs($f,"\$SHOPdbname=\"".$_POST["SHOPdbname"]."\";\n");
-			fputs($f,"\$SHOPdns=\"mysql://\$SHOPuser:\$SHOPpass@\$SHOPhost/\$SHOPdbname\";\n");
-			fputs($f,"\$SHOPdir=\"".$_POST["SHOPdir"]."\";\n");
-			fputs($f,"\$SHOPchar=\"".$_POST["SHOPchar"]."\";\n");
-			fputs($f,"\$SHOPimgdir=\"".$_POST["SHOPimgdir"]."\";\n");
-			fputs($f,"\$SHOPftphost=\"".$_POST["SHOPftphost"]."\";\n");
-			fputs($f,"\$SHOPftpuser=\"".$_POST["SHOPftpuser"]."\";\n");
-			fputs($f,"\$SHOPftppwd=\"".$_POST["SHOPftppwd"]."\";\n");
-			fputs($f,"\$div16[\"ID\"]=\"".$_POST["div16ID"]."\";\n");
-			fputs($f,"\$div07[\"ID\"]=\"".$_POST["div07ID"]."\";\n");
-			fputs($f,"\$versand[\"ID\"]=\"".$_POST["versandID"]."\";\n");
-			fputs($f,"\$nachn[\"ID\"]=\"".$_POST["nachnID"]."\";\n");
-			fputs($f,"\$minder[\"ID\"]=\"".$_POST["minderID"]."\";\n");
-			fputs($f,"\$paypal[\"ID\"]=\"".$_POST["paypalID"]."\";\n");
-			fputs($f,"\$div16[\"NR\"]=\"".$_POST["div16NR"]."\";\n");
-			fputs($f,"\$div07[\"NR\"]=\"".$_POST["div07NR"]."\";\n");
-			fputs($f,"\$versand[\"NR\"]=\"".$_POST["versandNR"]."\";\n");
-			fputs($f,"\$nachn[\"NR\"]=\"".$_POST["nachnNR"]."\";\n");
-			fputs($f,"\$minder[\"NR\"]=\"".$_POST["minderNR"]."\";\n");
-			fputs($f,"\$paypal[\"NR\"]=\"".$_POST["paypalNR"]."\";\n");
-			fputs($f,"\$div16[\"TAX\"]=\"".$_POST["div16TAX"]."\";\n");
-			fputs($f,"\$div07[\"TAX\"]=\"".$_POST["div07TAX"]."\";\n");
-			fputs($f,"\$versand[\"TAX\"]=\"".$_POST["versandTAX"]."\";\n");
-			fputs($f,"\$nachn[\"TAX\"]=\"".$_POST["nachnTAX"]."\";\n");
-			fputs($f,"\$minder[\"TAX\"]=\"".$_POST["minderTAX"]."\";\n");
-			fputs($f,"\$paypal[\"TAX\"]=\"".$_POST["paypalTAX"]."\";\n");
-			fputs($f,"\$div16[\"TXT\"]=\"".$div16txt."\";\n");
-			fputs($f,"\$div07[\"TXT\"]=\"".$div07txt."\";\n");
-			fputs($f,"\$versand[\"TXT\"]=\"".$versandtxt."\";\n");
-			fputs($f,"\$nachn[\"TXT\"]=\"".$nachntxt."\";\n");
-			fputs($f,"\$minder[\"TXT\"]=\"".$mindertxt."\";\n");
-			fputs($f,"\$paypal[\"TXT\"]=\"".$paypaltxt."\";\n");
-			fputs($f,"\$bgcol[1]=\"#ddddff\";\n");
-			fputs($f,"\$bgcol[2]=\"#ddffdd\";\n");
-			fputs($f,"\$preA=\"".$_POST["preA"]."\";\n");
-			fputs($f,"\$preK=\"".$_POST["preK"]."\";\n");
-			fputs($f,"\$auftrnr=\"".$_POST["auftrnr"]."\";\n");
-			fputs($f,"\$debug=".$_POST["debug"].";\n");
-			fputs($f,"\$kdnum=\"".$_POST["kdnum"]."\";\n");
-			fputs($f,"\$stdprice=\"".$_POST["stdprice"]."\";\n");
-			fputs($f,"\$altprice=\"".$_POST["altprice"]."\";\n");
-			fputs($f,"\$KDGrp=\"".$_POST["KDGrp"]."\";\n");
-			fputs($f,"\$nopic=\"".$_POST["nopic"]."\";\n");
-			fputs($f,"\$showErr=\"true\";\n");
-			$Language=array();
-			$DefaultLangOk=false;
-			if ($_POST["ERPlang"]) foreach ($_POST["ERPlang"] as $key=>$val) {
-				if ($_POST["SHOPlang"][$key]==$ShopDefaultLang["id"]) $DefaultLangOk=true;
-				if ($_POST["SHOPlang"][$key])
-					fputs($f,"\$Language[$key]=array(\"ERP\"=>$val,\"SHOP\"=>".$_POST["SHOPlang"][$key].");\n");
-			}
-			if (!$DefaultLangOk) {
-				//fputs($f,"\$SHOPdbname=\"\";\n");
-				echo "Es wurde keine ERP-Sprache der Shopdefaultsprache zugewiesen.";
-				echo "Verbindung zum Shop abgebrochen<br>";
-			}
-			fputs($f,"\$SHOPdefaultlang=\"".$ShopDefaultLang["id"]."\";\n");
-			fputs($f,"\$SpracheAlle=\"".$_POST["SpracheAlle"]."\";\n");
-			fputs($f,"?>");
-			fclose($f);
-			echo "<br>'conf.php' geschrieben!<br>";
-			if (file_exists ("conf$login.php")) {
-        		        require "conf$login.php";
-        		} else {
-        		        require "conf.php";
-        		}
-			$sql="select count(*) from customers_number";
-			$rc=@$dbM->query($sql);
-			if ($rc->code==-18) {
-				$sql="CREATE TABLE customers_number (  cid int(6) NOT NULL auto_increment,  customers_id int(3) NOT NULL default '0', ";
-				$sql.="kdnr int(3) NOT NULL default '0', shipto int ,  PRIMARY KEY  (cid)) TYPE=MyISAM";
-				$rc=@$dbM->query($sql);
-				if ($rc->code==-1) {
-					echo "Fehler beim Erzeugen der Tabelle 'customers_number' in der Shop-db";
-				} else {
-					echo "Tabelle 'customers_number' in der Shop-db angelegt.";
-				}
-			} else {
-				$sql="select shipto from customers_number limit 1";
-				$rc=@$dbM->query($sql);
-				if ($rc->code==-19) {
-					$sql="alter table customers_number add column shipto int";
-					$rc=@$dbM->query($sql);
-                                	if ($rc->code==-1) {
-						echo "Fehler beim Anlegen der Spalte 'shipto' in 'customers_number'";
-					} else {
-						echo "'shipto' in 'customers_number' angelegt.";
-					}
-				}
-			}
-		} else {
-			$ERPuser=$_POST["ERPuser"];
-			$ERPpass=$_POST["ERPpass"];
-			$ERPhost=$_POST["ERPhost"];
-			$ERPport=$_POST["ERPport"];
-			$ERPdbname=$_POST["ERPdbname"];
-			$ERPusrN=$_POST["ERPusrN"];
-			$ERPdir=$_POST["ERPdir"];
-			$ERPimgdir=$_POST["ERPimgdir"];
-			$maxSize=$_POST["maxSize"];
-			$ERPftphost=$_POST["ERPftphost"];
-			$ERPftpuser=$_POST["ERPftpuser"];
-			$ERPftppwd=$_POST["ERPftppwd"];
-			$SHOPuser=$_POST["SHOPuser"];
-			$SHOPpass=$_POST["SHOPpass"];
-			$SHOPhost=$_POST["SHOPhost"];
-			$SHOPport=$_POST["SHOPport"];
-			$SHOPchart=$_POST["SHOPchart"];
-			$SHOPdbname=$_POST["SHOPdbname"];
-			$SHOPlang=$_POST["SHOPlang"];
-			$SHOPdir=$_POST["SHOPdir"];
-			$SHOPimgdir=$_POST["SHOPimgdir"];
-			$SHOPftphost=$_POST["SHOPftphost"];
-			$SHOPftpuser=$_POST["SHOPftpuser"];
-			$SHOPftppwd=$_POST["SHOPftppwd"];
-			$div16NR=$_POST["div16NR"];
-			$div07NR=$_POST["div07NR"];
-			$versandNR=$_POST["versandNR"];
-			$nachnNR=$_POST["nachnNR"];
-			$minderNR=$_POST["minderNR"];
-			$paypalNR=$_POST["paypalNR"];
-			$preA=$_POST["preA"];
-			$preK=$_POST["preK"];
-			$kdnum=$_POST["kdnum"];
-			$auftrnr=$_POST["auftrnr"];
-			$debug=$_POST["debug"];
-			$altprice=$_POST["altprice"];
-			$stdprice=$_POST["stdprice"];
-			$nopic=$_POST["nopic"];
-		}
-		$ERPlangs=getERPlangs();
-		$CntERPLang=count($ERPlangs); //$rs[0][0];
-	}	else {
-		if (file_exists ("conf$login.php")) {
-			require "conf$login.php";
-		} else {
-			require "conf.php";
-		}
-        	$dsnP = array(
-                    'phptype'  => 'pgsql',
-                    'username' => $ERPuser,
-                    'password' => $ERPpass,
-                    'hostspec' => $ERPhost,
-                    'database' => $ERPdbname,
-                    'port'     => $ERPport
-        	);
-		$dbP=@DB::connect($dsnP);
-		if (DB::isError($dbP)||!$dbP) {
-			echo "Keine Verbindung zur ERP<br>";
-			$dbP=false;
-			//echo $dbP->userinfo;
-		} else {
-			//$rs=$dbP->getAll("select count(*) from language");
-			$ERPlangs=getERPlangs();
-			$CntERPLang=count($ERPlangs); //$rs[0][0];
-		}
-        	$dsnM = array(
-                    'phptype'  => 'mysql',
-                    'username' => $SHOPuser,
-                    'password' => $SHOPpass,
-                    'hostspec' => $SHOPhost,
-                    'database' => $SHOPdbname,
-                    'port'     => $SHOPport
-        	);
-		$dbM=@DB::connect($dsnM);
-		if (DB::isError($dbM)||!$dbM) {
-			echo "Keine Verbindung zum SHOP<br>";
-			$dbM=false;
-			//echo $dbM->userinfo;
-		} else {
-			$ShopDefaultLang=getShopDefault();
-		}
-	}
-?>
-<html>
-<body>
-<center>
-<table style="background-color:#cccccc">
-<form name="ConfEdit" method="post" action="confedit.php">
-<input type="hidden" name="div16ID" value="<?= $div16["ID"] ?>">
-<input type="hidden" name="div07ID" value="<?= $div07["ID"] ?>">
-<input type="hidden" name="minderID" value="<?= $minder["ID"] ?>">
-<input type="hidden" name="versandID" value="<?= $versand["ID"] ?>">
-<input type="hidden" name="nachnID" value="<?= $nachn["ID"] ?>">
-<input type="hidden" name="paypalID" value="<?= $paypal["ID"] ?>">
-<input type="hidden" name="ERPusrID" value="<?= $ERPusr["ID"] ?>">
-<input type="hidden" name="login" value="<?= $login ?>">
-<tr><th>Daten</th><th>Lx-ERP</th><th></th><th>Shop</th></tr>
-<tr>
-	<td>db-Host</td>
-	<td colspan="2"><input type="text" name="ERPhost" size="25" value="<?= $ERPhost ?>"></td>
-	<td><input type="text" name="SHOPhost" size="25" value="<?= $SHOPhost ?>"></td>
-</tr>
-<tr>
-	<td>db-Port</td>
-	<td colspan="2"><input type="text" name="ERPport" size="25" value="<?= $ERPport ?>"></td>
-	<td><input type="text" name="SHOPport" size="25" value="<?= $SHOPport ?>"></td>
-</tr>
-<tr>
-	<td>Database</td>
-	<td colspan="2"><input type="text" name="ERPdbname" size="20" value="<?= $ERPdbname ?>"></td>
-	<td><input type="text" name="SHOPdbname" size="20" value="<?= $SHOPdbname ?>"></td>
-</tr>
-<tr>
-	<td>db-User Name</td>
-	<td colspan="2"><input type="text" name="ERPuser" size="15" value="<?= $ERPuser ?>"></td>
-	<td><input type="text" name="SHOPuser" size="15" value="<?= $SHOPuser ?>"></td>
-</tr>
-<tr>
-	<td>db-User PWD</td>
-	<td colspan="2"><input type="text" name="ERPpass" size="15" value="<?= $ERPpass ?>"></td>
-	<td><input type="text" name="SHOPpass" size="15" value="<?= $SHOPpass ?>"></td>
-</tr>
-<tr>
-	<td>User-ID</td>
-	<td colspan="2"><input type="text" name="ERPusrN" size="10" value="<?= $ERPusr["Name"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($ERPusr["ID"])?"":"checked") ?> onFocus="blur();"> &nbsp; Charset Shop:</td>
-	<td><select name="SHOPchar">
-<? charset($SHOPchar); ?>
-	    </select></td>
-</tr>
-<tr>
-	<td>CSV-Dir</td>
-	<td colspan="2"><input type="text" name="ERPdir" size="30" value="<?= $ERPdir ?>"></td>
-	<td><input type="text" name="SHOPdir" size="30" value="<?= $SHOPdir ?>"></td>
-</tr>
-<tr>
-	<td>Image-Dir</td>
-	<td colspan="2"><input type="text" name="ERPimgdir" size="30" value="<?= $ERPimgdir ?>"></td>
-	<td><input type="text" name="SHOPimgdir" size="30" value="<?= $SHOPimgdir ?>"></td>
-</tr>
-<tr>
-	<td>FTP-Host</td>
-	<td colspan="2"><input type="text" name="ERPftphost" size="20" value="<?= $ERPftphost ?>"></td>
-	<td><input type="text" name="SHOPftphost" size="20" value="<?= $SHOPftphost ?>"></td>
-</tr>
-<tr>
-	<td>FTP-User</td>
-	<td colspan="2"><input type="text" name="ERPftpuser" size="15" value="<?= $ERPftpuser ?>"></td>
-	<td><input type="text" name="SHOPftpuser" size="15" value="<?= $SHOPftpuser ?>"></td>
-</tr>
-<tr>
-	<td>FTP-User PWD</td>
-	<td colspan="2"><input type="text" name="ERPftppwd" size="15" value="<?= $ERPftppwd ?>"></td>
-	<td><input type="text" name="SHOPftppwd" size="15" value="<?= $SHOPftppwd ?>"></td>
-</tr>
-<tr>
-	<td>ID Diverse 16%</td>
-	<td><input type="text" name="div16NR" size="10" value="<?= $div16["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($div16["ID"])?"":"checked") ?>></td>
-	<td>ID Diverse 7%</td>
-	<td><input type="text" name="div07NR" size="10" value="<?= $div07["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($div07["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Versand</td>
-	<td><input type="text" name="versandNR" size="10" value="<?= $versand["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($versand["ID"])?"":"checked") ?>></td>
-	<td>ID Nachname</td>
-	<td><input type="text" name="nachnNR" size="10" value="<?= $nachn["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($nachn["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td>ID Paypal</td>
-	<td><input type="text" name="paypalNR" size="10" value="<?= $paypal["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($paypal["ID"])?"":"checked") ?>></td>
-	<td>ID Mindemenge</td>
-	<td><input type="text" name="minderNR" size="10" value="<?= $minder["NR"] ?>">
-		<input type="checkbox" name="a1" <?= (empty($minder["ID"])?"":"checked") ?>></td>
-</tr>
-<tr>
-	<td >Sprachen</td>
-	<td ><input type="hidden" name="ERPlang[0]" value="0">Standard</td>
-	<td >--&gt;</td>
-	<td ><input type="hidden" name="SHOPlang[0]" value="<?= $ShopDefaultLang["id"] ?>"><?= $ShopDefaultLang["name"] ?></td>
-</tr>
-<? for($i=0; $i < $CntERPLang; $i++) {  ?>
-<tr>
-	<td >Sprachen</td>
-	<td><input type="hidden" name="ERPlang[<?= $i+1 ?>]" value="<?= $ERPlangs[$i]["id"] ?>"><?= $ERPlangs[$i]["description"] ?>
-	<td >--&gt;</td>
-	<td ><select name="SHOPlang[<?= $i+1 ?>]">
-<?= shoplang($Language[$i+1]["SHOP"],$ShopDefaultLang); ?>
-	</select></td>
-</tr>
-<? } ?>
-<tr>
-	<td colspan="2">Nur &uuml;bersetzte Artikel</td>
-	<td><input type="radio" name="SpracheAlle" value="true"  <?= ($SpracheAlle=="true")?"checked":"" ?>> Ja</td>
-	<td><input type="radio" name="SpracheAlle" value="false" <?= ($SpracheAlle<>"true")?"checked":"" ?>> Nein</td>
-</tr>
-<tr>
-	<td>Standardpreis</td>
-	<td><select name="stdprice">
-<? pg($stdprice); ?>
-	    </select></td>
-	<td>Defaultbild</td>
-	<td><input type="text" name="nopic" size="20" value="<?= $nopic ?>">
-<tr>
-	<td>abweichender Preis</td>
-	<td><select name="altprice">
-<? pg($altprice); ?>
-	    </select></td>
-	<td>Kundengruppe</td>
-	<td><input type="text" name="KDGrp" size="3" value="<?= $KDGrp ?>">
-</tr>
-<tr>
-	<td colspan="2">Auftragsnummern durch</td>
-	<td><input type="radio" name="auftrnr" value="1" <?= ($auftrnr==1)?"checked":"" ?>> LxO</td>
-	<td><input type="radio" name="auftrnr" value="0" <?= ($auftrnr<>1)?"checked":"" ?>> Shop</td>
-</tr>
-<tr>
-	<td colspan="2">Kundennummern durch</td>
-	<td><input type="radio" name="kdnum" value="1" <?= ($kdnum==1)?"checked":"" ?>> LxO</td>
-	<td><input type="radio" name="kdnum" value="0" <?= ($kdnum<>1)?"checked":"" ?>> Shop</td>
-</tr>
-<tr>
-	<td colspan="2">Nummernerweiterung</td>
-	<td>Auftrag<input type="text" name="preA" size="5" value="<?= $preA ?>"></td>
-	<td>Kunde<input type="text" name="preK" size="5" value="<?= $preK ?>"></td>
-</tr>
-<tr>
-	<td>Logging</td>
-	<td>ein<input type="radio" name="debug" value="true" <?= ($debug=="true")?"checked":"" ?>>
-	aus<input type="radio" name="debug" value="false" <?= ($debug!="true")?"checked":"" ?>></td>
-	<td></td><td></td>
-</tr>
-<tr><td colspan="4" align="center"><input type="submit" name="ok" value="sichern"></td></tr>
-</form>
-</table>
-</center>
-</body>
-</html>
-<? } ?>
diff --git a/xtcom/diff.php b/xtcom/diff.php
deleted file mode 100644
index eb90afe61..000000000
--- a/xtcom/diff.php
+++ /dev/null
@@ -1,71 +0,0 @@
-<?
-// $Id: diff.php,v 1.1 2004/06/30 10:12:15 hli Exp $
-require_once "shoplib.php";
-$LAND=array("Germany"=>"D");
-if ($_POST["ok"]) {
-	foreach($_POST as $key=>$val) {
-		if ($key=="ok") continue;
-		if ($key=="alle") continue;
-		$sql="update products set products_status=0 where products_model='$key'";
-		//echo "$key $sql";
-		echo "$key ";
-		if (query("shop",$sql,"diff")) { echo "deaktiviert<br>"; }
-		else { echo "konnte nicht deaktiviert werden<br>"; };
-	}
-} else {
-$sql="select partnumber from parts where shop='1' order by partnumber";
-$erp=getAll("erp",$sql,"getPartnumber");
-if ($SHOPlang>0) {
-	$defLang=$SHOPlang;
-} else {
-	$sql="select * from languages L left join configuration C on L.code=C.configuration_value where  configuration_key = 'DEFAULT_LANGUAGE'";
-	$rs=getAll("shop",$sql,"getLanguage");
-	if ($rs) {
-		$defLang=$rs[0]["languages_id"];
-	} else {
-		$defLang=1;
-	}
-}
-if ($erp) foreach ($erp as $zeile) { $arE[]=$zeile["partnumber"]; };
-$sql="select products_model,P.products_id,products_name from products P left join products_description D on P.products_id=D.products_id where language_id=$defLang and products_status=1 order by products_model";
-$shop=getAll("shop",$sql,"products_model");
-if ($shop) foreach ($shop as $zeile) {
-	$arS[]=$zeile["products_model"];
-	$arID[$zeile["products_model"]]=array("id"=>$zeile["products_id"],"name"=>$zeile["products_name"]);
-}
-
-$result=@array_diff($arS,$arE);
-if ($result) {
-?>
-<html>
-<head><title>Artikelpflege</title>
-<script language="JavaScript">
-<!--
-	function sel() {
-		val=document.doppel.alle.checked;
-		cnt=document.doppel.length;
-		for (i=0; i<cnt; i++) {
-			document.doppel.elements[i].checked=val;
-		}
-	}
-//-->
-</script>
-</head>
-<body>
-Folgende Artikel sind in der ERP nicht mehr als Shopartikel markiert.<br>
-Markieren Sie die Artikel, die deaktiviert werden sollen.<br>
-<form name='doppel' method='post' action='diff.php?login=<?= $login ?>'>
-<table>
-<?
-foreach ($result as $data) {
-	echo "\t<tr><td><input type='checkbox' name='".$data."' value='1'></td><td>".$data."</td><td>".$arID[$data]["name"]."</td></tr>\n";
-}
-?>
-	<tr><td><input type='checkbox' name='alle' value='1' onClick="sel()"></td><td></td><td>alle Artikel</td></tr>
-	<tr><td colspan='3'><input type='submit' name='ok' value='ok'></td></tr>
-</table>
-<form>
-<? }
-	else { echo "Artikelbestand identisch"; };
-} ?>
-<!-- a href="trans.php">zur&uuml;ck</a -->
diff --git a/xtcom/e2c.gif b/xtcom/e2c.gif
deleted file mode 100644
index 692eb8b87..000000000
Binary files a/xtcom/e2c.gif and /dev/null differ
diff --git a/xtcom/e2s.gif b/xtcom/e2s.gif
deleted file mode 100644
index f557ed4ba..000000000
Binary files a/xtcom/e2s.gif and /dev/null differ
diff --git a/xtcom/erpexport.php b/xtcom/erpexport.php
deleted file mode 100644
index 4e34ae4e8..000000000
--- a/xtcom/erpexport.php
+++ /dev/null
@@ -1,180 +0,0 @@
-<?
-/***************************************************************
-* $Id: erpexport.php,v 1.1 2004/06/29 08:50:30 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.0
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-?>
-<html>
-	<head><title>Lx-ERP Export der Shopartikel</title>
-	<link type="text/css" REL="stylesheet" HREF="css/main.css"></link>
-	<script language="JavaScript">
-	<!--
-		function xtcomm() {
-			document.fld.PN.value="products_model"; document.fld.partnumber.checked=true;
-			document.fld.BEZ.value="products_name"; document.fld.desctiption.checked=true;
-			document.fld.GEWICHT.value="products_weight"; document.fld.weight.checked=true;
-			document.fld.MWST.value="products_tax"; document.fld.rate.checked=true;
-			document.fld.VK.value="products_price"; document.fld.sellprice.checked=true;
-			document.fld.PG.value="categories_name"; document.fld.partsgroup.checked=true;
-			document.fld.BESCHR.value="products_description"; document.fld.notes.checked=true;
-			document.fld.LAGER.value="products_quantity"; document.fld.onhand.checked=true;
-			document.fld.encl.value="";
-			document.fld.deli.value=";";
-			document.fld.crln.value="\\n";
-			document.fld.head.checked=true;
-			document.fld.shop.value="xtcomm";
-		}
-	//-->
-	</script>
-<body>
-
-<?php
-require_once "shoplib.php";
-
-function artikel() {
-	$sql ="SELECT P.partnumber,P.description,P.unit,P.weight,t.rate,P.sellprice,P.listprice,P.priceupdate,";
-	$sql.="PG.partsgroup,P.notes,P.image,P.onhand,P.buchungsgruppen_id as bugru FROM ";
-	$sql.="chart c left join tax t on c.taxkey_id=t.taxkey, parts P left join partsgroup PG on ";
-	$sql.="PG.id=P.partsgroup_id left join buchungsgruppen B  on P.buchungsgruppen_id = B.id ";
-	$sql.="WHERE P.shop='t'  and c.id=B.income_accno_id_0";
-	$rs=getAll("erp",$sql,"artikel");
-	return $rs;
-}
-
-if ($_POST["export"]) {
-	$data=artikel();
-	$delim=($_POST["deli"])?$_POST["deli"]:",";
-	if (get_magic_quotes_gpc()) {
-		$crln = stripslashes($_POST["crln"]);
-	}
-	$crln = str_replace('\\r', "\015", $crln);
-	$crln = str_replace('\\n', "\012", $crln);
-	$crln = str_replace('\\t', "\011", $crln);
-	$encl=$_POST["encl"];
-	$i=0;
-	$f=fopen($ERPdir,"w");
-	if ($_POST["partnumber"])	{$header.=$_POST["PN"].$delim; };
-	if ($_POST["desctiption"])	{$header.=$_POST["BEZ"].$delim; };
-	if ($_POST["unit"])		{$header.=$_POST["EINHEIT"].$delim; };
-	if ($_POST["onhand"])		{$header.=$_POST["LAGER"].$delim; };
-	if ($_POST["weight"])		{$header.=$_POST["GEWICHT"].$delim; };
-	if ($_POST["rate"])		{$header.=$_POST["MWST"].$delim; };
-	if ($_POST["sellprice"])	{$header.=$_POST["VK"].$delim; };
-	if ($_POST["listprice"])	{$header.=$_POST["EK"].$delim; };
-	if ($_POST["priceupdate"])	{$header.=$_POST["PDATE"].$delim; };
-	if ($_POST["partsgroup"])	{$header.=$_POST["PG"].$delim; };
-	if ($_POST["notes"])		{$header.=$_POST["BESCHR"].$delim; };
-	if ($_POST["image"])		{$header.=$_POST["IMAGE"].$delim; };
-	$header=substr($header,0,-1);
-?>
-<table class="liste">
-<!-- BEGIN Artikel -->
-<?	$i=0;
-	$f=fopen($ERPdir,"w");
-	if ($_POST["head"]) fputs($f,$header.$crln);
-	foreach($data as $zeile) {
-		$file=""; $html="";
-		if ($_POST["shop"]=="pepper") {
-			if (preg_match("/^\[.*\].*/",$zeile["partsgroup"])) { $PG=$zeile["partsgroup"]; }
-			else { $PG="[".$zeile["partsgroup"]."]"; };
-			$mwst=$zeile["rate"]*100;
-		} else if ($_POST["shop"]=="oscomm") {
-			$mwst=sprintf("%01.4f",($zeile["rate"]*100));
-			$PG=$zeile["partsgroup"];
-		} else {
-			$PG=$zeile["partsgroup"];
-			$mwst=$zeile["rate"]*100;
-		};
-		$LineCol = $bgcol[$i%2+1];
-		if ($_POST["partnumber"])	{$file.=$encl.$zeile["partnumber"].$encl.$delim; $html.="<td>".$zeile["partnumber"]."</td>";};
-		if ($_POST["desctiption"])	{$file.=$encl.strtr($zeile["description"],chr(13).chr(10),"  ").$encl.$delim; $html.="<td>".$zeile["description"]."</td>";};
-		if ($_POST["unit"])			{$file.=$encl.$zeile["unit"].$encl.$delim; $html.="<td>".$zeile["unit"]."</td>";};
-		if ($_POST["onhand"])			{$file.=$encl.$zeile["onhand"].$encl.$delim; $html.="<td>".$zeile["onhand"]."</td>";};
-		if ($_POST["weight"])		{$file.=$encl.$zeile["weight"].$encl.$delim; $html.="<td>".$zeile["weight"]."</td>";};
-		if ($_POST["rate"])			{$file.=$encl.$mwst.$encl.$delim; $html.="<td>".$mwst."</td>";};
-		if ($_POST["sellprice"])	{$file.=$encl.(sprintf("%02.2f",$zeile["sellprice"])).$encl.$delim; $html.="<td>".(sprintf("%02.2f",$zeile["sellprice"]))."</td>";};
-		if ($_POST["listprice"])	{$file.=$encl.(sprintf("%02.2f",$zeile["listprice"])).$encl.$delim; $html.="<td>".(sprintf("%02.2f",$zeile["listprice"]))."</td>";};
-		if ($_POST["partsgroup"])	{$file.=$encl.$PG.$encl.$delim; $html.="<td>".$zeile["partsgroup"]."</td>";};
-		if ($_POST["notes"])		{$file.=$encl.strtr($zeile["notes"],chr(13).chr(10),"  ").$encl.$delim; $html.="<td>".$zeile["notes"]."</td>";};
-		if ($_POST["image"])		{$file.=$encl.$zeile["image"].$encl.$delim; $html.="<td>".$zeile["image"]."</td>";};
-		$i++;
-		fputs($f,substr($file,0,-1).$crln);
-		if ($_POST["show"]) {
-?>
-	<tr  class="smal" onMouseover="this.bgColor='#FF0000';" onMouseout="this.bgColor='<?= $LineCol ?>';" bgcolor="<?= $LineCol ?>">
-		<?= $html ?>
-	</tr>
-<? 		}
-	}
-?>
-<!-- END Artikel -->
-</table>
-Anzahl der Artikel: <?= $i ?><br>
-Export am : <?= date("d.m.Y : H:i") ?><br>
-download <a href="tmp/shopartikel.csv">Exportfile</a><br><hr>
-<?
-	fclose($f);
-} // if ($export)
-?>
-Export der Shopartikel aus Lx-ERP <br>
-M&ouml;gliche Felder
-<form name="fld" action="erpexport.php" method="post">
-<input type="hidden" name="shop" value="">
-<table>
-	<tr>
-		<td><input type="checkbox" name="partnumber" value="1">Artikelnummer</td>
-		<td><input type="checkbox" name="desctiption" value="1">Bezeichnung</td>
-		<td><input type="checkbox" name="unit" value="1">Einheit</td>
-		<td><input type="checkbox" name="weight" value="1">Gewicht</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="PN" size="23"></td>
-		<td><input type="text" name="BEZ" size="23"></td>
-		<td><input type="text" name="EINHEIT" size="23"></td>
-		<td><input type="text" name="GEWICHT" size="23"></td>
-	</tr>
-	<tr><td colspan=5></td></tr>
-	<tr>
-		<td><input type="checkbox" name="sellprice" value="1">Verkaufspreis</td>
-		<td><input type="checkbox" name="listprice" value="1">Listenpreis</td>
-		<td><input type="checkbox" name="onhand" value="1">Lagerbestand</td>
-		<td><input type="checkbox" name="rate" value="1">MwSt</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="VK" size="23"></td>
-		<td><input type="text" name="EK" size="23"></td>
-		<td><input type="text" name="LAGER" size="23"></td>
-		<td><input type="text" name="MWST" size="23"></td>
-	</tr>
-	<tr><td colspan=5></td></tr>
-	<tr>
-		<td><input type="checkbox" name="partsgroup" value="1">Gruppe</td>
-		<td><input type="checkbox" name="notes" value="1">Beschreibung</td>
-		<td><input type="checkbox" name="image" value="1">Bild</td>
-		<td><input type="checkbox" name="show" value="1" checked>HTML-Anzeige</td>
-	</tr>
-	<tr>
-		<td><input type="text" name="PG" size="23"></td>
-		<td><input type="text" name="BESCHR" size="23"></td>
-		<td><input type="text" name="IMAGE" size="23"></td>
-		<td></td>
-	</tr>
-	<tr>
-		<td>Feldtrenner <input type="text" name="deli" size="2" value=","></td>
-		<td>Feldumrahmung <input type="text" name="encl" size="2" value="&quot;"></td>
-		<td>Zeilenende <input type="text" name="crln" size="2" value="\n"></td>
-		<td><input type="checkbox" name="head" value="1" checked>Headline</td>
-	</tr>
-	<tr>
-		<td colspan=5><input type="submit" name="export" value="Export"> <input type="button" name="xsc" value="xtCommerce" onClick="xtcomm()"></td>
-	</tr>
-</table>
-<a href="trans.php">zur&uuml;ck</a>
-</form>
-</body>
-</html>
diff --git a/xtcom/handbuch.pdf b/xtcom/handbuch.pdf
deleted file mode 100644
index 63cdd2f83..000000000
Binary files a/xtcom/handbuch.pdf and /dev/null differ
diff --git a/xtcom/menu.ini b/xtcom/menu.ini
deleted file mode 100644
index cd5c93caf..000000000
--- a/xtcom/menu.ini
+++ /dev/null
@@ -1,12 +0,0 @@
-
-[Shop]
-
-[Shop--Warenexport]
-module=xtcom/shopimport_db.php
-
-[Shop--Bestellungen]
-module=xtcom/xtcomexport.php
-
-[Shop--Konfiguration]
-module=xtcom/confedit.php
-
diff --git a/xtcom/pixel_trans.gif b/xtcom/pixel_trans.gif
deleted file mode 100644
index e7749f217..000000000
Binary files a/xtcom/pixel_trans.gif and /dev/null differ
diff --git a/xtcom/readme.first b/xtcom/readme.first
deleted file mode 100644
index 18b0139d6..000000000
--- a/xtcom/readme.first
+++ /dev/null
@@ -1,123 +0,0 @@
-Shop - Schnittstelle Lx-ERP <-> xt:Commerce
-
-
-Info:
-	Die Zusammenarbeit mit der Version 2.6.x wurde nicht getestet!
-
-	Die Anmeldung der Benutzer an LxO hat sich ge�ndert. Auch wurde  Lagerwesen eingef�hrt.
-	Damit die Schnittstelle mit Version 2.6.0 und neuer funktioniert, sollten hier Anpassungen
-	durchgef�hrt werden.
-
-Update:
-	Die Schnittstelle meldet sich unabh�ngig mit den hinterlegten Daten an.
-	Da nicht auf L�ger gebucht (Auftrag ohne Lagerbewegung) wird, ist auch hier i
-	nichts zu ber�chsichtigen. 
-	Warenbestand in "parts" ist der Gesamtbestand. Nicht unbedingt der Bestand f�r 
- 	den Shop. Sollte vielleicht noch angepasst werden.
-
-Vorraussetzungen:
-	Lx-ERP Version >= 2.4.0 
-	xt:Commerce 3.04
-	Pear DB, PHP-ImageMagick
-
-Installation:
-Das tar-File unterhalb vom Webserververzeichnis oder vom ERP-Verzeichnis entpacken.
-
-	$ cd /var/www/html
-	$ tar xzf /pfad/zu/xtcomm.tgz
-
-In das Verzeichnis oscomm wechseln und Schreibrechte auf die Datei conf.php und 
-die Verzeichnisse xtcom und tmp f�r den Webbenutzer (apache,www-data,httpd) vergeben.
-
-	$ chown apache xtcom
-	$ chown apache xtcom/conf.php
-	$ chmod 600 xtcom/conf.php
-	$ chown apache xtcom/tmp
-
-Bitte zuerst einen Benutzer f�r die ERP anlegen, der mit der Schnittstelle benutzt 
-werden soll. Dann noch die Artikel 'Diverse 16%', 'Versandkosten' und 'Nachname' anlegen.
-Sollen 'PayPal','Mindermengenzuschlag' und '7%'-Artikel extra verwendet werden, legen Sie
-auch diese Artikel zun�chst an.
-
-Im Browser dann folgende URL aufrufen:
-
-	http://webserver/pfad/xtcomm/confedit.php
-
-	z.B.: http://localhost/xtcomm/confedit.php
-
-Benutzer und Kennwort f�r die Erstinstallation sind:
-
-	xtcom / xtcom
-
-Die Maske sogf�lltig ausf�llen.
-
-	db-Host		db-Server f�r die jeweilige Anwendung
-	Database	Namen der Datenbankinstanzen
-	db-User		Username und Kennwort f�r die jeweilige Instanz
-	User-ID		Mit dieser ID soll in die ERP geschrieben werden
-	CSV-Dir		hier wird die csv-Datei erwartet (Schreibrechte!)
-	Image-Dir	hier liegen die Bilder
-	ftp-Host	Webserver der jeweiligen Anwendung
-	ftp-User	Name und Kennwort f�r ftp-Zugang
-	ID-xxxx		Interne ID der Waren. Lx-ERP:
-	Shopsprache	Die Id der Voreingestellten Sprache. Nur f�r diese 
-				werden die Artikel eingestellt.
-	Bildergr��e	in Byte
-
-Das Formular abschicken. 
-
-Sollen sp�ter �nderungen durchgef�hrt werden, so mu� bei der Anmeldung 
-der ERP-ftp-User als Benutzer verwendet werden.
-
-In der Shopinstanz mu� noch eine Tabelle angelegt werden. Das wird 
-normalerweise durch das Programm condedit.php erledigt. Sollte das aus 
-irgend einem Grund nicht funktionieren, f�hren Sie dazu die
-Datei oscom.sql als Datenbankbenutzer auf die Shopinstanz aus.
-
-	$ mysql -p -u dbuser dbinstanz < xtcom.sql
-	Enter password:
-
-Ist diese Tabelle nicht angelegt, werden Kunden in der ERP immer wieder neu 
-angelegt.
-
-Fehlerquellen:
-Befinden sich ERP und Shop nicht auf dem gleichen Server, achten Sie darauf, das
-die entsprechende Datenbank von Aussen erreichbar ist. Dazu m�ssen folgende Ports 
-freigeschaltet werden:
-
-	MySQL		3306
-	PostgreSQL	5432
-
-Auch mu� auf dem Shopserver ein ftp-Dienst eingerichtet werden, wenn Bilder �ber-
-tragen werden sollen. Die Firewal ist entsprechend anzupassen.
-
-Arbeiten:
-In der ERP kann nun bei den Artikeln das H�ckchen Shop gesetzt werden.
-Bitte auch eine Warengruppe vergeben, da sonst alle Artikel in Default landen.
-Da die ERP nur eine Kategorieebene verwalten kann, mu� der ganze Kategorienpfad
-hintelegt werden. Die einzelnen Kategorien werden durch Ausrufezeichen (!) getrennt.
-
-	Hardware -> Monitore -> LCD = Hardware!Monitore!LCD
-
-Die URL f�r die Shopschnittstelle lautet:
-
-	http://webservername/pfad/xtcom/trans.php
-
-
-Die Schnittstelle kann auch in die ERP integriert werden. Dazu installieren Sie
-die Schnittstelle wie beschrieben unterhalb der ERP. 
-Erweitern Sie die menu.ini um die Eintr�ge im xtcom-Verzeichnis. z.B.:
-
-	$ cat /pfad/zu/xtcom/menu.ini >> /pfad/zu/lx-erp/menu.ini
-
-Unter dem Men�punkt Shop stehen Ihnen nun die Module shopimport_db und xtcomexport 
-zur Verf�gung.
-
-Copyright:
-Die Schnittstelle mit ihren einzelnen Bestandteilen steht unter Copyright der
-Lx-System. Die Schnittstelle und auch einzelne Programmabschnitte unterliegen 
-dem Urheberrecht sowie auch anderer Gesetze zum Schutz des geistigen Eigentums. 
-Sie d�rfen weder f�r kommerzielle Zwecke noch zur blo�en Weitergabe kopiert, 
-ver�ndert oder Dritten zug�nglich gemacht werden.
-
-				info@lx-system.de
diff --git a/xtcom/s2e.gif b/xtcom/s2e.gif
deleted file mode 100644
index cd29ee3f0..000000000
Binary files a/xtcom/s2e.gif and /dev/null differ
diff --git a/xtcom/shopimport_csv.php b/xtcom/shopimport_csv.php
deleted file mode 100644
index f953a547d..000000000
--- a/xtcom/shopimport_csv.php
+++ /dev/null
@@ -1,164 +0,0 @@
-<?php
-/***************************************************************
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.1.0
-*Shop: xtCommerce 2.0 RC 1.2
-***************************************************************/
-
-require_once "shoplib.php";
-$LAND=array("Germany"=>"D");
-
-function createCategory($name,$maingroup) {
-global $langs;
-	$newID=uniqid(rand());
-	$sql="insert into categories (categories_image,parent_id,date_added) values ('$newID',$maingroup,now())";
-	$rc=query("shop",$sql,"createCategory");
-	$sql="select * from categories where categories_image = '$newID'";
-	$rs=getAll("shop",$sql,"createCategory");
-	$id=$rs[0]["categories_id"];
-	$sql="update categories set categories_image = null where categories_id=$id";
-	$rc=query("shop",$sql,"createCategory");
-	echo "($name) ";
-	foreach ($langs as $LANG) {
-		$sql="insert into categories_description (categories_id,language_id,categories_name) values ($id,$LANG,'$name')";
-		$rc=query("shop",$sql,"createCategory");
-		if ($rc === -99) break;
-	}
-	return ($rc === -99)?false:$id;
-}
-function getCategory($name) {
-	if (empty($name)) $name="Default";
-	$tmp=split("!",$name);
-	$maingroup=0;
-	$found=true;
-	$i=0;
-	do {
-		$sql="select D.*,C.parent_id from categories C left join categories_description D on C.categories_id=D.categories_id ";
-		$sql.="where categories_name like '".$tmp[$i]."' and C.parent_id=$maingroup";
-		$rs=getAll("shop",$sql,"getCategory");
-		if ($rs[0]["categories_id"]) {
-			$maingroup=$rs[0]["categories_id"];
-			echo $maingroup.":".$rs[0]["categories_name"]." ";
-			$i++;
-		} else {
-			$found=false;
-		}
-	} while ($rs and $found and $i<count($tmp));
-	for (;$i<count($tmp); $i++) {
-		$maingroup=createCategory($tmp[$i],$maingroup);
-	}
-	return $maingroup;
-}
-function insartikel($data) {
-global $header,$tax,$defLang;
-	$newID=uniqid(rand());
-	$sql="insert into products (products_model,products_image) values ('".$data[array_search("products_model")]."','$newID')";
-	$rc=query("shop",$sql,"insartikel");
-	$sql="select * from products where products_image='$newID'";
-	$rs=getAll("shop",$sql,"insartikel");
-	$sql="update products set products_image=null,products_status=1 where products_id=".$rs[0]["products_id"];
-	$rc=query("shop",$sql,"insartikel");
-	$sql="insert into products_description (products_id,language_id,products_name) values (".$rs[0]["products_id"].",$defLang,' ')";
-	$rc=query("shop",$sql,"insartikel");
-	$sql="insert into products_to_categories (products_id,categories_id) values (".$rs[0]["products_id"].",".$data["categories_id"].")";
-	$rc=query("shop",$sql,"insartikel");
-	echo " <b>insert</b> ";
-	updartikel($data,$rs[0]["products_id"]);
-}
-function updartikel($data,$id) {
-global $header,$tax,$defLang;
-	$sql="update products set products_price=%01.2f,products_weight=%01.2f,products_tax_class_id=%d,products_last_modified=now()  where products_id=%d";
-	$sql=sprintf($sql,$data[array_search("products_price",$header)],$data[array_search("products_weight",$header)],$tax[$data[array_search("products_tax",$header)]],$id);
-	$rc=query("shop",$sql,"updartikel");
-	$sql="update products_description set products_name='%s',products_description='%s' where products_id=%d and language_id=$defLang";
-	$sql=sprintf($sql,$data[array_search("products_name",$header)],$data[array_search("products_description",$header)],$id);
-	$rc=query("shop",$sql,"insartikel");
-	$sql="update products_to_categories set categories_id=".$data[array_search("categories_id",$header)]." where products_id=$id";
-	$rc=query("shop",$sql,"insartikel");
-	echo "(".$id." ".$data[array_search("products_name",$header)].")+++<br>";
-}
-function chkartikel($data) {
-global $header,$tax;
-	$sql="select * from products P left join products_description D on P.products_id=D.products_id left join products_to_categories C on P.products_id=C.products_id where  products_model like '".$data[array_search("products_model",$header)]."' and language_id=2";
-	$rs=getAll("shop",$sql,"chkartikel");
-	if ($rs) {
-			 if ($rs[0]["products_price"]<>$data[array_search("products_price",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_weight"]<>$data[array_search("products_weight",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_name"]<>$data[array_search("products_name",$header)])		{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_description"]<>$data[array_search("products_description",$header)])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["products_tax_class_id"]<>$tax[$data[array_search("products_tax",$header)]])	{ updartikel($data,$rs[0]["products_id"]); }
-		else if ($rs[0]["categories_id"]<>$data[array_search("categories_id",$header)])		{ updartikel($data,$rs[0]["products_id"]); }
-		else { echo "(".$rs[0]["products_id"]." ".$rs[0]["products_name"].")...<br>"; };
-	} else {
-		insartikel($data);
-	}
-}
-
-$sql="select languages_id from languages";
-$rs=getAll("shop",$sql,"sellanguageid");
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$langs[]=$zeile["languages_id"];
-	}
-} else {
-	$langs[]=1;
-}
-$sql="select * from languages L left join configuration C on L.code=C.configuration_value where  configuration_key = 'DEFAULT_LANGUAGE'";
-$rs=getAll("shop",$sql,"sellanguage");
-if ($rs) {
-	$defLang=$rs[0]["languages_id"];
-} else {
-	$defLang=$SHOPlang;
-}
-$sql="select * from tax_rates";
-$rs=getAll("shop",$sql,"taxrates");
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$tax[$zeile["tax_rate"]]=$zeile["tax_class_id"];
-	}
-} else {
-	$tax[0]="";
-}
-
-if ($_FILES["csv"]["name"] || ($_POST["nofile"] && file_exists($SHOPdir)) ) {
-	if ($_FILES["csv"]["tmp_name"]) {
-		move_uploaded_file($_FILES["csv"]["tmp_name"],$SHOPdir);
-	}
-	$f=fopen($SHOPdir,"r");
-	$header=fgetcsv($f,1000,";");
-	$header[]="categories_id";
-	$data=fgetcsv($f,1000,";");
-	while (!feof($f)) {
-		$catId=getCategory($data[array_search("categories_name",$header)]);
-		$data[]=$catId;
-		chkartikel($data);
-		$data=fgetcsv($f,1000,";");
-	}
-	fclose($f);
-	echo "<a href='trans.php'>zur&uuml;ck</a>";
-} else {
-?>
-<html>
-	<head>
-		<title>Datenaustausch ERP-xt:Commerce</title>
-	</head>
-<body>
-<center>
-<br>
-<h1>Artikelimport aus csv-Datei in xt:Commerce</h1><br>
-<form name="csv" action="shopimport_csv.php" enctype="multipart/form-data" method="post">
-	<INPUT TYPE="hidden" name="MAX_FILE_SIZE" value="500000">
-	<input type="checkbox" name="nofile" value="1">Auf dem Server vorhandene Daten importieren<br>
-	Datenfile f&uuml;r Import <input type="file" name="csv"><br>
-	<input type="submit" name="ok" value="ok">
-</form>
-</center>
-<a href="trans.php">zur&uuml;ck</a>
-</body>
-</html>
-<?
-}
-?>
diff --git a/xtcom/shopimport_db.php b/xtcom/shopimport_db.php
deleted file mode 100644
index 474a00edf..000000000
--- a/xtcom/shopimport_db.php
+++ /dev/null
@@ -1,472 +0,0 @@
-<?php
-/***************************************************************
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 2.1
-*Shop: xt:Commerce 3.04
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-define("ExportMode","1");
-require_once "shoplib.php";
-
-
-/*******************************************
-* createCategoryLang($id,$lang,$name)
-* Kategorie für eine Sprache anlegen. Ist immer
-* in der gleichen Sprache, da ERP nur eine hat.
-*******************************************/
-function createCategoryLang($id,$lang,$name) {
-	$sql="insert into categories_description (categories_id,language_id,categories_name,categories_meta_title) ";
-	$sql.="values ($id,$lang,'$name','$name')";
-	$rc=query("shop",$sql,"createCategoryLang");
-	return $rc;
-}
-
-/*******************************************
-* createCategory($name,$maingroup,$Lang,$Lanuages)
-* Eine Kategorie in der default-Sprache anlegen
-*******************************************/
-function createCategory($name,$maingroup,$Lang,$Languages) {
-	echo "Kategorie: $name<br>";
-	//Kategorie nicht vorhanden, anlegen
-	$newID=uniqid(rand());
-	$sql="insert into categories (categories_image,parent_id,date_added) values ('$newID',$maingroup,now())";
-	$rc=query("shop",$sql,"createCategory_1");
-	if ($rc === -99) return false;
-	$sql="select * from categories where categories_image = '$newID'";
-	$rs=getAll("shop",$sql,"createCategory_2");
-	$id=$rs[0]["categories_id"];
-	$sql="update categories set categories_image = null where categories_id=$id";
-	$rc=query("shop",$sql,"createCategory_3");
-	if ($rc === -99) return false;
-	createCategoryLang($id,$Lang,$name);
-	if ($Languages) foreach ($Languages as $erp=>$shop) {
-		if ($Lang<>$shop) {
-			createCategoryLang($id,$shop,$name);
-		}
-	}
-	return ($rc !== -99)?$id:false;
-}
-
-/*******************************************
-* getCategory($name,$Lang,$Languages)
-* gibt es die Kategorie schon?
-*******************************************/
-function getCategory($name,$Lang,$Languages) {
-	if (empty($name)) $name="Default";
-	$tmp=split("!",$name);
-	$maingroup=0;
-	$found=true;
-	$i=0;
-	do {
-		$sql="select D.*,C.parent_id from categories C left join categories_description D on C.categories_id=D.categories_id ";
-		$sql.="where (categories_name = '".$tmp[$i]."' or categories_meta_title ='".$tmp[$i]."') and ";
-		$sql.="C.parent_id=$maingroup and language_id=$Lang";
-		$rs=getAll("shop",$sql,"getCategory");
-		if ($rs) {
-			$maingroup=$rs[0]["categories_id"];
-			$i++;
-		} else {
-			$found=false;
-		}
-	} while ($rs and $found and $i<count($tmp));
-	for (;$i<count($tmp); $i++) {
-		$maingroup=createCategory($tmp[$i],$maingroup,$Lang,$Languages);
-	}
-	return $maingroup;
-}
-
-/*******************************************
-* getCategoryLang($name,$Lang,$defLang,$Languages
-* ohne Funktion
-*******************************************/
-function getCategoryLang($name,$Lang,$defLang,$Languages) {
-	if (empty($name)) $name="Default";
-	$tmp=split("!",$name);
-	$tmpname=$tmp[count($tmp)-1];
-	$i=0;
-	do {
-		$sql="select * from categories_description ";
-		$sql.="where (categories_name = '".$tmp[$i]."' or categories_meta_title ='".$tmp[$i]."') and language_id=$Lang";
-		$rs=getAll("shop",$sql,"getCategoryLang");
-		if ($rs) {
-			$i++;
-		} else {
-			$found=false;
-		}
-	} while ($rs and $found and $i<count($tmp));
-	for (;$i<count($tmp); $i++) {
-		$id=getCategory($tmp[$i],$Lang,false);
-		createCategoryLang($id,$shop,$tmpname);
-	}
-	return $id;
-}
-
-/*******************************************
-* bilder($width,$height,$dest
-* Bild in der gewünschten Größe erzeugen
-*******************************************/
-function bilder($width,$height,$dest) {
-	//Wenn auf dem Server die php_imagick nicht installiert werden kann:
-        //$rc=@exec("/usr/bin/convert -resize ".$width."x".$height." tmp/tmp.file_org tmp/tmp.file_$dest",$aus,$rc2);
-        //if ($rc2>0) { echo "[Bildwandeln: $image.$dest]<br>";  return false; };
-
-	if (!function_exists("imagick_readimage")) { echo "Imagick-Extention nicht installiert"; return false; };
-	$handle=imagick_readimage("./tmp/tmp.file_org");
-	if (!$handle) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Lesen: $reason<BR>\n" ; flush();
-		return false;
-	}
-	if (!imagick_resize( $handle, $width, $height, IMAGICK_FILTER_UNKNOWN, 0)) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Resize: $reason<BR>\n" ;	flush();
-		return false;
-	}
-	if (!imagick_writeimage( $handle,"./tmp/tmp.file_$dest")) {
-		$reason      = imagick_failedreason( $handle ) ;
-		print "Schreiben: $reason<BR>\n" ; 	flush();
-		return false;
-	}
-	return true;
-}
-
-/*******************************************
-* uploadImage($image,$id)
-* Ein Bild zum Shop übertragen
-*******************************************/
-function uploadImage($image,$id) {
-global $ERPftphost,$ERPftpuser,$ERPftppwd,$ERPimgdir,$SHOPftphost,$SHOPftpuser,$SHOPftppwd,
-		$SHOPimgdir,$picsize;
-	$picdest = array("thumb"=>"thumbnail_images","info"=>"info_images","popup"=>"popup_images","org"=>"original_images");
-	$ok=true;
-	// Bilder holen
-	if ($ERPftphost=="localhost")
-	{
-		$aus=""; $rc2=0;
-		if (is_file($ERPimgdir."/".$image)) {
-			$rc3=@exec("cp $ERPimgdir/$image ./tmp/tmp.file_org",$aus,$rc2);
-			if ($rc2>0) { $ok=false; echo "[Downloadfehler: $image]<br>"; };
-		} else {
-                        echo "[Downloadfehler: $ERPimgdir/$image nicht gefunden]";
-                        return false;
-                }
-	} else {
-		$conn_id = ftp_connect($ERPftphost);
-		if ($conn_id==false) {
-			echo "[Kein FTP-Verbindung ERP]";
-			return false;
-		}
-		ftp_login($conn_id,$ERPftpuser,$ERPftppwd);
-		$src=$ERPimgdir."/".$image;
-		$upload=ftp_get($conn_id,"tmp/tmp.file_org","$src",FTP_BINARY);
-		if (!$upload) { $ok=false; echo "[Ftp Downloadfehler: $image]<br>";};
-		ftp_quit($conn_id);
-	}
-	if ($ok) {
-		//Bildergrößen erzeugen
-		if (!bilder($picsize["PRODUCT_IMAGE_THUMBNAIL_WIDTH"],$picsize["PRODUCT_IMAGE_THUMBNAIL_HEIGHT"],"thumb")) return false;
-		if (!bilder($picsize["PRODUCT_IMAGE_INFO_WIDTH"],$picsize["PRODUCT_IMAGE_INFO_HEIGHT"],"info")) return false;
-		if (!bilder($picsize["PRODUCT_IMAGE_POPUP_WIDTH"],$picsize["PRODUCT_IMAGE_POPUP_HEIGHT"],"popup")) return false;
-		$name=(strrpos($image,"/")>0)?substr($image,strrpos($image,"/")+1):$image;
-		//zum Shop übertragen
-		if ($SHOPftphost=="localhost") {
-			foreach ($picdest as $key => $val) {
-				if (is_dir($SHOPimgdir."/".$val."/")) {
-					$src=$SHOPimgdir."/".$val."/".$name;
-					$rc2=0; $aus="";
-					$rc3=@exec("cp ./tmp/tmp.file_$key $src",$aus,$rc2);
-					print "!$rc2,$rc3!";
-					if ($rc2>0) { $ok=false; echo "[Uploadfehler: $src]"; };
-				} else {
-					echo "[Uploadfehler: $val nicht gefunden]";
-					return false;
-				}
-			}
-		} else {
-			$conn_id = ftp_connect($SHOPftphost);
-			if ($conn_id==false) {
-				echo "[Kein FTP-Verbindung Shop]";
-				return false;
-			}
-			ftp_login($conn_id,$SHOPftpuser,$SHOPftppwd);
-			foreach ($picdest as $key => $val) {
-				$src=$SHOPimgdir."/".$val."/".$name;
-				$upload=ftp_put($conn_id,"$src","tmp/tmp.file_".$key,FTP_BINARY);
-				if (!$upload) { $ok=false; echo $key."[FTP Uploadfehler $src]<br>";};
-			}
-			ftp_quit($conn_id);
-		}
-		if ($ok) {
-			$sql="update products set products_image='%s',products_last_modified=now() where products_id=%d";
-			$sql=sprintf($sql,$name,$id);
-			$rc=query("shop",$sql,"uploadImage");
-			if ($rc === -99) return false;
-			echo "i";
-		}
-	}
-	return true;
-}
-
-/*******************************************
-* insartikel($data,$defLang
-* Einen neuen Artikel im Shop anlegen
-*******************************************/
-function insartikel($data,$defLang) {
-	$newID=uniqid(rand());
-	$sql="insert into products (products_model,products_image) values ('".$data["partnumber"]."','$newID')";
-	$rc=query("shop",$sql,"insartikel_1");
-	if ($rc === -99) return false;
-	$sql="select * from products where products_image='$newID'";
-	$rs=getAll("shop",$sql,"insartikel_2");
-	$sql="update products set products_image=null where products_id=".$rs[0]["products_id"];
-	$rc=query("shop",$sql,"insartikel_3");
-	$sql="insert into products_to_categories (products_id,categories_id) values ";
-	$sql.="(".$rs[0]["products_id"].",".$data["categories_id"].")";
-	$rc=query("shop",$sql,"insartikel_4");
-	if ($rc === -99) return false;
-	echo " + ";
-	updartikel($data,$rs[0]["products_id"],$defLang);
-	return $rs[0]["products_id"];
-}
-
-/*******************************************
-*
-*
-*******************************************/
-function updartikel($data,$id,$defLang) {
-global $tax,$KDGrp;
-	echo $id." ";
-	$sql="update products set products_status=1,products_price=%01.2f,products_weight=%01.2f,";
-	$sql.="products_tax_class_id=%d,products_last_modified=now(),products_quantity=%d where products_id=%d";
-	$price=($data["sellprice"]>0)?$data["sellprice"]:$data["stdprice"];
-	$sql=sprintf($sql,$price,$data["weight"],$tax[sprintf("%1.4f",$data["rate"])],$data["onhand"],$id);
-	$rc=query("shop",$sql,"updartikel_1");
-	$sql="update products_to_categories set categories_id=".$data["categories_id"]." where products_id=$id";
-	$rc=query("shop",$sql,"updartikel_2");
-	echo "~";
-	if ($KDGrp>0) personal_offer ($data["altprice"],$id);
-	$sql="select * from products_description where products_id=$id and language_id=$defLang";
-	$rs=getAll("shop",$sql,"updartikel_3");
-	if ($rs) {  // bestehende Sprachen abgleichen
-		$sql="update products_description set products_name='%s',products_description='%s' where ";
-		$sql.="products_id=%d and language_id=$defLang";
-		$sql=sprintf($sql,$data["description"],$data["notes"],$id);
-		echo "l";
-	} else {  // neue Sprache einfügen
-		$sql="insert into products_description (products_id,products_name,products_description,language_id) ";
-		$sql.="values (%d,'%s','%s',%d)";
-		$sql=sprintf($sql,$id,$data["description"],$data["notes"],$defLang);
-		echo "L";
-	}
-	$rc=query("shop",$sql,"updartikel_4");
-	if ($rc === -99) return false;
-}
-
-/*******************************************
-* personal_offer ($personal_offer,$products_id)
-* Spezialangebote anlegen
-*******************************************/
-function personal_offer ($personal_offer,$products_id) {
-global $KDGrp;
-	$sql="select * from personal_offers_by_customers_status_$KDGrp where ";
-	$sql.="products_id=$products_id order by quantity limit 1";
-	$rs=getAll("shop",$sql,"personal_offer_1");
-	if ($rs) {
-		if ($personal_offer) {
-			$sql="update personal_offers_by_customers_status_$KDGrp ";
-			$sql.="set personal_offer=$personal_offer where price_id = ".$rs[0]["price_id"];
-			echo "p";
-		} else {
-			$sql="delete from personal_offers_by_customers_status_$KDGrp where price_id = ".$rs[0]["price_id"];
-			echo "q";
-		}
-		$rc=query("shop",$sql,"personal_offer_2");
-	} else {
-		if ($personal_offer) {
-			$sql="insert into personal_offers_by_customers_status_$KDGrp ";
-			$sql.="(price_id,products_id,quantity,personal_offer) ";
-			$sql.="values (0,$products_id,1,$personal_offer)";
-			$rc=query("shop",$sql,"personal_offer_3");
-			if ($rc === -99) return false;
-			echo "P";
-		}
-	};
-}
-
-/*******************************************
-* chkartikellang($data,$Lang)
-* Gibt es den Artikel und hat er sich geändert
-*******************************************/
-function chkartikellang($data,$Lang) {
-global $tax,$KDGrp;
-	if ($data["partnumber"]=="") { echo "Artikelnummer fehlt!<br>"; return;};
-	echo $data["partnumber"]." ".$data["translation"]." -> ";
-	$sql ="select P.products_id from products P left join products_description PD on P.products_id=PD.products_id where ";
-	$sql.="products_model like '".$data["partnumber"]."' and language_id=$Lang";
-	$rs=getAll("shop",$sql,"chkartikellang");
-	if (count($rs)>0) {
-		$sql="update products_description set products_name='".$data["translation"]."', products_description='".$data["longdescription"]."' ";
-		$sql.="where products_id='".$rs[0]["products_id"]."' and language_id=$Lang";
-		$rc=query("shop",$sql,"chkartikellang_u");
-	} else {
-		$sql ="select products_id from products where products_model like '".$data["partnumber"]."'";
-		$rs=getAll("shop",$sql,"chkartikellang");
-		$sql="insert into products_description (products_id,language_id,products_name,products_description) values (";
-		$sql.=$rs[0]["products_id"].",$Lang,'".$data["translation"]."','".$data["longdescription"]."')";
-		$rc=query("shop",$sql,"chkartikellang_i");
-		if ($rc === -99) return false;
-	}
-	echo $rs[0]["products_id"]."<br>\n";
-	return true;
-}
-
-/*******************************************
-* chkartikel($data,$defLang)
-* Hat sich der Artikel verändert
-*******************************************/
-function chkartikel($data,$defLang) {
-global $tax,$erptax,$shop2erp,$KDGrp,$GeoZone,$nopic;
-	if ($data["partnumber"]=="") { echo "Artikelnummer fehlt!<br>"; return;};
-	if ($data["image"]) {
-		$data["picname"]=(strrpos($data["image"],"/")>0)?substr($data["image"],strrpos($data["image"],"/")+1):$data["image"];
-	} else if ($nopic) {
-		$data["picname"]=(strrpos($nopic,"/")>0)?substr($nopic,strrpos($nopic,"/")+1):$nopic;
-		$data["image"]=$nopic;
-	}
-	$data["onhand"]=floor($data["onhand"]);
-	echo $data["partnumber"]." ".$data["description"]." -> ";
-	$sql ="select * from products where products_model like '".$data["partnumber"]."'";
-	$rs=getAll("shop",$sql,"chkartikel");
-	$data["rate"]=$erptax[$data["bugru"]]["rate"];
-	if ($rs) {
-		updartikel($data,$rs[0]["products_id"],$defLang);
-		if ($rs[0]["products_image"]<>$data["picname"] and $data["picname"]) uploadImage($data["image"],$rs[0]["products_id"]);
-	} else {
-		$id=insartikel($data,$defLang);
-		if ($data["image"]) uploadImage($data["image"],$id);
-	}
-	echo "<br>\n";
-}
-
-/*******************************************
-* Grafiken
-*******************************************/
-//Defaultwerte
-$picsize= array("PRODUCT_IMAGE_THUMBNAIL_WIDTH" => 120,"PRODUCT_IMAGE_THUMBNAIL_HEIGHT" => 80,
-		"PRODUCT_IMAGE_INFO_WIDTH" => 200,"PRODUCT_IMAGE_INFO_HEIGHT" => 160,
-		"PRODUCT_IMAGE_POPUP_WIDTH" => 300,"PRODUCT_IMAGE_POPUP_HEIGHT" => 240,"IMAGE_QUALITY" => 80);
-//persönliche Werte
-foreach ($picsize as $key => $val) {
-	$sql=sprintf("select configuration_value from configuration where configuration_key='%s'",$key);
-	$rs=getAll("shop",$sql,"Picsize");
-	if ($rs[0]["configuration_value"]>0) $picsize[$key]=$rs[0]["configuration_value"];
-}
-
-/*******************************************
-* Steuern
-*******************************************/
-//Steuertabelle ERP
-$sql ="select  BG.id as bugru,T.rate,TK.startdate from buchungsgruppen BG left join chart C ";
-$sql.="on BG.income_accno_id_0=C.id left join taxkeys TK on TK.chart_id=C.id left join tax T ";
-$sql.="on T.id=TK.tax_id where TK.startdate <= now()";
-$rs=getAll("erp",$sql,"Tax ERP");
-$erptax=array();
-foreach ($rs as $row) {
-	if ($erptax[$row["bugru"]]["startdate"]<$row["startdate"]) {
-		$erptax[$row["bugru"]]["startdate"]=$row["startdate"];
-		$erptax[$row["bugru"]]["rate"]=$row["rate"]*100;
-	}
-}
-
-//Steuerzone Shop
-$sql="select GZ.geo_zone_id from configuration C, zones_to_geo_zones GZ ";
-$sql.="where C.configuration_key='STORE_COUNTRY' and GZ.zone_country_id=C.configuration_value";
-$rs=getAll("shop",$sql,"GZ");
-if ($rs) {
-	$GeoZone=$rs[0]["geo_zone_id"];
-} else {
-	echo "Steuerzone nicht gefunden";
-	exit;
-}
-
-//Steuersätze
-$sql="select * from tax_rates where tax_zone_id=$GeoZone";
-$rs=getAll("shop",$sql,"tax_rates");
-if ($rs) {
-	foreach ($rs as $zeile) {
-		$tax[$zeile["tax_rate"]]=$zeile["tax_class_id"];
-	}
-} else {
-	$tax[0]="";
-}
-
-/*******************************************
-* Sprache
-*******************************************/
-if (empty($Language) || !$Language) {
-	echo "Keine Sprachzuordnung definiert!";
-	exit;
-}
-
-//Default Shopsprache ermitteln
-$sql="select * from languages L left join configuration C on L.code=C.configuration_value ";
-$sql.="where  configuration_key = 'DEFAULT_LANGUAGE'";
-$rs=getAll("shop",$sql,"DefaultLang");
-
-if ($rs) {
-        $ShopdefaultLang=$rs[0]["languages_id"];
-	if ($SHOPdefaultlang<>$ShopdefaultLang) {
-                echo "Defaultsprache im Shop wurde geändert ($SHOPdefaultlang<>$ShopdefaultLang)";
-		exit;
-	}
-} else  {
-	echo "Keine Defaultsprache im Shop eingestellt.";
-	exit;
-}
-
-$Languages=array();
-foreach ($Language as $Langrow) {
-	if ($Langrow["SHOP"]>0 and $Langrow["ERP"]>0) $Languages[$Langrow["ERP"]]=$Langrow["SHOP"];
-}
-
-/*******************************************
-* Import starten
-*******************************************/
-$artikel=shopartikel(); //array_keys($Languages));
-
-echo "Artikelexport ERP -&gt; xt:Commerce (Standardsprache $ShopdefaultLang): ".count($artikel)." Artikel markiert.<br>";
-
-if ($artikel) { //Mit jedem Artikel in der Defaultsprache:
-	foreach ($artikel as $data) {
-		//Kategorie abfragen/anlegen
-		$data["categories_id"]=getCategory($data["partsgroup"],$ShopdefaultLang,$Languages);
-		chkartikel($data,$ShopdefaultLang,false);
-	}
-
-	foreach ($Languages as $erplang=>$shoplang) { //Mit jeder weiteren Sprache
-		$artikel=shopartikellang($erplang,$SpracheAlle);
-		echo "Shopsprache: $shoplang<br>";
-		if ($artikel) {
-			foreach ($artikel as $data) {
-				//Kategorie abfragen
-				$data["categories_id"]=getCategory($data["partsgroup"],$shoplang,$Languages);
-				if ($SpracheAlle) {
-					if ($data["translation"]=="") $data["translation"]=$data["description"];
-					if ($data["longdescription"]=="") $data["longdescription"]=$data["notes"];
-				}
-				chkartikellang($data,$shoplang);
-			}
-		}
-	}
-} else {
-	if ($debug) {
-		$log=fopen("tmp/shop.log","a");
-		fputs($log,$nun.": Fehler\n");
-	}
-}
-require ("diff.php");
-
-?>
diff --git a/xtcom/shoplib.php b/xtcom/shoplib.php
deleted file mode 100755
index ebbbf369b..000000000
--- a/xtcom/shoplib.php
+++ /dev/null
@@ -1,328 +0,0 @@
-<?php
-
-
-$login=$_GET["login"];
-$debug=false;
-#require_once "DB.php";
-require_once "MDB2.php";
-
-if (file_exists ("conf$login.php")) {
-	require "conf$login.php";
-} else {
-	require "conf.php";
-}
-
-$landarray=array("DEUTSCHLAND"=>"D","STEREICH"=>"A","OESTEREICH"=>"A","SCHWEIZ"=>"CH");
-$taxarray=array("D"=>0,"A"=>1,"CH"=>2);
-$defaultland="D";
-$taxid=0;
-$log=false;
-$erp=false;
-$shop=false;
-
-//$PGdns = "user='$ERPuser' password='$ERPpass' host='$ERPhost' dbname='$ERPdbname' port='$ERPport'";
-
-$ERPdns= array('phptype'  => 'pgsql',
-               'username' => $ERPuser,
-               'password' => $ERPpass,
-               'hostspec' => $ERPhost,
-               'database' => $ERPdbname,
-               'port'     => $ERPport);
-
-$SHOPdns=array('phptype'  => 'mysql',
-               'username' => $SHOPuser,
-               'password' => $SHOPpass,
-               'hostspec' => $SHOPhost,
-               'database' => $SHOPdbname,
-               'port'     => $SHOPport);
-
-/****************************************************
-* Debugmeldungen in File schreiben
-****************************************************/
-if ($debug) { $log=fopen("tmp/shop.log","a"); } // zum Debuggen
-else { $log=false; };
-
-
-
-/****************************************************
-* Shopverbindung aufbauen
-****************************************************/
-/*$shop=DB::connect($SHOPdns);
-if (!$shop) shopFehler("",$shop->getDebugInfo());
-if (DB::isError($shop)) {
-	$nun=date("Y-m-d H:i:s");
-	if ($log) fputs($log,$nun.": Shop-Connect\n");
-	shopFehler("",$shop->getDebugInfo());
-	die ($shop->getDebugInfo());
-};*/
-$options = array();
-//print_r($SHOPdns);
-$shop=MDB2::factory($SHOPdns,$options);
-//echo "<pre>"; print_r($shop); echo "</pre>";
-if (!$shop) shopFehler("",$shop->getMessage());
-if (PEAR::isError($shop)) {
-        $nun=date("Y-m-d H:i:s");
-        if ($log) fputs($log,$nun.": Shop-Connect\n");
-        shopFehler("",$shop->getMessage());
-        die ($shop->getMessage());
-};
-if (ExportMode == "1") $shop->setCharset('utf8');
-$shop->setFetchMode(MDB2_FETCHMODE_ASSOC);
-
-
-/****************************************************
-* ERPverbindung aufbauen
-****************************************************/
-/*$erp=DB::connect($ERPdns);
-if (!$erp) shopFehler("",$erp->getDebugInfo());
-if (DB::isError($erp)) {
-	$nun=date("Y-m-d H:i:s");
-	if ($log) fputs($log,$nun.": ERP-Connect\n");
-	shopFehler("",$erp->getDebugInfo());
-	die ($erp->getDebugInfo());
-} else {
-	$erp->autoCommit(true);
-};*/
-$options = array('result_buffering' => false,);
-$erp = MDB2::factory($ERPdns,$options);
-//echo "<pre>"; print_r($erp); echo "</pre>";
-if (!$erp) shopFehler("",$erp->getMessage());
-if (PEAR::isError($erp)) {
-        $nun=date("Y-m-d H:i:s");
-        if ($log) fputs($log,$nun.": ERP-Connect\n");
-        shopFehler("",$erp->getMessage());
-        die ($erp->getMessage());
-} else {
-        if ($erp->autocommit) $erp->autocommit();
-};
-
-if ($SHOPchar and ExportMode != "1") {
-    $erp->setCharset($SHOPchar);
-} 
-$erp->setFetchMode(MDB2_FETCHMODE_ASSOC);
-
-
-
-/****************************************************
-* SQL-Befehle absetzen
-****************************************************/
-function query($db,$sql,$function="--") {
- 	$nun=date("d.m.y H:i:s");
- 	//if ($db<>"shop") { echo "$sql!$db!<br>"; flush(); };
- 	if ($GLOBALS["log"]) fputs($GLOBALS["log"],$nun.": ".$function."\n".$sql."\n");
- 	$rc=$GLOBALS[$db]->query($sql);
- 	if ($GLOBALS["log"]) fputs($GLOBALS["log"],print_r($rc,true)."\n");
-    if(PEAR::isError($rc)) {
- 	//if ($rc!==1) {
- 	    return -99;
- 	} else {
-            return true;
- 	}
-}
-
-/****************************************************
-* Datenbank abfragen
-****************************************************/
-function getAll($db,$sql,$function="--") {
-	$nun=date("d.m.y H:i:s");
-	if ($GLOBALS["log"]) fputs($GLOBALS["log"],$nun.": ".$function."\n".$sql."\n");
-	//$rs=$GLOBALS[$db]->getAll($sql,DB_FETCHMODE_ASSOC);
-	$rs=$GLOBALS[$db]->queryAll($sql);
-	//if ($rs["message"]<>"") {
-    if ($rs->message<>"") {
-	       	if ($GLOBALS["log"]) fputs($GLOBALS["log"],print_r($rs,true)."\n");
-		return false;
-	} else {
-       	 	return $rs;
-	}
-}
-
-/****************************************************
-* shopFehler
-* in: sql,err = string
-* out:
-* Fehlermeldungen ausgeben
-*****************************************************/
-function shopFehler($sql,$err) {
-global $showErr;
-	if ($showErr)
-		echo "</td></tr></table><font color='red'>$sql : $err</font><br>";
-}
-
-/****************************************************
-* Nächste Auftragsnummer (ERP) holen
-****************************************************/
-function getNextAnr() {
-	$sql="select * from defaults";
-	$sql1="update defaults set sonumber=";
-	$rs2=getAll("erp",$sql,"getNextAnr");
-	if ($rs2[0]["sonumber"]) {
-		$auftrag=$rs2[0]["sonumber"]+1;
-		$rc=query("erp",$sql1.$auftrag,"getNextAnr");
-		if ($rc === -99) {
-			echo "Kann keine Auftragsnummer erzeugen - Abbruch";
-			exit();
-		}
-		return $auftrag;
-	} else {
-		return false;
-	}
-}
-
-/****************************************************
-* Nächste Kundennummer (ERP) holen
-****************************************************/
-function getNextKnr() {
-	$sql="select * from defaults";
-	$sql1="update defaults set customernumber='";
-	$rs2=getAll("erp",$sql,"getNextKnr");
-	if ($rs2[0]["customernumber"]) {
-		$kdnr=$rs2[0]["customernumber"]+1;
-		$rc=query("erp",$sql1.$kdnr."'","getNextKnr");
-		if ($rc === -99) {
-			echo "Kann keine Kundennummer erzeugen - Abbruch";
-			exit();
-		}
-		return $kdnr;
-	} else {
-		return false;
-	}
-}
-
-
-//$shopdata=array("firma"=>"","abteilung"=>"","vorname"=>"","nachname"=>"","strasse"=>"","plz"=>"","ort"=>"","telefon"=>"","email"=>"","land"=>"","fax"=>"","notiz"=>"","postfach"=>"")
-$shopdata=array(	"id"=>"customers_id","kdnr"=>"customers_cid","bid"=>"orders_id", "anrede"=>" customers_gender",
-			"firma"=>"customers_company", "nachname"=>"customers_lastname", "vorname"=>"customers_firstname",
-			"strasse"=>"customers_street_address","plz"=>"customers_postcode","ort"=>"customers_city","land"=>"customers_country",
-			"telefon"=>"customers_phone","email"=>"customers_email_address","fax"=>"Fax","notiz"=>"comments",
-
-			"netto"=>"ot_subtotal","steuer"=>"ot_tax","datum"=>" date_purchased","bemerkung"=>"comments",
-			"artnr"=>"products_id","preis"=>"final_price","artikeltxt"=>" products_name","menge"=>" products_quantity");
-
-$shopartikel=array(	"id"=>"Artikel_ID","artnr"=>"Artikel_Nr","arttxt"=>"Name","artbeschr"=>"Beschreibung","gruppe"=>"Kategorie_ID",
-			"preis"=>"Preis","preis2"=>"Haendlerpreis","preis3"=>"Aktionspreis","gewicht"=>"Gewicht",
-			"bild"=>"Bild_gross","bestand"=>"Lagerbestand","minbestand"=>"Mindestlagermenge","steuer"=>"MwSt_Satz");
-
-
-/****************************************************
-* Ab hier Artikelexport aus ERP
-****************************************************/
-// Ab hier Artikelexport aus ERP nur eine Sprache
-function shopartikellang($lang,$alle) {
-	$sql="SELECT P.partnumber,L.translation,P.description,L.longdescription,P.notes,PG.partsgroup ";
-	$sql.="FROM parts P left join translation L on L.parts_id=P.id left join partsgroup PG on PG.id=P.partsgroup_id ";
-	$sql.="WHERE P.shop='t' and (L.language_id = $lang";
-	if ($alle) {
-		$sql.=" or L.language_id is Null)";
-	} else { $sql.=")"; };
-	$rs=getAll("erp",$sql,"shopartikellang");
-	$data=array();
-	if ($rs) foreach ($rs as $row) {
-		if (!$data[$row["partnumber"]])	$data[$row["partnumber"]]=$row;
-	}
-	return $data;
-}
-// Ab hier alle Artikelexport aus ERP Defaultsprache
-function shopartikel() {
-global $stdprice,$altprice;
-	if ($stdprice>0) {
-		$sql="SELECT P.partnumber,P.description,P.weight,(t.rate * 100) as rate,G.price as sellprice,P.sellprice as stdprice, ";
-		$sql.="PG.partsgroup,P.notes,P.image,P.onhand,G.pricegroup_id,P.buchungsgruppen_id as bugru FROM ";
-		$sql.="chart c left join tax t on c.taxkey_id=t.taxkey, parts P left join partsgroup PG on ";
-		$sql.="PG.id=P.partsgroup_id left join prices G on G.parts_id=P.id ";
-		$sql.="left join buchungsgruppen B  on P.buchungsgruppen_id = B.id ";
-		$sql.="where P.shop='t' and c.id=B.income_accno_id_0  and ";
-		$sql.="(G.pricegroup_id=$stdprice or G.pricegroup_id=$altprice or G.pricegroup_id is null) ";
-		$sql.="order by P.partnumber";
-	} else {
-		$sql="SELECT P.partnumber,P.description,P.weight,(t.rate * 100) as rate,P.sellprice,PG.partsgroup,";
-		$sql.="P.notes,P.image,P.onhand,P.buchungsgruppen_id as bugru FROM ";
-		$sql.="chart c left join tax t on c.taxkey_id=t.taxkey, parts P left join partsgroup PG on ";
-		$sql.="PG.id=P.partsgroup_id left join buchungsgruppen B  on P.buchungsgruppen_id = B.id ";
-		$sql.="WHERE P.shop='t'  and c.id=B.income_accno_id_0";
-	}
-	$rs=getAll("erp",$sql,"shopartikel");
-	$i=0;
-	$data=array();
-	if ($rs) foreach ($rs as $row) {
-		if (!$data[$row["partnumber"]])	$data[$row["partnumber"]]=$row;
-		if ($row["pricegroup_id"]==$altprice) {
-			$data[$row["partnumber"]]["altprice"]=($row["sellprice"])?$row["sellprice"]:$row["stdprice"];
-		} else {
-			$data[$row["partnumber"]]["sellprice"]=($row["sellprice"])?$row["sellprice"]:$row["stdprice"];
-		}
-		$i++;
-	}
-	
-	return $data;
-}
-
-/****************************************************
-* Artikelexport in ERP importieren
-****************************************************/
-function insertArtikel($data) {
-global $shopartikel;
-	foreach ($data as $row) {
-		$pg=$GLOBALS["warengruppen"][$row[$shopartikel["gruppe"]]]["partsgroup"];
-		$bg=$GLOBALS["buchungsgruppen"][sprintf("%0.2f",$row[$shopartikel["steuer"]])];
-		$artnr=($row[$shopartikel["artnr"]])?$row[$shopartikel["artnr"]]:getArtnr();
-		$sqltmp="insert into parts (partnumber,description,notes,weight,onhand,rop,image,sellprice,unit,partsgroup_id,buchungsgruppen_id) ";
-		$sqltmp.="values ('%s','%s','%s',%0.5f,%0.5f,%0.5f,'%s',%0.5f,'%s',%d,%d)";
-		$sql=sprintf($sqltmp,$artnr,$row[$shopartikel["arttxt"]],$row[$shopartikel["artbeschr"]],
-				$row[$shopartikel["gewicht"]],$row[$shopartikel["bestand"]],$row[$shopartikel["minbestand"]],
-				$row[$shopartikel["bild"]],$row[$shopartikel["preis"]],$row[$shopartikel["einheit"]],$pg,$bg);
-		$rc=query("erp",$sql,"insertArtikel");
-		if ($rc === -99) {
-			echo $row[$shopartikel["id"]]." ".$row[$shopartikel["arttxt"]]." nicht importiert<br>";
-		} else {
-			echo "";
-		}
-		echo $sql."<br>";
-	}
-}
-
-/****************************************************
-* Nächste Artikelnummer (ERP) holen
-****************************************************/
-function getArtnr() {
-	$sql="select * from defaults";
-	$sql1="update defaults set articlenumber='";
-	if ($rc === -99) {
-		echo "Kann keine Artikelnummer erzeugen - Abbruch";
-		exit();
-	}
-	$rs2=getAll("erp",$sql,"getArtnr");
-	$artnr=$rs2[0]["articelnumber"]+1;
-	$rc=query("erp",$sql1.$artnr."'","getArtnr");
-	if ($rc === -99) {
-		echo "Kann keine Artikelnummer erzeugen - Abbruch";
-		$rc=query("erp","ROLLBACK","getArtnr");
-		exit();
-	}
-	return $artnr;
-}
-
-$buchungsgruppen=array();
-$warengruppen=array();
-
-function getBugru() {
-	$sql ="select B.id,tax.rate from buchungsgruppen B left join chart on income_accno_id_0=chart.id left join taxkeys T on ";
-	$sql.="T.chart_id=income_accno_id_0 left join tax on tax.id=T.tax_id where T.startdate<=now()";
-	$rs=getAll("erp",$sql,"getBugru");
-	if ($rs) foreach ($rs as $row) {
-		$steuer=sprintf("%0.2f",$row["rate"]*100);
-		$GLOBALS["buchungsgruppen"][$steuer]=$row["id"];
-	}
-}
-
-$wg=1000;
-
-function insPartgroup($kat) {
-	$sql="insert into partsgroup () value ()";
-	$GLOBALS["wg"]++;
-	//$rc=query("erp",$sql,"insPartgroup");
-	if ($rc === -99) { return false; }
-	else { return $GLOBALS["wg"]; }
-}
-getBugru();
-?>
diff --git a/xtcom/tmp/.dummy b/xtcom/tmp/.dummy
deleted file mode 100644
index e69de29bb..000000000
diff --git a/xtcom/trans.php b/xtcom/trans.php
deleted file mode 100644
index 6cfe8b634..000000000
--- a/xtcom/trans.php
+++ /dev/null
@@ -1,128 +0,0 @@
-<?
-/***************************************************************
-* $Id: trans.php,v 1.1 2004/06/29 08:50:30 hli Exp $
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.0.0
-*Shop: xt:Commerce 2.2
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-$login=($_GET["login"])?$_GET["login"]:$_POST["login"];
-require_once "DB.php";
-if (file_exists ("conf$login.php")) {
-                require "conf$login.php";
-        } else {
-                require "conf.php";
-        }
-$ERPdsn = array(
-                    'phptype'  => 'pgsql',
-                    'username' => $ERPuser,
-                    'password' => $ERPpass,
-                    'hostspec' => $ERPhost,
-                    'database' => $ERPdbname,
-                    'port'     => $ERPport
-                );
-
-$LAND=array("Germany"=>"D");
-$db=@DB::connect($SHOPdns);
-if (DB::isError($db)||!$db) { $shop="<font color='red'>Fehler</font>"; } else { $shop="ok"; };
-$db2=DB::connect($ERPdsn);
-if (DB::isError($db2)||!$db2) { $erp="<font color='red'>Fehler</font>"; } else { $erp="ok"; };
-
-?>
-<html>
-	<head>
-		<title>Datenaustausch ERP-xt:Commerce</title>
-	</head>
-<body>
-<center>
-<table>
-	<tr>
-		<td colspan="2">
-			Eine direkte Verbindung beider Datenbanken ist erforderlich!<br>
-			Folgende Verbindungsdaten wurden gefunden:
-		</td>
-	</tr>
-	<tr>
-		<td>
-			<b>Lx-ERP</b>
-		</td>
-		<td><?= $erp ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank-Server</td>
-		<td><?= $ERPhost ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank</td>
-		<td><?= $ERPdbname ?></td>
-	</tr>
-	<tr>
-		<td>
-			<b>xt:Commerce</b>
-		</td>
-		<td><?= $shop ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank-Server</td>
-		<td><?= $SHOPhost ?></td>
-	</tr>
-	<tr>
-		<td>Datenbank</td>
-		<td><?= $SHOPdbname ?></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td align="center"><a href="shopimport_db.php"><img src="e2s.gif" border="0"></a></td>
-		<td align="center"><a href="xtcomexport.php"><img src="s2e.gif" border="0"></a></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			F&uuml;r den Export der Artikeldaten aus der ERP in eine CSV-Datei<br>
-			oder den Import der Artikeldaten in den Shop ist nur die Verbindung<br>
-			zur entsprechenden	Datenbank notwendig.<br>
-			Die CSV-Dateien werden in den konfigurierten Verzeichnissen erwartet.<br>
-			Der Webserver ben&ouml;tigt hier Schreibrechte.
-		</td>
-	</tr>
-	<tr>
-		<td>
-			<b>Lx-ERP</b>
-		</td>
-		<td><a href="<?= $ERPdir ?>"><?= $ERPdir ?></a></td>
-	</tr>
-	<tr>
-		<td>
-			<b>xt:Commerce</b>
-		</td>
-		<td><a href="<?= $SHOPdir ?>"><?= $SHOPdir ?></a></td>
-	</tr>
-	<tr>
-		<td align="center"><a href="erpexport.php"><img src="e2c.gif" border="0"></a></td>
-		<td align="center"><a href="shopimport_csv.php"><img src="c2s.gif" border="0"></a></td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			<hr>
-		</td>
-	</tr>
-	<tr>
-		<td colspan="2">
-			Copyright (c) 2004 Lx-System - Version: 1.0 - <a href="mailto:info@lx-system.de">info@lx-system.de</a>
-		</td>
-	</tr>
-</table>
-</center>
-</body>
-</html>
diff --git a/xtcom/xtcom.sql b/xtcom/xtcom.sql
deleted file mode 100644
index 24b3ac4b9..000000000
--- a/xtcom/xtcom.sql
+++ /dev/null
@@ -1,9 +0,0 @@
-# $Id: oscom.sql,v 1.2 2004/07/01 20:50:34 hli Exp $
-# Zusatztabelle Kundenbeziehung ERP - osCommerce
-#
-CREATE TABLE customers_number (
-  cid int(6) NOT NULL auto_increment,
-  customers_id int(3) NOT NULL default '0',
-  kdnr int(3) NOT NULL default '0',
-  PRIMARY KEY  (cid)
-) TYPE=MyISAM;
diff --git a/xtcom/xtcomexport.php b/xtcom/xtcomexport.php
deleted file mode 100644
index 948977b8a..000000000
--- a/xtcom/xtcomexport.php
+++ /dev/null
@@ -1,426 +0,0 @@
-<?
-/***************************************************************
-*Author: Holger Lindemann
-*Copyright: (c) 2004 Lx-System
-*License: non free
-*eMail: info@lx-system.de
-*Version: 1.6
-*Shop: xt::Commerce
-*ERP: kivitendo ERP 3.0.0
-***************************************************************/
-/*
-* Noch einzubauen:
-*/
-//echo <<<EOF
-echo "<html>";
-echo "	<head><title>Lx-ERP Export der Shopartikel</title>";
-echo '	<link type="text/css" REL="stylesheet" HREF="css/main.css"></link>';
-echo "<body>";
-//EOF;
-
-define("ExportMode","2");
-require_once "shoplib.php";
-/**********************************************
-* getAttribut($oid,$pid)
-*
-**********************************************/
-function getAttribut($oid,$pid) {
-	$sql="select * from orders_products_attributes where orders_id=$oid and orders_products_id=$pid";
-	$rs=getAll("shop",$sql,"getAttribut");
-	$txt="";
-	foreach ($rs as $zeile) {
-		$txt.="\n - ".$zeile["products_options"].":".$zeile["products_options_values"];
-	};
-	return $txt;
-}
-
-/**********************************************
-* getBrutto($id)
-*
-**********************************************/
-function getBrutto($id) {
-	$sql="select * from orders_total where orders_id=$id and class='ot_total'";
-	$rs=getAll("shop",$sql,"getBrutto");
-	return $rs[0]["value"];
-}
-
-/**********************************************
-* getMwst($id)
-*
-**********************************************/
-function getMwst($id) {
-	$sql="select * from orders_total where orders_id=$id and class='ot_tax'";
-	$rs=getAll("shop",$sql,"getMwst");
-	$mwst=0;
-	if ($rs) {
-		foreach ($rs as $zeile) {
-			$mwst+=$zeile["value"];
-		}
-	}
-	return $mwst;
-}
-
-/**********************************************
-* getSonderkosten($id,$art)
-*
-**********************************************/
-function getSonderkosten($id,$art) {
-	$sql="select * from orders_total where orders_id=$id and class='".$GLOBALS["skosten"][$art]."'";
-	$rs=getAll("shop",$sql,"getSonderkosten");
-	if ($rs[0]["value"]) {
-		$kosten=round($rs[0]["value"]/(100+$GLOBALS["versand"]["TAX"])*100,2);
-	} else {
-		$kosten=false;
-	}
-	return $kosten;
-}
-
-/**********************************************
-* insBestArtikel($zeile,$transID)
-*
-**********************************************/
-function insBestArtikel($ordersID,$transID) {
-global $div07,$div16;
-	$sql="select * from orders_products where orders_id=$ordersID";
-	$rs=getAll("shop",$sql,"insBestArtikel");
-	$ok=true;
-	if ($rs) foreach ($rs as $zeile) {
-		$sql="select * from parts where partnumber='".$zeile["products_model"]."'";
-		$rs2=getAll("erp",$sql,"insBestArtikel");
-		if ( $rs2[0]["id"]) {$artID=$rs2[0]["id"]; $artNr=$rs2[0]["partnumber"]; }
-		else {
-			if ($zeile["products_tax"]=="19.0000") {
-				$artID=$div16["ID"];
-				$artNr=$div16["NR"];
-			} else {
-				$artID=$div07["ID"];
-				$artNr=$div07["NR"];
-			};
-		}
-		$preis=round($zeile["products_price"]/(100+$zeile["products_tax"])*100,2);
-		$text=getAttribut($ordersID,$zeile["orders_products_id"]);
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$transID.",".$artID.",'".$zeile["products_name"].$text."',".$zeile["products_quantity"].",".$preis.",'Stck',0,0)";
-		echo " - Artikel:[ BuNr.:$artID ArtNr:<b>$artNr</b> ".$zeile["products_name"]." ]<br>";
-		$rc=query("erp",$sql,"insBestArtikel");
-		if ($rc === -99) { $ok=false; break; };
-	}
-	return $ok;
-}
-
-function insAuftrag($data) {
-global $ERPusr,$versand,$nachn,$minder,$paypal,$auftrnr;
-	$Zahlmethode=array("authorizenet"=>"Authorize.net","banktransfer"=>"Lastschriftverfahren","cc"=>"Kreditkarte",
-		"cod"=>"Nachnahme","eustandardtransfer"=>"EU-Standard Bank Transfer","iclear"=>"iclear Rechnungskauf",
-		"invoice"=>"Rechnung","ipayment"=>"iPayment","liberecobanktransfer"=>"Lastschriftverfahren",
-		"liberecocc"=>"Kreditkarte","moneybookers"=>"Moneybookers.com","moneyorder"=>"Scheck/Vorkasse",
-		"nochex"=>"NOCHEX","paypal"=>"PayPal","pm2checkout"=>"2CheckOut","psigate"=>"PSiGate",
-		"qenta"=>"qenta.at","secpay"=>"SECPay");
-	$brutto=getBrutto($data["orders_id"]);
-	$mwst=getMwst($data["orders_id"]);
-	$netto=$brutto-$mwst;
-	$versandK=getSonderkosten($data["orders_id"],"Versand");
-	$nachnK  =getSonderkosten($data["orders_id"],"NachName");
-	$mindermK=getSonderkosten($data["orders_id"],"Minder");
-	$paypalK =getSonderkosten($data["orders_id"],"Paypal");
-	// Hier beginnt die Transaktion
-	$rc=query("erp","BEGIN WORK","insAuftrag");
-	if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-	if ($auftrnr) {
-		$auftrag=$GLOBALS["preA"].getNextAnr();
-	} else {
-		$auftrag=$GLOBALS["preA"].$data["orders_id"];
-	}
-	$sql="select count(*) as cnt from oe where ordnumber = '$auftrag'";
-	$rs=getAll("erp",$sql,"insAuftrag 1");
-	if ($rs[0]["cnt"]>0) {
-		$auftrag=$GLOBALS["preA"].getNextAnr();
-	}
-	$newID=uniqid (rand());
-	$sql="insert into oe (notes,ordnumber,cusordnumber) values ('$newID','$auftrag','".$data["kdnr"]."')";
-	$rc=query("erp",$sql,"insAuftrag 2");
-	if ($rc === -99) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK WORK","chkKunde");
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		return false;
-	}
-	$sql="select * from oe where notes = '$newID'";
-	$rs2=getAll("erp",$sql,"insAuftrag 3");
-	if (!$rs2>0) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK WORK","chkKunde");
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		return false;
-	}
-	$BEZAHLEN=$Zahlmethode[$data["payment_method"]]."\n";
-	if ($data["cc_type"]) {
-		$BEZAHLEN.=$data["cc_type"]."\n".$data["cc_owner"]."\n".$data["cc_number"]."\n".$data["cc_expires"]."\n";
-	} else if ($data["banktransfer_blz"]) {
-		$BEZAHLEN.="Kontoinhaber: ".$data["banktransfer_owner"]."\nBanknummer: ".$data["banktransfer_blz"];
-		$BEZAHLEN.="\nBank: ".$data["banktransfer_bankname"]."\nKontonummer: ".$data["banktransfer_number"]."\n";
-	}
-	$sql="update oe set cusordnumber=".$data["orders_id"].", transdate='".$data["date_purchased"]."', customer_id=".$data["kdnr"].", ";
-	$sql.="amount=".$brutto.", netamount=".$netto.", reqdate='".$data["date_purchased"]."', taxincluded='f', ";
-	if ($data["shipto"]>0) $sql.="shipto_id=".$data["shipto"].", ";
-	$sql.="intnotes='".$data["comments"]."',notes='".$BEZAHLEN."', curr='EUR',employee_id=".$ERPusr["ID"].", vendor_id=0 ";
-	$sql.="where id=".$rs2[0]["id"];
-	$rc=query("erp",$sql,"insAuftrag 4");
-	if ($rc === -99) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK WORK","chkKunde");
-		if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		return false;
-	}
-	echo "Auftrag:[ Buchungsnummer:".$rs2[0]["id"]." AuftrNr:<b>".$auftrag."</b> ]<br>";
-	if (!insBestArtikel($data["orders_id"],$rs2[0]["id"])) {
-		echo "Auftrag ".$data["orders_id"]." konnte nicht angelegt werden.<br>";
-		$rc=query("erp","ROLLBACK WORK","chkKunde");
-		if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		return false;
-	};
-	if ($versandK) {
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$rs2[0]["id"].",".$versand["ID"].",'".$versand["TXT"]."',1,".$versandK.",'Stck',0,0)";
-		$rc=query("erp",$sql,"insAuftrag 8");
-		if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den Versandkosten<br>";
-	}
-	if ($nachnK) {
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$rs2[0]["id"].",".$nachn["ID"].",'".$nachn["TXT"]."',1,".$nachnK.",'Stck',0,0)";
-		$rc=query("erp",$sql,"insAuftrag 9");
-		if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den Nachnamekosten<br>";
-	}
-	if ($mindermK) {
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$rs2[0]["id"].",".$minder["ID"].",'".$minder["TXT"]."',1,".$mindermK.",'Stck',0,0)";
-		$rc=query("erp",$sql,"insAuftrag 10");
-		if ($rc === -99) echo "Auftrag $auftrag : Fehler beim Mindermengenzuschlag<br>";
-	}
-	if ($paypalK) {
-		$sql="insert into orderitems (trans_id, parts_id, description, qty, sellprice, unit, ship, discount) values (";
-		$sql.=$rs2[0]["id"].",".$paypal["ID"].",'".$paypal["TXT"]."',1,".$paypalK.",'Stck',0,0)";
-		$rc=query("erp",$sql,"insAuftrag 11");
-		if ($rc === -99) echo "Auftrag $auftrag : Fehler bei den PayPal-Kosten<br>";
-	}
-	$sql="update orders set orders_status ='3' WHERE orders_id =".$data["orders_id"];
-	$rc=query("shop",$sql,"insBestArtikel 12");
-	if ($rc === -99) echo "Bestellung im Shop nicht geschlossen";
-	$rc=query("erp","COMMIT WORK","chkKunde");
-	if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-	return true;
-}
-
-/**********************************************
-* getBestellung()
-*
-**********************************************/
-function getBestellung() {
-	$sql="select b.*,h.comments,o.*,cn.kdnr from orders o left join orders_status_history h on h.orders_id=o.orders_id ";
-	$sql.="left join banktransfer b on b.orders_id =o.orders_id left join customers_number cn on ";
-	$sql.="cn.customers_id=o.customers_id where o.orders_status=1 order by o.orders_id";
-	$rs=getAll("shop",$sql,"getBestellung");
-	return $rs;
-}
-
-/**********************************************
-* chkKdData()
-*
-**********************************************/
-function chkKunden() {
-	$felder=array("firstname","lastname","company","street_address","city","postcode","country");
-	foreach ($GLOBALS["bestellungen"] as $bestellung) {
-		$rc=query("erp","BEGIN WORK","chkKunden");
-		if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		if ($bestellung["kdnr"]>0) { // Bestandskunde; kdnr == ID in customers
-			$msg="update ";
-			$kdnr=chkOldKd($bestellung);
-			if ($kdnr == -1) { //Kunde nicht gefunden, neu anlegen.
-				$msg="insert ";
-				$kdnr=insNewKd($bestellung);
-				$GLOBALS["neuKd"]++;
-			} else if (!$kdnr) {
-				echo $msg." ".$bestellung["customers_name"]." fehlgeschlagen!<br>";
-				$GLOBALS["gesKd"]++;
-				continue;
-			}
-		} else { // Neukunde
-			$msg="insert ";
-			$kdnr=insNewKd($bestellung);
-			$GLOBALS["neuKd"]++;
-		}
-		echo $bestellung["customers_company"]." ".$bestellung["customers_name"]." $kdnr<br>";
-		$GLOBALS["bestellungen"][$GLOBALS["gesKd"]]["kdnr"]=$kdnr;
-		$sql="delete from customers_number where customers_id=".$bestellung["customers_id"];
-        	$rc=query("shop",$sql,"chkKunde");
-        	$sql="insert into customers_number (customers_id,kdnr) values(".$bestellung["customers_id"].",".$kdnr.")";
-        	$rc=query("shop",$sql,"chkKunde");
-		if ($kdnr>0) {
-			foreach($felder as $feld) {
-				if ($bestellung["delivery_$feld"]<>$bestellung["customers_$feld"]) {
-					$rc=insShData($bestellung,$kdnr);
-					if ($rc>0) $GLOBALS["bestellungen"][$GLOBALS["gesKd"]]["shipto"]=$rc;
-					break;
-				}
-			}
-		}
-		if (!$kdnr || $rc === -99) {
-			echo $msg." ".$bestellung["customers_name"]." fehlgeschlagen! ($kdnr,$rc)<br>";
-			$rc=query("erp","ROLLBACK WORK","chkKunde");
-			if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		} else {
-			$rc=query("erp","COMMIT WORK","chkKunde");
-			if ($rc === -99) { echo "Probleme mit Transaktion. Abbruch!"; exit(); };
-		}		$GLOBALS["gesKd"]++;
-	}
-	return true;
-}
-
-function chkOldKd($data) {
-	$sql="select * from customer where id = ".$data["kdnr"];
-	$rs=getAll("erp",$sql,"chkKdData");
-	if (!$rs || $rs[0]["id"]<>$data["kdnr"]) { return -1; }; // Kunde nicht gefunden
-	if ($rs[0]["zipcode"]<>$data["customers_postcode"]) $set.="zipcode='".$data["customers_postcode"]."',";
-	if ($rs[0]["city"]<>$data["customers_city"]) $set.="city='".$data["customers_city"]."',";
-	if (in_array($data["customers_country"],$GLOBALS["LAND"])) {
-		if ($rs[0]["country"]<>$GLOBALS["LAND"][$data["customers_country"]]) $set.="country='".$GLOBALS["LAND"][$data["customers_country"]]."',";
-	} else {
-		if ($rs[0]["country"]<>$data["customers_country"]) $set.="country='".$data["customers_country"]."',";
-	}
-	if ($rs[0]["phone"]<>$data["customers_phone"])$set.="phone='".$data["customers_phone"]."',";
-	if ($rs[0]["email"]<>$data["customers_email_address"])$set.="email='".$data["customers_mail_address"]."',";
-	if ($data["customers_company"]) {
-		if ($rs[0]["name"]<>$data["customers_company"]) $set.="name='".$data["customers_company"]."',";
-		if ($rs[0]["contact"]<>$data["customers_name"]) $set.="contact='".$data["customers_name"]."',";
-	} else {
-		if ($rs[0]["name"]<>$data["customers_name"]) $set.="name='".$data["customers_lastname"].", ".$data["customers_firstname"]."',";
-	}
-	if ($rs[0]["street"]<>$data["customers_street_address"]) $set.="street='".$data["customers_street_address"]."',";
-	if ($set) {
-		$sql="update customer set ".substr($set,0,-1)." where id=".$rs[0]["id"];
-		$rc=query("erp",$sql,"chkKdData");
-		if ($rc === -99) {
-			return false;
-		} else {
-			return $data["kdnr"];
-		}
-	} else {
-		return $data["kdnr"];
-	}
-}
-
-/**********************************************
-* insShData($data,$id)
-*
-**********************************************/
-function insShData($data,$id) {
-	$set=$id;
-	if ($data["delivery_company"]) { $set.=",'".$data["delivery_company"]."','".$data["delivery_name"]."',"; }
-	else { $set.=",'".$data["delivery_name"]."','',"; }
-	$set.="'".$data["delivery_street_address"]."',";
-	$set.="'".$data["delivery_postcode"]."',";
-	$set.="'".$data["delivery_city"]."',";
-	if (in_array($data["delivery_country"],$GLOBALS["LAND"])) {
-		$set.="'".$GLOBALS["LAND"][$data["delivery_country"]]."',";
-	} else {
-		$set.="'".$data["delivery_country"]."',";
-	}
-	$set.="'".$data["customers_telephone"]."',";
-	$set.="'".$data["customers_email_address"]."'";
-	$sql="insert into shipto (trans_id,shiptoname,shiptodepartment_1,shiptostreet,shiptozipcode,shiptocity,";
-	$sql.="shiptocountry,shiptophone,shiptoemail,module) values ($set,'CT')";
-	$rc=query("erp",$sql,"insShData");
-	if ($rc === -99) return false;
-	$sql="select shipto_id from shipto where trans_id = $id and module='CT' order by itime desc limit 1";
-	$rs=getAll("erp",$sql,"insKdData");
-	if ($rs[0]["shipto_id"]>0) {
-		$sid=$rs[0]["shipto_id"];
-		$sql="update customers_number set shipto = $sid where kdnr = $id";
-		$rc2=query("shop",$sql,"insShData");
-        	if ($rc2 === -99) {
-        		$sql="delete from shipto where shipto_id=$sid";
-        		$rc=query("shop",$sql,"insShData");
-			return false;
-		}
-		return $sid;
-	} else  {
-		echo "Fehler bei abweichender Anschrift ".$data["delivery_name"];
-		$sql="delete from shipto where shipto_id=$sid";
-        	$rc=query("shop",$sql,"insShData");
-		return false;
-	}
-}
-
-/**********************************************
-* insKdData($BID)
-*
-**********************************************/
-function insNewKd($data) {
-	$taxid=array("DE"=>0,"CH"=>2,"AU"=>1,"FR"=>1,"IT"=>1,"ES"=>1,"NL"=>1); // Muß erweitert werden
-	$taxidL=array("Germany"=>0,"Switzerland"=>2,"Austria"=>1,"France"=>1,"Italy"=>1,"Spain"=>1,"Netherlands"=>1); // Muß erweitert werden
-	$newID=uniqid(rand(time(),1));
-	//Kundennummer generieren
-	if ($GLOBALS["kdnum"]==1) { // von der ERP
-		$kdnr=$GLOBALS["preK"].getNextKnr();
-	} else {		    // durch Shop
-		$kdnr=$GLOBALS["preK"].$data["customers_id"];
-	}
-	$sql="select count(*) as cnt from customer where customernumber = '$kdnr'";
-	$rs=getAll("erp",$sql,"insKdData");
-	if ($rs[0]["cnt"]>0) {  // Kundennummer gibt es schon, eine neue aus ERP
-		$kdnr=$GLOBALS["preK"].getNextKnr();
-	}
-	$sql="insert into customer (name,customernumber) values ('$newID','$kdnr')";
-	$rc=query("erp",$sql,"insKdData");
-	if ($rc === -99) return false;
-	$sql="select * from customer where name = '$newID'";
-	$rs=getAll("erp",$sql,"insKdData");
-	if (!$rs) return false;
-	if ($data["customers_company"]) {
-		$set.="set name='".$data["customers_company"]."',contact='".$data["customers_name"]."',";
-	}else {
-		$set.="set name='".$data["customers_lastname"].", ".$data["customers_firstname"]."',";
-		$set.="contact='".$data["customers_name"]."',";
-	}
-	$set.="street='".$data["customers_street_address"]."',";
-	$set.="zipcode='".$data["customers_postcode"]."',";
-	$set.="city='".$data["customers_city"]."',";
-	$set.="country='".$data["delivery_country_iso_code_2"]."',";
-	$set.="phone='".$data["customers_telephone"]."',";
-	$set.="email='".$data["customers_email_address"]."',";
-	if ($data["delivery_country_iso_code_2"]) {
-		$tid=(in_array($data["delivery_country_iso_code_2"],$taxid))?$taxid[$data["delivery_country_iso_code_2"]]:0;
-	} else {
-		$tid=(in_array($data["delivery_country"],$taxidL))?$taxidL[$data["delivery_country"]]:0;
-	}
-	if (!$tid) $tid=0;
-	$set.="taxzone_id=$tid,";
-	$set.="taxincluded='f' ";
-	$sql="update customer ".$set;
-	$sql.="where id=".$rs[0]["id"];
-	$rc=query("erp",$sql,"insKdData");
-	if ($rc === -99) {
-		$sql="delete from customer where id=".$rs[0]["id"];
-        	$rc=query("shop",$sql,"insNewKd");
-		return false;
-	} else { return $rs[0]["id"]; }
-}
-
-$LAND=array("Germany"=>"D","Austria"=>"A","Switzerland"=>"CH");
-$skosten=array("Versand"=>"ot_shipping","NachName"=>"ot_cod_fee","Paypal"=>"ot_paypal","Minder"=>"ot_loworderfee");
-$bestellungen=getBestellung();
-$ok=count($bestellungen);
-$gesKd=0;
-$neuKd=0;
-if ($ok) {
-	echo "Es liegen $ok Bestellungen vor. <br>";
-	chkKunden();
-	echo $gesKd." Kunde(n), davon ".$neuKd." neue(r) Kunde(n).<br>";
-	foreach ($bestellungen as $bestellung) {
-		insAuftrag($bestellung);
-	}
-} else { echo "Es liegen keine Bestellungen vor!<br>"; };
-?>
-<!--a href='trans.php'>zur&uuml;ck</a-->
-</body>
-</html>
