123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- <?php
- ini_set('display_errors', 1);
- ini_set('display_startup_errors', 1);
- error_reporting(E_ALL);
-
- header('Content-Type: application/json');
- if(isset($_GET["ProductCodeJson"])){
- $productcode = json_decode($_GET["ProductCodeJson"]);
- }
- elseif (isset($_GET["ProductCode"])){
- $noecho=true;
- include "TransformProductCode.php"; //if in the same folder
- $productcode = json_decode(json_encode($asocarray2));
- }
-
- //{"Pb":"E","Sy":"A","Pk":"PZ","Ba":"KZ-S","Za":"31","Zi":"31","Of":"NI","Kf":"X1K","Pf":"KeineAngabePf","Va":"KeineAngabeVa","Sn":"SEP","Zs":"SET1"}
-
- if ($productcode->Ba == "RKZ-S" || $productcode->Ba == "RHZ-S" || $productcode->Ba == "RDZ-S"){
- $file ="CE_SerNr_SlotT1_RP." . $productcode->Za . ".rotiert.xml";
- }
- elseif (($productcode->Ba == "KZ-S" || $productcode->Ba == "HZ-S" || $productcode->Ba == "DZ-S") && $productcode->Pf == "FLU"){
- $file = "CE_SerNr_FLU_SlotT1_EP." . $productcode->Za . ".rotiert.xml";
- }
- elseif ($productcode->Ba == "KZ-S" || $productcode->Ba == "HZ-S" || $productcode->Ba == "DZ-S"){
- $file = "CE_SerNr_SlotT1_EP." . $productcode->Za . ".rotiert.xml";
- }
- elseif ($productcode->Pk == "HA" && $productcode->Ba == "HM24-S" ){
- $file = "CE_SerNr_SlotT1_HPM.xml";
- }
- elseif ($productcode->Pk == "AI" && $productcode->Ba == "AZ25-FP" ){
- $file = "CE_SerNr_SlotT1_AZ25-FP.rotiert.xml";
- }
- elseif ($productcode->Pk == "SKI" || $productcode->Pk == "SKA" ){
- $file = "CE_SerNr_SlotT1_SKA-SKI.xml";
- }
- elseif ($productcode->Ba == "SKI" || $productcode->Ba == "SKA" ){
- $file = "CE_SerNr_SlotT1_SKA-SKI.xml";
- }
- elseif ($productcode->Pk == "HB" ){
- $file = "CE_SerNr_SlotT1_" . $productcode->Ba . ".xml";
- }
-
-
-
-
-
-
-
-
-
- echo json_encode($file);
-
- ?>
|