function nameValueRow($name, $value)
{
    $row = new JUI\Table\Row();
    $row->setClick(new JUI\Click(JUI\Click::openPlugin, 'plg_serversettings', 'home', ''));
    $columnName = new JUI\Table\Column();
    $nameText = new JUI\Text($name);
    $nameText->setAppearance(JUI\Text::BOLD);
    $columnName->add($nameText);
    $columnValue = new JUI\Table\Column();
    $valueText = new JUI\Text($value);
    $columnValue->add($valueText);
    $row->addColumn($columnName);
    $row->addColumn($columnValue);
    return $row;
}
$configEditor = new ConfigManager(dirname(dirname(dirname(dirname(__FILE__)))) . '/config.php');
$config = $configEditor->loadConfig();
if (!empty($_POST)) {
    foreach ($_POST as $key => $value) {
        $configEditor->setValue($key, $value);
    }
    $configEditor->save();
    $jUI->setWarning('Eingaben gespeichert.');
}
$jUI->add(new JUI\Heading("Konfigurations-Editor"));
$table = new JUI\Table();
foreach ($config as $key => $value) {
    $keyText = new JUI\Text($key);
    $keyText->setAppearance(JUI\Text::BOLD);
    $keyDescription = new JUI\Text($value['description']);
    $keyDescription->setAppearance(JUI\Text::ITALIC);
    $keyColumn = new JUI\Table\Column();
    $keyColumn->add($keyText);
    $keyColumn->add($keyDescription);
    $row = new JUI\Table\Row();
    $row->addColumn($keyColumn);
    if ($value['type'] == "STRING") {
        $view = new JUI\Input($key);
        $view->setValue($value['value']);
    } else {
        if ($value['type'] == "INTEGER") {
            $view = new JUI\Input($key);
            $view->setAccepted(JUI\Input::NUMBERS);
            $view->setValue($value['value']);
        } else {
            if ($value['type'] == "BOOLEAN") {
 $pluginManager->unsetTemporary('data');
 $pluginManager->unsetTemporary('files');
 $notifyInput = new JUI\Input('nachricht');
 $notifyInput->setLabel('Nachricht: ');
 $notifyInput->setValue($data);
 $jUI->add($notifyInput);
 $submitButton = new JUI\Button('Nachricht senden', TRUE);
 $jUI->add($submitButton);
 //$nachrichten = $pluginManager->databaseManager->getValues(Array("recipient"=>Array("value"=>$recipient, "operator"=>"=", "or"=>array("name"=>"sender","value"=>$recipient))));
 $nachrichten = $pluginManager->databaseManager->getValues(array('((`recipient`=? AND `sender`=?) OR (`recipient`=? AND `sender`=?))', 'iiii', array($recipient, $loginManager->getId(), $loginManager->getId(), $recipient)));
 if (!empty($nachrichten)) {
     foreach ($nachrichten as $nachricht) {
         $sender = $nachricht['sender'];
         $type = $nachricht['type'];
         $senderView = new JUI\Text($senderList[$sender]['username']);
         $senderView->setAppearance(JUI\Text::BOLDITALIC);
         $senderView->setColor('#' . stringToColorCode($sender));
         if (!empty($type) && $type == '1') {
             $file = $nachricht['text'];
             if ($pluginManager->fileManager->fileExists('thumb/' . $file, TRUE, FileManager::FILESYSTEM_PLUGIN_PUBLIC)) {
                 $file = 'thumb/' . $file;
             }
             $hash = $pluginManager->fileManager->getImageHash($file, FileManager::FILESYSTEM_PLUGIN_PUBLIC);
             $contentView = new JUI\Image($hash);
             $contentView->setClick(new JUI\Click(JUI\Click::openMedia, 'image', FileManager::FILESYSTEM_PLUGIN_PUBLIC . '://plg_messenger/' . $nachricht['text']));
         } else {
             $contentView = new JUI\Text($nachricht['text']);
             if ($nachricht['sender'] != $loginManager->getId()) {
                 $senderView->setAlign(JUI\Text::RIGHT);
                 $contentView->setAlign(JUI\Text::RIGHT);
             }
function showServerLog($jUI, $id)
{
    global $logManager;
    global $pluginManager;
    $jUI->add(new JUI\Heading("Eintrag:  " . $id));
    $log = $logManager->getLog($id);
    $table = new JUI\Table();
    $row4 = new JUI\Table\Row();
    $row4->addColumn("Plugin");
    if (empty($log['user'])) {
        $statusText = new JUI\Text("Warnung");
        $statusText->setColor('FF0000');
    } else {
        if ($log['plugin'] == "plg_serversettings") {
            $statusText = new JUI\Text("Info");
            $statusText->setColor('00008B');
        } else {
            $statusText = new JUI\Text("Normal");
        }
    }
    $row4->addColumn($statusText);
    $table->addRow($row4);
    $row1 = new JUI\Table\Row();
    $row1->addColumn("Zeit");
    $row1->addColumn(date("Y-m-d H:i:s", $log['timestamp']));
    $table->addRow($row1);
    $row3 = new JUI\Table\Row();
    $row3->addColumn("Plugin");
    $pluginText = new JUI\Text($log['plugin']);
    $pluginText->setAppearance(JUI\Text::BOLD);
    $row3->addColumn($pluginText);
    $table->addRow($row3);
    $row2 = new JUI\Table\Row();
    $row2->addColumn("Nachricht");
    $row2->addColumn($log['text']);
    $table->addRow($row2);
    $jUI->add($table);
    $delete = new JUI\Button('Eintrag löschen');
    $delete->setClick(new JUI\Click(JUI\Click::openPlugin, $pluginManager, 'logs', 'server/' . $id . '/delete'));
    $jUI->add($delete);
}