public function getWindowHTML() { $bps = $this->getMyBPSData(); #print_r($bps); $v = false; $b = false; $von = "Bitte ziehen Sie ein <img src=\"./images/i2/add.png\" style=\"margin-bottom:-5px;\" />-Symbol auf dieses Feld."; $bis = "Bitte ziehen Sie ein <img src=\"./images/i2/add.png\" style=\"margin-bottom:-5px;\" />-Symbol auf dieses Feld."; if ($bps != -1 and isset($bps["VonClass"])) { $VonClass = $bps["VonClass"]; $VonClass = new $VonClass($bps["VonID"]); $von = $VonClass->getCategorizerLabel(); $v = true; } if ($bps != -1 and isset($bps["BisClass"])) { $BisClass = $bps["BisClass"]; $BisClass = new $BisClass($bps["BisID"]); $bis = $BisClass->getCategorizerLabel(); $b = true; } $t = new HTMLTable(2); $t->addColStyle(1, "width:120px;"); $t->addRow(array("<label>Von:</label>", $von)); $t->addCellID(2, "droppableVon"); $t->addCellStyle(2, "height:30px;"); $t->addRow(array("<label>Bis:</label>", $bis)); $t->addCellID(2, "droppableBis"); $t->addCellStyle(2, "height:30px;"); if ($v and $b) { $K = $BisClass->getCategorizerOptions(); $o = HTMLGUI::getOptions(array_keys($K), array_values($K)); $t->addRow(array("<label>Kategorie:</label>", "<select id=\"categorizeWithCategory\">{$o}</select>")); $t->addRow(array("<input\n\t\t\ttype=\"button\"\n\t\t\tclass=\"bigButton backgroundColor3\"\n\t\t\tvalue=\"Kategorisieren\"\n\t\t\tstyle=\"background-image:url(./images/navi/okCatch.png);float:right;\"\n\t\t\tonclick=\"rme('Categorizer','','categorize',Array(\$('categorizeWithCategory').value),'if(checkResponse(transport)) { Popup.close(\\'Categorizer\\', 0); contentManager.reloadFrameRight(); }');\" />")); $t->addRowColspan(1, 2); } $html = "\n\t\t<script type=\"text/javascript\">\n\t\t\tDroppables.add('droppableVon', {hoverclass: 'backgroundColor1', accept: 'draggable', onDrop: function(element){ rme('Categorizer','','saveVon',Array(element.id),'Popup.update(transport, \\'Categorizer\\', 0);'); }});\n\t\t\tDroppables.add('droppableBis', {hoverclass: 'backgroundColor1', accept: 'draggable', onDrop: function(element){ rme('Categorizer','','saveBis',Array(element.id),'Popup.update(transport, \\'Categorizer\\', 0);'); }});\n\t\t</script>"; echo $t->getHTML() . $html; }