Aber irgendwas funzt bei mir im Kopf nicht richtig.
include.hello_world_menu.php:
Code: Alles auswählen
$page = "main.php?area=$area&frame=2&test=test&contenido=".$sess->id; // link to same frame
if (isset($cfg['plugins']['hello_world'])) { // can be used in a modul !
$plugin = true;
} else {
$plugin = false;
echo "<!-- plugin not found - db access deactivated //-->\n";
}
$tpl->reset();
$tpl->set('s', 'HELLO_WORLD_MENU', '<a href="'.$page.'">weiter</a>');
$tpl->generate($cfg['plugins']['hello_world'] . $cfg['path']['templates'] . $cfg['templates']['hello_world_menu']);
Code: Alles auswählen
$tpl->reset();
$test = $_REQUEST["test"];
if ($_REQUEST["test"] != "test") {
$tpl->set('s', 'HELLO_WORLD_EDIT', "If zweig");
}
else{
$tpl->set('s', 'HELLO_WORLD_EDIT', "Else zweig");
}
$tpl->set('s', 'TEST', "der ".$test);
$tpl->generate($cfg['plugins']['hello_world'] . $cfg['path']['templates'] . $cfg['templates']['hello_world_edit']);