Ejemplo n.º 1
0
    $short_id = (int) $short_id;
}
if (!isset($func)) {
    $func = '';
}
//------------------------------> Eintragsliste
if ($func == '') {
    require_once $Basedir . '/../../addon_framework/classes/list/class.rex_list.inc.php';
    /**
     *  Liste anlegen 
     */
    $sql = 'SELECT * FROM rex_13_glossar, rex_13_glossar_lang WHERE language = lang_id';
    // Standard sortierung nach shortcut aufsteigend
    // Standard suchspalte ist shortcut
    $list = new rexlist($sql, 'shortcut', 'asc', 'shortcut');
    $list->setLabel($I18N_GLOSSAR->msg('label_list'));
    $list->setName('glossarlist');
    $list->setColGroup(array('50px', '*', '85px', '45px', '*'));
    // $list->debug = true;
    /**
     *  Spalten aus dem SQL-ResultSet anlegen 
     */
    $colId = new resultColumn('short_id', $I18N_GLOSSAR->msg('label_id'));
    $colShort = new resultColumn('shortcut', $I18N_GLOSSAR->msg('label_shortcut'));
    $colDesc = new resultColumn('description', $I18N_GLOSSAR->msg('label_description'));
    $colLang = new resultColumn('lang_name', $I18N_GLOSSAR->msg('label_language'));
    $colCase = new resultColumn('casesense', $I18N_GLOSSAR->msg('label_casesens'));
    // ID zentrieren
    $colId->setBodyAttributes('style="text-align: center;"');
    // colCase Werte übersetzen
    $colCase->addCondition('casesense', '0', $I18N_GLOSSAR->msg('no'));
Ejemplo n.º 2
0
if (!isset($entry_id)) {
    $entry_id = 0;
} else {
    $entry_id = (int) $entry_id;
}
//------------------------------> Eintragsliste
if ($func == '') {
    require_once $Basedir . '/../../addon_framework/classes/list/class.rex_list.inc.php';
    /**
     *  Liste anlegen 
     */
    $sql = 'SELECT * FROM ' . TBL_GBOOK;
    // Standard sortierung nach id absteigend
    // Standard author ist shortcut
    $list = new rexlist($sql, 'id', 'desc', 'author');
    $list->setLabel($I18N_GBOOK->msg('label_list'));
    //$list->debug = true;
    /**
     *  Spalten aus dem SQL-ResultSet anlegen 
     */
    $colId = new resultColumn('id', $I18N_GBOOK->msg('label_id'));
    $colAuthor = new resultColumn('author', $I18N_GBOOK->msg('label_author'));
    $colMsg = new resultColumn('message', $I18N_GBOOK->msg('label_message'), 'truncate');
    $colUrl = new resultColumn('url', $I18N_GBOOK->msg('label_url'), 'url');
    $colCreated = new resultColumn('created', $I18N_GBOOK->msg('label_created'), 'strftime', 'datetime');
    // ID zentrieren
    $colId->setBodyAttributes('style="text-align: center;"');
    /**
     *  Statische Spalten anlegen 
     */
    // Antworten link