本文整理汇总了PHP中Forum::getAllCategory方法的典型用法代码示例。如果您正苦于以下问题:PHP Forum::getAllCategory方法的具体用法?PHP Forum::getAllCategory怎么用?PHP Forum::getAllCategory使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Forum
的用法示例。
在下文中一共展示了Forum::getAllCategory方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: htmlentities
}
if (isset($_POST["catall"])) {
$reply = true;
//= $formu->getAllCategory();
if ($reply == true) {
echo 'Category added succesfully';
} else {
print '<option>Nothing Selected</option>';
}
}
if (isset($_POST["newcategory"])) {
echo '<div id="newcategorydiv"><form class="signupform" id="signupform" method="post" action="" enctype="multipart/form-data">' . '<p class="forumfeed"></p>' . '<fieldset><legend><span class="title">category Details</span></legend><p><label>Name:</label>' . '<input id="cat" class="smallinputs" name="firstname" type="text" required /></p><p><label>Category Name:</label>' . '<input id="cat_name" class="smallinputs" name="middlename" type="text" required /></p><p><label>Category Description:</label>' . '<textarea id="cat_desc" class="smalltextarea" cols="50" rows="4" required></textarea></p>' . '</fieldset></form><p style="text-align:center"><button class="submit" id="newcategorybt" name="cratnewtopic">Create Category:</button ></p></div>';
}
if (isset($_POST["newtopic"])) {
global $forum;
echo ' <div id="newtopicdiv"><form class="signupform" id="newtopicform" method="post" action="" enctype="multipart/form-data">' . '<p class="forumfeed"></p><fieldset><legend><span class="title">Topic deatils</span></legend>' . '<p><label>Topic Subject</label><input id="topic_subject" class="smallinputs" name="firstname" type="text" required /></p>' . '<p><label>Topic Category</label><select id="topic_cat_select" class="smallinput" name="firstname" value="' . $_SESSION["username"] . '" required>' . $forum->getAllCategory() . '</select></p>' . '<p><label> Topic By</label><input id="topic_by" class="smallinputs" name="middlename" userid="' . $_SESSION["user_id"] . '" type="text" value="' . $_SESSION["username"] . '" required /></p>' . '</fieldset></form><p style="text-align:center"><button class="submit" id="newtopicbt" name="cratnewtopic">Create Topic</button ></p></div>';
}
if (isset($_POST["getallforum"])) {
//$reply = $formu->addCategory();
echo 'Forum for will display most recent forms';
}
if (isset($_POST["c_view"])) {
echo $forum->getAllCategoryView();
}
if (isset($_POST["topicspecview"])) {
$topic = htmlentities(htmlspecialchars($_POST["topic"]));
echo $forum->getTopicSpecView($topic);
}
if (isset($_POST["t_view"])) {
echo $forum->getAllTopicView();
}
示例2: isset
}
if (isset($_POST["catall"])) {
$reply = true;
//= $formu->getAllCategory();
if ($reply == true) {
echo 'Category added succesfully';
} else {
print '<option>Nothing Selected</option>';
}
}
if (isset($_POST["newcategory"])) {
echo '<div id="newcategorydiv"><form>' . '<p class="forumfeed"></p>' . '<fieldset><legend><span class="boldertext">Category Details</span></legend>' . '<input id="cat" data-clear-btn="true" data-mini="true" class="" value="' . isset($_SESSION["user_id"]) ? $_SESSION["user_id"] : "" . '" type="hidden" required /></p>' . '<p><label>Category Name:</label>' . '<input id="cat_name" data-clear-btn="true" data-mini="true" class="" name="middlename" type="text" required /></p>' . '<p><label>Category Description:</label>' . '<textarea id="cat_desc" class="smalltextarea" cols="30" rows="4" required></textarea></p>' . '</fieldset></form></div></p>';
}
if (isset($_POST["newtopic"])) {
global $forum;
echo ' <div id="newtopicdiv"><form>' . '<p class="forumfeed"></p>' . '<fieldset><legend><span class="boldertext">Topic deatils</span></legend>' . '<p><label>Topic Subject</label>' . '<input id="topic_subject" class="" type="text" required /></p>' . '<p><label>Topic Category</label>' . '<select id="topic_cat_select" class="" required>' . $forum->getAllCategory() . '</select></p>' . '<p><label> Topic By</label>' . '<input id="topic_by" class="" userid="' . $_SESSION["user_id"] . '" type="text" value="' . $_SESSION["username"] . '" required /></p>' . '</fieldset></form></div>';
}
if (isset($_POST["getallforum"])) {
//$reply = $formu->addCategory();
echo $forum->goHome();
}
////category view codes
if (isset($_POST["c_view"])) {
echo $forum->getAllCategoryView();
}
//topic spec view codes
if (isset($_POST["topicspecview"])) {
$topic = htmlentities(htmlspecialchars($_POST["topic_subject"]));
$id = htmlentities(htmlspecialchars($_POST["topic_id"]));
echo $forum->getTopicSpecView($topic, $id);
}