コード例 #1
0
 public function getHTML($id)
 {
     try {
         $U = new mUserdata();
         $U->addAssocV3("typ", "=", $_SESSION["applications"]->getActiveApplication() . "DesktopLink");
         $U->addAssocV3("UserID", "=", $_SESSION["S"]->getCurrentUser()->getID());
         $U->addOrderV3("wert");
         $U->addOrderV3("UserdataID");
         $U->lCV3();
     } catch (Exception $e) {
         return "";
     }
     $html = "";
     while ($t = $U->getNextEntry()) {
         $e = explode(";", $t->A("name"));
         $v = explode(";", $t->A("wert"));
         $B = new Button($v[2], $v[1]);
         $B->type("icon");
         $B->onclick("DesktopLink.hide(); contentManager.loadFrame('{$e['2']}', '{$e['0']}', '{$e['1']}')");
         $BS = new Button("Einstellungen", "./images/i2/settings.png");
         $BS->type("icon");
         $BS->className("DesktopLinkSettings");
         $BS->rmePCR("DesktopLink", "", "editInWindow", $t->getID(), "Popup.displayNamed('DesktopLinkPopup','Desktop-Link bearbeiten', transport);");
         $BM = new Button("Verschieben", "./images/i2/moveLeftRight.png");
         $BM->type("icon");
         $BM->className("DesktopLinkHandler");
         $html .= "<li id=\"DesktopLink_" . $t->getID() . "\" class=\"DesktopLinkIcon\">{$BS}{$BM}{$B}" . "<p>" . $v[2] . "</p></li>";
     }
     if ($html != "") {
         echo "<ul id=\"DesktopLinkElements\">{$html}</ul><div style=\"clear:both;\"></div>";
     }
 }