Seite 1 von 1

Plugin Navigationsbereich - welche Möglichkeiten

Verfasst: Mi 12. Aug 2009, 16:25
von rethus
Ich habe ein Plugin und habe es so entwickelt, wie ich es aus den Beispielen entnommen habe.
Für die Navigation beispielsweise so:

Code: Alles auswählen

if ($_GET["do"] == "new_structure" || $_GET["do"] == "edit_structure")
{
        $struc_name = htmlspecialchars ($_GET['struc_name']);
        $struc_name = stripslashes($group);

        $groupDesc = htmlspecialchars ($_GET['groupDesc']);
        $groupDesc = stripslashes ($groupDesc);

        // Attribut ausgeben
        $ui = new UI_Menu();
        $pm_structure->query("SELECT * FROM ".$pm_structure->name." ORDER BY struc_pos");
        while ($pm_structure->next_record())
        {
                $i++;
                $id             = $pm_structure->f("struc_id");
                $sname          = $pm_structure->f("struc_name");
                $beschr         = $pm_structure->f("struc_desc");
                $struc_sort        = (int)$pm_structure->f("struc_pos");
                $struc_status      = (int)$pm_structure->f("struc_status");

                if($struc_status==1) $struc_statusus ="online"; else $struc_statusus ="offline";
                $struc_status_txt = i18n("Attribut ist momentan $struc_statusus");

                $oLink = new cHTMLLink;
                $oLink->setMultiLink($area, "", $area, "");
                $oLink->setCustom("do", $do);
                $oLink->setCustom("structure_status", $structure_status);

                if($do=="new_structure"){
                        $sEditTitle = i18n("Attribut anlegen");
                }else{
                        $sEditTitle = i18n("Attribut bearbeiten");
                        // id nur übergeben, wenn Datensatz editiert wird.
                        $oLink->setCustom("struc_id", $id);
                }
                        $status = new Link;
                        $status->setMultiLink("product_matrix","","product_matrix","");
                        $status->setCustom("do","status");
                        $status->setCustom("struc_id","$id");
                        $status->setCustom("struc_status", $struc_status);
                        $status->setCustom("struc_name", $sname);
                        $status->setAlt("$struc_status_txt");
                        $status->setContent('<img src="'.$cfg['path']['images'].$struc_statusus.'.gif" border="0" title="'.$struc_status_txt.'" alt="'.$struc_status_txt.'">');

                        $edit = new Link;
                        $edit->setMultiLink("product_matrix","","product_matrix","");
                        $edit->setCustom("do","$do");
                        $edit->setCustom("struc_id","$id");
                        $edit->setAlt($sEditTitle);
                        $edit->setContent('<img src="'.$cfg['path']['images'].'but_edit.gif" border="0" title="'.$sEditTitle.'" alt="'.$sEditTitle.'">');

                        $sDelTitle = i18n("Attribut löschen");
                        $sDelete = '<a title="'.$sDelTitle.'" href="javascript://" onclick="showDelMsg('.$id.',\''.addslashes($sname).'\',\'del_structure\')"><img src="'.$cfg['path']['images'].'delete.gif" border="0" title="'.$sDelTitle.'" alt="'.$sDelTitle.'"></a>';

                $ui->setTitle($i,$sname);
                $ui->setLink($i,$oLink);
                $ui->setImage($i, "images/spacer.gif");
                $ui->setActions($i, 'struc_statusus', $status->render());
                $ui->setActions($i, 'struc_edit', $edit->render());
                $ui->setActions($i, 'delete', $sDelete);
        }
                $liste = $liste_1.$ui->render(false);
                $page->setContent($liste);
                $page->render();
}
Diese UI_Menu-Logik funktioniert ja so, dass man dann ein neues cHTMLLink-Objekt erstellt, dieses bestückt und dann der UI hinzufügt.

Ist es irgensie möglich nur einen normalen Text mit in diese Struktur zu packen (ohne dass es verlinkt ist)?
Also am Beispiel dieser Grafik:
Plugin-Navigation
Plugin-Navigation
Plugin_navi.jpg (59.33 KiB) 2737 mal betrachtet
Hier wären dann Versicherungen, Fonds und Teste nicht verlinkt sondern halt nur so ne art Gruppierungs-Überschrift.