本文整理汇总了PHP中Menu::addMenu方法的典型用法代码示例。如果您正苦于以下问题:PHP Menu::addMenu方法的具体用法?PHP Menu::addMenu怎么用?PHP Menu::addMenu使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Menu
的用法示例。
在下文中一共展示了Menu::addMenu方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Menu
require_once '../classes/connection.class.php';
require_once '../classes/menu.class.php';
$addmenuobj = new Menu();
/*echo '<pre>';
print_r($addmenuobj);
echo '</pre>';
exit;
*/
$menu_id = mysqli_real_escape_string($addmenuobj->conxn, $_POST['menu_id']);
$menu_category = mysqli_real_escape_string($addmenuobj->conxn, $_POST['menu_category']);
$category_title = mysqli_real_escape_string($addmenuobj->conxn, $_POST['category_title']);
$menu_title = mysqli_real_escape_string($addmenuobj->conxn, $_POST['menu_title']);
$menu_price = mysqli_real_escape_string($addmenuobj->conxn, $_POST['menu_price']);
$addmenuobj->setMenuID($menu_id);
$addmenuobj->setMenuCategory($menu_category);
$addmenuobj->setCategoryTitle($category_title);
$addmenuobj->setMenuTitle($menu_title);
$addmenuobj->setMenuPrice($menu_price);
//$adduserobj->setError($er);
//$adduserobj->setMessage($msg);
$addmenuobj->addMenu();
/*echo '<pre>';
print_r ($adduserobj);
echo '</pre>';
exit;*/
if ($addmenuobj) {
header('location:../index.php?page=menu&action=view');
$_SESSION['msg'] = $addmenuobj->msg = "The menu has been added sucessfully";
} else {
echo $_SESSION['msg'] = $addmenuobj->msg = "Sorry the menu has not been added, please try again later";
}
示例2: welcomePageTitle
<div id="main">
<?php
include 'section/LinkExpo.php';
?>
<div id="preferencewelcomepage">
<?php
welcomePageTitle($expo->title, 1);
if (PREF == 'New') {
welcomePageContent($author, $expo);
} else {
welcomePageContent();
}
welcomePageNavi();
?>
</div><!-- preferencewelcomepage -->
</div><!-- main -->
<?php
$menuItemArray = array();
Menu::addMenu($menuItemArray);
include 'section/footer.php';
?>
</div><!-- container -->
</body></html>
示例3: swwat_createInputSubmit
<?php
// ok, start the html
include 'section/header.php';
?>
<div id="main">
<div id="sendmessagepage_send">
<form method="POST" name="sendmessagepage_form" action="WorkerMessageAction.php">
<?php
echo "Subject: ";
echo '<input type="text" name="', PARAM_SUBJECT_MESSAGE, '" value="" length="30"/>';
echo "<p/>\n";
echo '<textarea name="', PARAM_MESSAGE, '" rows="3" cols="40"></textarea>';
echo "<br/><br/>\n";
swwat_createInputSubmit(PARAM_SEND_MESSAGE, "Send Message");
?>
</form>
</div><!-- sendmessagepage_send -->
</div><!-- main -->
<?php
Menu::addMenu(array());
include 'section/footer.php';
?>
</div><!-- container -->
</body></html>