Database->select('MeasureClient', '*'); while($MeasureClient = $DbResult->fetch_assoc()) { $DbResult2 = $this->Database->select('MeasureMethod', '*', 'Id='.$MeasureClient['Method']); $MeasureMethod = $DbResult2->fetch_assoc(); echo($MeasureClient['MeasureId'].','); include_once(dirname(__FILE__).'/'.$MeasureMethod['MeasureClass'].'.php'); $MeasureMethod['MeasureClass'] .= 'Measurement'; if(class_exists($MeasureMethod['MeasureClass'])) { $MeasureClass = new $MeasureMethod['MeasureClass']($this->System); if(method_exists($MeasureClass, $MeasureMethod['Method'])) { if($MeasureClient['Parameter'] != '') $Value = $Measure->$MeasureMethod['Method']($MeasureClient['Parameter']); else $Value = $MeasureClass->$MeasureMethod['Method'](); echo(file_get_contents('http://'.$MeasureClient['Host'].$MeasureClient['Path'].'/?M=Add&MeasureId='.$MeasureClient['MeasureId'].'&Value='.addslashes($Value))); } else echo('Metoda '.$MeasureMethod['Method'].' neexistuje.'); } else echo('Třída '.$MeasureMethod['MeasureClass'].' neexistuje.'); } } }