"; foreach ($images as $image) { $select .= "\n"; } $select .= ""; $html = " ".make_form(make_link("tips/save"))."
Enable:
Post: {$select}
Message:
"; $page->set_title("Tips List"); $page->set_heading("Tips List"); $page->add_block(new NavBlock()); $page->add_block(new Block("Add Tip", $html, "main", 10)); } public function showTip($url, $tip) { global $page; $img = ""; if (!empty($tip['image'])) { $img = " "; } $html = "
".$img.html_escape($tip['text'])."
"; $page->add_block(new Block(null, $html, "subheading", 10)); } public function showAll($url, $tips) { global $user, $page; $html = "". "". "". "". "". ""; if ($user->can(Permissions::TIPS_ADMIN)) { $html .= ""; } $html .= ""; foreach ($tips as $tip) { $tip_enable = ($tip['enable'] == "Y") ? "Yes" : "No"; $set_link = "".$tip_enable.""; $html .= "". "". "". ( empty($tip['image']) ? "" : "" ). ""; $del_link = "Delete"; if ($user->can(Permissions::TIPS_ADMIN)) { $html .= ""; } $html .= ""; } $html .= "
IDEnabledPostTextAction
".$tip['id']."".$set_link."".$tip['text']."".$del_link."
"; $page->add_block(new Block("All Tips", $html, "main", 20)); } }