当前位置: 首页>>代码示例>>PHP>>正文


PHP Div::add方法代码示例

本文整理汇总了PHP中Div::add方法的典型用法代码示例。如果您正苦于以下问题:PHP Div::add方法的具体用法?PHP Div::add怎么用?PHP Div::add使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Div的用法示例。


在下文中一共展示了Div::add方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: show

 /**
  *  Zeigt das gesamte Panel an
  */
 function show()
 {
     $this->CONTENT->setWidth($this->WIDTH - 8 * $this->PANELTITELRIGHTWIDTH);
     //---------------------------------------------------
     // Inhalt
     //---------------------------------------------------
     $cont = new Div();
     $cont->setBorder(1);
     $cont->setWidth($this->WIDTH - 2 * $this->PANELTITELRIGHTWIDTH);
     if ($this->HEIGHT > 0) {
         $cont->setHeight($this->HEIGHT - $this->PANELTITELHEIGHT);
     }
     $cont->setOverflow("auto");
     $cont->setStyle("background-color", $this->BGCOLOR);
     $cont->setStyle("border-style", "solid");
     $cont->setStyle("border-top", "1px");
     $cont->setStyle("border-left", "1px");
     $cont->setStyle("border-right", "2px");
     $cont->setStyle("border-bottom", "2px");
     $cont->setStyle("border-color", $_SESSION['config']->COLORS['text']);
     $cont->add($this->CONTENT);
     //---------------------------------------------------
     $tb = new Table(array(""));
     $rH = $tb->createRow();
     $rH->setAlign("center");
     $rH->setBackgroundColor($_SESSION['config']->COLORS['text']);
     $rH->setFontType($_SESSION['config']->COLORS['text']);
     $rH->setAttribute(0, $this->NAME);
     $tb->addRow($rH);
     $rC = $tb->createRow();
     $rC->setAlign("center");
     $rC->setAttribute(0, $cont);
     $tb->addRow($rC);
     return $tb;
 }
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:38,代码来源:Panel.php

示例2: testRender_tidy

    /**
     * Test rendering a div with HTML tidy.
     * @depends testRender_withSubdivs
     */
    public function testRender_tidy()
    {
        if (!class_exists('tidy')) {
            $this->markTestSkipped("Tidy extension not available");
        }
        $html = <<<HTML
<div>
  <div>
    Test
  </div>
  <div class="subdiv">
    <div>
      Child
    </div>
    <p>
      foobar
    </p>
  </div>
</div>
HTML;
        $this->div->setOption('tidy', array('indent' => true));
        $this->div->add('<div>Test</div>');
        $child = new Div(array('class' => 'subdiv'));
        $child->add('<div>Child</div>');
        $this->div->add($child);
        $element = $this->getMockBuilder('Jasny\\FormBuilder\\Element')->getMockForAbstractClass();
        $element->expects($this->once())->method('render')->will($this->returnValue('<p>foobar</p>'));
        $child->add($element);
        $this->assertSame($html, (string) $this->div);
    }
开发者ID:sachsy,项目名称:formbuilder,代码行数:34,代码来源:DivTest.php

示例3: getMobileSwitch

 function getMobileSwitch()
 {
     $tbl = new Table(array("", "", "", ""));
     $tbl->setAlignments(array("center", "left", "left", "right"));
     $tbl->setColSizes(array(60, "", 170, 150));
     $tbl->setBorder(0);
     $rowTtl = $tbl->createRow();
     $rowTtl->setVAlign("middle");
     $txtAn = new Text("AN", 7, true);
     $txtAus = new Text("AUS", 7, true);
     $divAn = new Div();
     $divAn->add($txtAn);
     $divAn->setWidth(150);
     $divAn->setHeight(50);
     $divAn->setAlign("center");
     $divAn->setVAlign("middle");
     $divAn->setStyle("line-height", "50px");
     $divAn->setBorder(1);
     $divAn->setBackgroundColor("green");
     $divAus = new Div();
     $divAus->setWidth(150);
     $divAus->setHeight(50);
     $divAus->setAlign("center");
     $divAus->setVAlign("middle");
     $divAus->setStyle("line-height", "50px");
     $divAus->add($txtAus);
     $divAus->setBorder(1);
     $divAus->setBackgroundColor("red");
     $txtName = new Text($this->OBJNAME, 6, true);
     $img = $this->getControlArtIcon(false);
     $lnkAn = new Link("http://" . $this->IP . "?schalte=on", $divAn, false, "arduinoSwitch");
     $lnkAus = new Link("http://" . $this->IP . "?schalte=-" . $this->FUNK_ID, $divAus, false, "arduinoSwitch");
     $rowTtl->setAttribute(0, $img);
     $rowTtl->setAttribute(1, $txtName);
     $rowTtl->setAttribute(2, $lnkAn);
     $rowTtl->setAttribute(3, $lnkAus);
     $tbl->addRow($rowTtl);
     return $tbl;
 }
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:39,代码来源:HomeControlAlarmgeber.php

示例4: getFullParentStructure

/**
 * Liefert den gesamten "Pfad" zum aktuellen Thread
 * @param $CurrentThreadtitle           Name des aktuellen Themas
 */
function getFullParentStructure($CurrentThreadtitle)
{
    $ret = new Div();
    $thread = $CurrentThreadtitle;
    while (getParentThreadName($thread) != "" && getParentThreadName($thread) != null) {
        $thread = getParentThreadName($thread);
        $lnk = new Link("?changeCurrForumThread=" . $thread, $thread);
        $ret->add($lnk);
        $t = new Text("&nbsp;-&nbsp;");
        $t->setFilter(false);
        $ret->add($t);
    }
    $lnk = new Link("?changeCurrForumThread=" . $CurrentThreadtitle, $CurrentThreadtitle);
    $ret->add($lnk);
    return $ret;
}
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:20,代码来源:forum_functions.php

示例5: getCommitRegisterMask

 function getCommitRegisterMask()
 {
     if ($this->USER->existsUsername($_REQUEST['user'])) {
         $dv = new Div();
         $dv->add(new Title("Benutzername existiert bereits"));
         $dv->add($this->getDefaultRegisterMask());
         return $dv;
     }
     $ttl = new Title("Benutzer wurde angelegt");
     $ttl->show();
     $txt = "Innerhalb der nächsten Minuten erhalten Sie eine eMail mit dem aktivierungs-Link.<br>" . "Sobald sie durch anklicken dieses Links ihre E-Mail bestätigt haben, ist Ihr Account vollständig aktiviert.<br>" . "Anschließend können Sie sich sofort mit ihren Benutzerdaten anmelden.";
     $sql = "INSERT INTO user( Vorname, Nachname, Email, User, Pw ) " . "VALUES( '" . $_REQUEST['vorname'] . "', '" . $_REQUEST['nachname'] . "', '" . $_REQUEST['email'] . "', '" . $_REQUEST['user'] . "', '" . md5($_REQUEST['passwort']) . "' )";
     $_SESSION['config']->DBCONNECT->executeQuery($sql);
     $rowUser = $this->USER->USERTABLE->getUserByEmail($_REQUEST['email']);
     $this->USER->setPassword($rowUser['id'], $_REQUEST['passwort']);
 }
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:16,代码来源:User.php

示例6: getTerminForCalendarView

function getTerminForCalendarView($day, $month, $year)
{
    $ret = new Text("");
    //W - Wochennummer des Jahres (z.B.: 28)
    //w - Wochentag (0(Sonntag) bis 6(Samstag))
    $wochentag = date('w', mktime(0, 0, 0, $month, $day, $year));
    if ($wochentag == 0) {
        $wochentag = 7;
    }
    /*-------------------------------------------------
      /  Prüft ob an angegebenem Datum ein Geburtstag
      /  ist, und zeigt diesen im Kalender an.
      /-------------------------------------------------*/
    if (strlen($month) == 1) {
        $month = "0" . $month;
    }
    if (strlen($day) == 1) {
        $day = "0" . $day;
    }
    // Alle mit passendem Start/Enddatum
    $sqlTermin = "SELECT * FROM terminserie ";
    $sqlTermin .= "WHERE serien_start_datum <= '" . $year . "-" . $month . "-" . $day . "'  ";
    $sqlTermin .= "AND (serien_end_datum  >= '" . $year . "-" . $month . "-" . $day . "' OR enddatumjn != 'J') ";
    //echo $sqlTermin;
    $resultTermin = mysql_query($sqlTermin);
    $ret = new Div();
    while ($rowTermin = mysql_fetch_array($resultTermin)) {
        switch ($rowTermin['serienmuster']) {
            case -1:
                // Einzeltermin
                if ($rowTermin['fixdatum'] == $year . "-" . $month . "-" . $day) {
                    $ret->add(getTerminInfoForCalendarView($rowTermin));
                }
                break;
                // ---------------------------------------
            // ---------------------------------------
            case 1:
                // Täglicher Serientermin
                //Wenn xten==1 gilt der Termin entweder nur Wochentags oder an allen Tagen
                if (isset($rowTermin['xten']) && $rowTermin['xten'] == 1) {
                    $chkWeekday = false;
                    switch ($wochentag) {
                        case 1:
                            if ($rowTermin['montag'] == "J") {
                                $chkWeekday = true;
                            }
                            break;
                        case 2:
                            if ($rowTermin['dienstag'] == "J") {
                                $chkWeekday = true;
                            }
                            break;
                        case 3:
                            if ($rowTermin['mittwoch'] == "J") {
                                $chkWeekday = true;
                            }
                            break;
                        case 4:
                            if ($rowTermin['donnerstag'] == "J") {
                                $chkWeekday = true;
                            }
                            break;
                        case 5:
                            if ($rowTermin['freitag'] == "J") {
                                $chkWeekday = true;
                            }
                            break;
                        case 6:
                            if ($rowTermin['samstag'] == "J") {
                                $chkWeekday = true;
                            }
                            break;
                        case 7:
                            if ($rowTermin['sonntag'] == "J") {
                                $chkWeekday = true;
                            }
                            break;
                    }
                    if ($chkWeekday) {
                        $ret->add(getTerminInfoForCalendarView($rowTermin));
                    }
                    //Sonst (Wenn xten!=1 gilt der Termin im festen Interval von x-Tagen)
                } else {
                    //	z - Tag des Jahres (z.B. 148 (entspricht 29.05.2001))
                    $jahrestag = date('z', mktime(0, 0, 0, $month, $day, $year));
                    $starttag = date('z', mktime(0, 0, 0, substr($rowTermin['serien_start_datum'], 5, 2), substr($rowTermin['serien_start_datum'], 8, 2), substr($rowTermin['serien_start_datum'], 0, 4)));
                    if (($jahrestag - $starttag) % $rowTermin['xten'] == 0) {
                        $ret->add(getTerminInfoForCalendarView($rowTermin));
                    }
                }
                break;
                // ---------------------------------------
            // ---------------------------------------
            case 2:
                // Wöchentlicher Serientermin
                if (strlen($rowTermin['xten']) > 0) {
                    $chkWeekday = false;
                    $jahreswoche = date('W', mktime(0, 0, 0, $month, $day, $year));
                    $startwoche = date('W', mktime(0, 0, 0, substr($rowTermin['serien_start_datum'], 5, 2), substr($rowTermin['serien_start_datum'], 8, 2), substr($rowTermin['serien_start_datum'], 0, 4)));
                    $wochentag = date('w', mktime(0, 0, 0, $month, $day, $year));
//.........这里部分代码省略.........
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:101,代码来源:calendar_functions.inc.php

示例7: getSensorMap

 function getSensorMap($dbTable)
 {
     $dv = new Div();
     for ($i = 1; $i <= $dbTable->getRowCount(); $i++) {
         $currConfigRow = $dbTable->getRow($i);
         if ($currConfigRow->getNamedAttribute("x") > 0 || $currConfigRow->getNamedAttribute("y") > 0) {
             $ctrlItem = new HomeControlSensor($currConfigRow, $this->EDITMODE);
             $ctrlItem->setIconViewActive(true);
             $dv->add($ctrlItem);
         }
     }
     return $dv;
 }
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:13,代码来源:HomeControlMap.php

示例8: DivByInclude

    $cont = new DivByInclude($_SESSION['mainpage'], false);
}
$cont->setWidth("800");
$cont->setStyle("padding-left", "4px");
$cont->setStyle("padding-right", "4px");
$MainPanel->add($cont);
$contentLayoutRow = $layoutTable->createRow();
$contentLayoutRow->setAttribute(0, $MainPanel);
$layoutTable->addRow($contentLayoutRow);
/* --------------------------------- */
/* ------------------------------------
     FUSS-MENU 
   ------------------------------------ */
$footMenuDiv = new Div();
$footMenuDiv->setWidth(810);
$footMenuDiv->setBorder(0);
$footMenuDiv->setAlign("center");
$footMenu = new DbMenu("Fussmenue");
$footMenu->setHeight(14);
$footMenu->setMenuType("horizontal");
$footMenu->setAlign("center");
$footMenu->setFontsize(1);
$footMenuDiv->add($footMenu);
$fussLayoutRow = $layoutTable->createRow();
$fussLayoutRow->setAttribute(0, $footMenuDiv);
$layoutTable->addRow($fussLayoutRow);
/* --------------------------------- */
$layoutTable->show();
$arduinoFrame = new IFrame($_SESSION['config'], "arduinoSwitch", -1, -1, 1, 1, 0);
$arduinoFrame->show();
echo "Diese Tablet-Version befindet sich im Aufbau;)";
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:31,代码来源:layout_tablet.php

示例9: getWochentagTermCreatorMask

 /**
  * Maske um Urhzeit incl. Bedingung (<>=) zu erzeugen
  */
 private function getWochentagTermCreatorMask()
 {
     $div = new Div("createWochentag");
     $cboMo = new Checkbox("montag");
     $cboDi = new Checkbox("dienstag");
     $cboMi = new Checkbox("mittwoch");
     $cboDo = new Checkbox("donnerstag");
     $cboFr = new Checkbox("freitag");
     $cboSa = new Checkbox("samstag");
     $cboSo = new Checkbox("sonntag");
     $triggerChb = new Checkbox("trigger_jn", "", "J");
     $triggerChb->setToolTip("Gibt an, ob eine &Auml;nderung des Wertes einen Schaltvorgang aktiviert oder nur als Bedingung dient.");
     $t = new Table(array("Mo", "Di", "Mi", "Do", "Fr", "Sa", "So", "", ""));
     $t->setAlign("center");
     $r = $t->createRow();
     $r->setAttribute(0, "Montag");
     $r->setAttribute(1, "Dienstag");
     $r->setAttribute(2, "Mittwoch");
     $r->setAttribute(3, "Donnerstag");
     $r->setAttribute(4, "Freitag");
     $r->setAttribute(5, "Samstag");
     $r->setAttribute(6, "Sonntag");
     $r->setAttribute(7, "Trigger?");
     $t->addRow($r);
     $r = $t->createRow();
     $r->setAttribute(0, $cboMo);
     $r->setAttribute(1, $cboDi);
     $r->setAttribute(2, $cboMi);
     $r->setAttribute(3, $cboDo);
     $r->setAttribute(4, $cboFr);
     $r->setAttribute(5, $cboSa);
     $r->setAttribute(6, $cboSo);
     $r->setAttribute(7, $triggerChb);
     $r->setAttribute(8, new Button("saveCreateWochentagTerm", "Bedingung hinzufuegen"));
     $t->addRow($r);
     $rH = $t->createRow();
     $rH->setSpawnAll(true);
     $rH->setAttribute(0, new Hiddenfield("dbTableNewhomecontrol_term", "Neuen Eintrag"));
     $t->addRow($rH);
     $rH2 = $t->createRow();
     $rH2->setSpawnAll(true);
     $rH2->setAttribute(0, new Hiddenfield("createWochentag", "ok"));
     $t->addRow($rH2);
     $div->add($t);
     return $div;
 }
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:49,代码来源:HomeControlTermCreator.php

示例10: show

 function show()
 {
     //Wenn notwendig Eingabemaske, ansonsten Standard-Anzeige
     if (!$this->showInsertMaskIfNeeded()) {
         $rowsToShow = $this->getRowsToShow();
         //Tabelle für gesamte NEWS
         $tbl = new Table(array("News"));
         $tbl->setHeadEnabled(false);
         $tbl->setBorder(0);
         foreach ($rowsToShow as $row) {
             $tt = new Text($row['Text']);
             $tt->setFilter(false);
             $ta = new Text($row['Autor']);
             $tblxTitle = new Table(array("", ""));
             $tblxTitle->setColSizes(array("50"));
             $tblxTitle->setAlign("left");
             $rxtitle = $tblxTitle->createRow();
             $t0 = new Title(getFormatedDate($row['Datum'], "standard") . ":");
             $t0->setWidth(20);
             $rxtitle->setAttribute(0, $t0);
             $t1 = new Title($row['Title']);
             $rxtitle->setAttribute(1, $t1);
             $rxtitle->setAlign("left");
             $tblxTitle->addRow($rxtitle);
             //Tabelle für den jeweiligen Eintrag
             $tblx = new Table(array(""));
             if (strlen($row['pic']) > 0) {
                 $tblx = new Table(array("", ""));
                 $tblx->setColSizes(array("180"));
             }
             $tblx->setBorder($this->CONFIG->GB_CONFIG['border']);
             $tblx->setWidth("100%");
             //TEXT
             $rx = $tblx->createRow();
             if (strlen($row['pic']) > 0 && !(isset($_REQUEST['removeNewsPicId']) && $_REQUEST['removeNewsPicId'] == $row['id'])) {
                 $img = new Image($row['pic']);
                 $img->setWidth(175);
                 $rx->setAttribute(0, $img);
                 $rx->setAttribute(1, $tt);
             } else {
                 $rx->setAttribute(0, $tt);
             }
             $rx->setAlign("left");
             $tblx->addRow($rx);
             $f = new FontType();
             $rx->setFonttypes(array(0 => $f));
             $f = new FontType();
             $f->setFontsize(1);
             $f->setItalic(false);
             $rx->setFonttypes(array(0 => $f));
             $r = $tbl->createRow();
             $r->setAttribute(0, $tblxTitle);
             $tbl->addRow($r);
             $r1 = $tbl->createRow();
             $r1->setAttribute(0, $tblx);
             $tbl->addRow($r1);
             $ytElem = new YouTubeElement($row['yt_video'], "news", "yt_video", $row['id']);
             $r1 = $tbl->createRow();
             $r1->setAttribute(0, $ytElem);
             $tbl->addRow($r1);
             $tbl->addSpacer(0, 7);
             if ($_SESSION['config']->CURRENTUSER->STATUS == "admin" || $_SESSION['config']->CURRENTUSER->STATUS == "user") {
                 $r2 = $tbl->createRow();
                 $xDv = new Div();
                 $xDv->setWidth(450);
                 $xDv->setHeight(40);
                 $txChngePic = new Text("Bild Hochladen/Ändern<br>");
                 $txChngePic->setFilter(false);
                 $newPicLink = new Link("?popupRunLink=imageUploaderPopup&targetPath=pics/news&DbInsertTable=news&DbInsertCol=pic&DbInsertId=" . $row['id'] . "&stayAlive=ok", $txChngePic);
                 $txRemPic = new Text("Bild Entfernen<br>");
                 $txRemPic->setFilter(false);
                 $removePicLink = new Link("?removeNewsPicId=" . $row['id'] . "", $txRemPic);
                 $spTx = new Text("&nbsp;&nbsp;&nbsp;");
                 $spTx->setFilter(false);
                 $xDv->add($newPicLink);
                 if (strlen($row['pic']) > 0) {
                     if (isset($_REQUEST['removeNewsPicId']) && $_REQUEST['removeNewsPicId'] == $row['id']) {
                         $sql = "UPDATE news SET pic = null WHERE id = " . $_REQUEST['removeNewsPicId'];
                         $_SESSION['config']->DBCONNECT->executeQuery($sql);
                     } else {
                         $xDv->add($removePicLink);
                     }
                 }
                 $newPicLink->setPopup(true);
                 $r2->setAttribute(0, $xDv);
                 $tbl->addRow($r2);
             }
             $tbl->addSpacer(0, 35);
         }
         if ($_SESSION['config']->CURRENTUSER->STATUS == "admin" || $_SESSION['config']->CURRENTUSER->STATUS == "user") {
             // Neuer Eintrag- BUTTON
             //--------------------------------
             $insertButton = new Button('dbTableNew', 'News eintragen');
             $form = new Form($_SERVER['SCRIPT_NAME']);
             $form->add($insertButton);
             $form->show();
         }
         // Tabelle anzeigen
         //--------------------------------
         $tbl->show();
//.........这里部分代码省略.........
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:101,代码来源:News.php

示例11: getMobileSwitch

 function getMobileSwitch()
 {
     $tbl = new Table(array("", "", "", "", ""));
     $tbl->setAlignments(array("center", "left", "left", "left", "right"));
     $tbl->setColSizes(array(60, "", 100, 160, 150));
     $tbl->setBorder(0);
     $rowTtl = $tbl->createRow();
     $rowTtl->setVAlign("middle");
     $txtAn = new Text("AN", 7, true);
     $txtAus = new Text("AUS", 7, true);
     switch ($this->ART) {
         case 1:
             // Steckdosen
         // Steckdosen
         case 3:
             // Glühbirne
             $txtAn = new Text("AN", 7, true);
             $txtAus = new Text("AUS", 7, true);
             break;
         case 2:
             // Jalousien
             $txtAn = new Text("AUF", 7, true);
             $txtAus = new Text("ZU", 7, true);
             break;
         case 4:
             // Heizung
             $txtAn = new Text("WARM", 7, true);
             $txtAus = new Text("KALT", 7, true);
             break;
         default:
             $txtAn = new Text("AN", 7, true);
             $txtAus = new Text("AUS", 7, true);
     }
     $divAn = new Div();
     $divAn->add($txtAn);
     $divAn->setWidth(150);
     $divAn->setHeight(50);
     $divAn->setAlign("center");
     $divAn->setVAlign("middle");
     $divAn->setStyle("line-height", "50px");
     $divAn->setBorder(1);
     $divAn->setBackgroundColor("green");
     $divAn->setOverflow("hidden");
     $divAus = new Div();
     $divAus->setWidth(150);
     $divAus->setHeight(50);
     $divAus->setAlign("center");
     $divAus->setVAlign("middle");
     $divAus->setStyle("line-height", "50px");
     $divAus->add($txtAus);
     $divAus->setBorder(1);
     $divAus->setBackgroundColor("red");
     $divAus->setOverflow("hidden");
     $txtName = new Text($this->OBJNAME, 6, true);
     $img = $this->getControlArtIcon(false);
     $lnkAn = new Link("?switchShortcut=" . $this->FUNK_ID . "-on", $divAn, false, "arduinoSwitch");
     $lnkAus = new Link("?switchShortcut=" . $this->FUNK_ID . "-off", $divAus, false, "arduinoSwitch");
     $fDimmLvl = "";
     if ($this->isDimmable()) {
         $fDimmLvl = new Form();
         $cobDimmLvl = new Combobox("dimmer", getNumberComboArray(1, 16), "", " ");
         $cobDimmLvl->setDirectSelect(true);
         $cobDimmLvl->setStyle("font-size", "40px");
         $fDimmLvl->add($cobDimmLvl);
         $fDimmLvl->add(new Hiddenfield("schalte", $this->FUNK_ID));
     }
     $rowTtl->setAttribute(0, $img);
     $rowTtl->setAttribute(1, $txtName);
     $rowTtl->setAttribute(2, $fDimmLvl);
     $rowTtl->setAttribute(3, $lnkAn);
     $rowTtl->setAttribute(4, $lnkAus);
     $tbl->addRow($rowTtl);
     return $tbl;
 }
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:74,代码来源:HomeControlItem.php

示例12: Div

    $contentLayoutRow->setAlign("left");
} else {
    $contentLayoutRow->setAlign("center");
}
$contentLayoutRow->setAttribute(0, $MainPanel);
$layoutTable->addRow($contentLayoutRow);
/* --------------------------------- */
$layoutTable->addSpacer(0, 40);
/* ------------------------------------
FUSS-MENU 
------------------------------------ */
$footMenuDiv = new Div();
$footMenuDiv->setWidth("99%");
$footMenuDiv->setBackgroundColor($_SESSION['config']->COLORS['panel_background']);
$footMenuDiv->setBorder(0);
$footMenuDiv->setAlign("center");
$footMenu = new DbMenu("Fussmenue");
//       $footMenu->setHeight(60);
$footMenu->setMenuType("horizontal");
$footMenu->setAlign("center");
$footMenu->setFontsize(6);
$footMenuDiv->add(new Line(1, 6));
$footMenuDiv->add($footMenu);
$footMenuDiv->add(new Line(1, 6));
$fussLayoutRow = $layoutTable->createRow();
$fussLayoutRow->setAttribute(0, $footMenuDiv);
$layoutTable->addRow($fussLayoutRow);
/* --------------------------------- */
$layoutTable->show();
$arduinoFrame = new IFrame($_SESSION['config'], "arduinoSwitch", -1, -1, 1, 1, 0);
$arduinoFrame->show();
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:31,代码来源:layout_mobile.php

示例13: showLogContent

 function showLogContent()
 {
     $div = new Div();
     $div->setWidth("100%");
     $div->setHeight("250");
     $div->setStyle("white-space", "nowrap");
     $output = array();
     $tmp = exec("tail -n " . $this->getLinesToShow() . " " . $this->getPath(), $output);
     foreach (array_reverse($output) as $out) {
         $tx = new Text($out . "<br>", 2, false, false, false, false);
         $div->add($tx);
     }
     $ln = new Line();
     $ln->show();
     $div->show();
     $ln->show();
 }
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:17,代码来源:LogFile.php

示例14: doDeleteFromUpdatemask

 function doDeleteFromUpdatemask()
 {
     //generelle Delete bearbeitung
     //Zugeschnitten auf dynamische UpdateMaske (showUpdateMask)
     $ret = false;
     for ($ir = 1; $ir <= count($this->ROWS); $ir++) {
         $rowId = $this->ROWS[$ir]->getAttribute(count($this->COLNAMES));
         $delName = "delete" . $rowId . $this->TABLENAME;
         if (isset($_REQUEST[$delName])) {
             if (isset($_REQUEST['RowDeleteCommited']) && $_REQUEST['RowDeleteCommited'] == "Wirklich entfernen") {
                 $rowId = $this->ROWS[$ir]->getAttribute(count($this->COLNAMES));
                 $chk = 0;
                 $sql = "";
                 $row = $this->ROWS[$ir];
                 // Wenn Zeile gelöscht werden soll
                 $statement = "DELETE FROM " . $this->TABLENAME . " WHERE id = " . $rowId . " ";
                 $result = $this->DBCONNECT->executeQuery($statement);
                 $e = new Message("entfernen", "Entfernen erfolgreich ");
                 $this->refresh();
                 $ret = true;
                 $this->postDelete($rowId);
             } else {
                 $tbl = new Table($this->COLNAMES);
                 $dataRow = $this->getRowById($this->ROWS[$ir]->getNamedAttribute("id"));
                 $tbl->setStyle("background-color", "#ee9999");
                 $tbl->setStyle("padding", "5px");
                 $r1 = $tbl->createRow();
                 $r1->setSpawnAll(true);
                 $txt = new Text("Wollen Sie den folgenden Datensatz wirklich entfernen?");
                 $r1->setAttribute(0, $txt);
                 $tbl->addRow($r1);
                 $tbl->addSpacer(1, 8);
                 $r = $tbl->createRow();
                 $c = 0;
                 foreach ($this->COLNAMES as $colname) {
                     $r->setAttribute($c, new Title($colname));
                     $c++;
                 }
                 $tbl->addRow($r);
                 $r = $tbl->createRow();
                 $c = 0;
                 foreach ($this->COLNAMES as $colname) {
                     $r->setAttribute($c, new Text($this->ROWS[$ir]->getNamedAttribute($colname)));
                     $c++;
                 }
                 $tbl->addRow($r);
                 $tbl->addSpacer(1, 5);
                 $rbtn = $tbl->createRow();
                 $rbtn->setSpawnAll(true);
                 $btnOk = new Button("RowDeleteCommited", "Wirklich entfernen");
                 $btnCancle = new Button("Abbrechen", "Abbrechen", "location='" . $_SERVER['SCRIPT_NAME'] . "'");
                 $div = new Div();
                 $div->add($btnOk);
                 $div->add($btnCancle);
                 $rbtn->setAttribute(0, $div);
                 $tbl->addRow($rbtn);
                 $hiddenOk = new Hiddenfield($delName, $_REQUEST[$delName]);
                 //$frm = new Form($_SERVER['SCRIPT_NAME']);
                 $frm = new Div();
                 $frm->add($tbl);
                 $frm->add($hiddenOk);
                 $frm->add($this->DEFAULT_HIDDEN_FIELDS);
                 return $frm;
             }
         }
     }
     return $ret;
 }
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:68,代码来源:DbTable.php

示例15: Text

 $divMotionDauer->add($txtMotionDauer);
 $txtSensorlogDauer = new Text("Tage die Sensor-Log Daten behalten");
 $txfSensorlogDauer = new Textfield($sensorlogDauerName, $sensorlogDauer, 4, 4);
 $divSensorlogDauer = new Div();
 $divSensorlogDauer->add($txfSensorlogDauer);
 $divSensorlogDauer->add($txtSensorlogDauer);
 $txtTimelineDuration = new Text("Tage in der Timeline anzeigen (1-6)");
 $divTimelineDuration = new Div();
 $divTimelineDuration->add($cobTimelineDuration);
 $divTimelineDuration->add($txtTimelineDuration);
 $txtPageTitel = new Text("Seiten-Titel");
 $txfPageTitel = new Textfield($pagetitelName, $pagetitel, 30, 50);
 $txtNotifyTargetMail = new Text("Emailempfangs-Adresse");
 $txfNotifyTargetMail = new Textfield($notifyTargetMailName, $notifyTargetMail, 30, 50);
 $rightDiv = new Div();
 $rightDiv->add($chbLoginSwitchNeed);
 $rightDiv->add(new Spacer(5));
 $rightDiv->add($chbLoginForTimelinePauseNeed);
 $rightDiv->add(new Spacer(5));
 $rightDiv->add($divSessionDauer);
 $rightDiv->add(new Spacer(20));
 $rightDiv->add($divMotionDauer);
 $rightDiv->add(new Spacer(5));
 $rightDiv->add($divSensorlogDauer);
 $rightDiv->add(new Spacer(5));
 $rightDiv->add($divTimelineDuration);
 $leftTab = new Table(array("", ""));
 $lT = $leftTab->createRow();
 $lT->setAttribute(0, $txtPageTitel);
 $lT->setAttribute(1, $txfPageTitel);
 $leftTab->addRow($lT);
开发者ID:CyborgOne,项目名称:cybihomecontrol_ui,代码行数:31,代码来源:MainSettings.php


注:本文中的Div::add方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。