本文整理汇总了PHP中messages::view_unread_messages方法的典型用法代码示例。如果您正苦于以下问题:PHP messages::view_unread_messages方法的具体用法?PHP messages::view_unread_messages怎么用?PHP messages::view_unread_messages使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类messages
的用法示例。
在下文中一共展示了messages::view_unread_messages方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: database
break;
}
//retrieve the users workflow he had been assign ...
$db = new database();
$sql = "select * from user_stage us,\r\n\t\tstages s\r\n\t\twhere us.userID = {$userID}\r\n\t\tand\ts.stageID = us.stageID ";
// print $sql;
if (!($result = $db->query($sql))) {
die('Error:' . $db->error());
}
$user_stage = array();
while ($row = $db->fetcharray()) {
$user_stage[] = $row;
}
$db->freeresult();
$msg = new messages();
$messages = $msg->view_unread_messages($userID);
$total_unread_messages = count($messages) - 1;
$fb = new feedbacks();
$feedbacks = $fb->view_unread_feedbacks(1);
$total_unread_feedbacks = count($feedbacks) - 1;
$feedbacks = $fb->view_unread_feedbacks(2);
$total_unread_sources = count($feedbacks) - 1;
// get all articles belong in da specific category and edit by this editor assigned on dat category
if ($editor_on_category) {
$sql = "select * from article_versions av, article_category ac where \r\n\t\t\t((av.stageID = 2 and av.status != 'revise') or (av.stageID = 3 and av.status = 'revise' )) \r\n\t\t\tand (( av.isarchive = '0' and ( ac.articleID = av.articleID ) and ( ac.categoryID = '{$assigned_category}' ))) order by av.created DESC \r\n\t";
} else {
// wil display all articles regardless of category so that this user can edit them..
$sql = "select * from article_versions av where \r\n\t\t\t(av.stageID = 2 and av.status != 'revise') or (av.stageID = 3 and av.status = 'revise' ) \r\n\t\t\tand av.isarchive = '0' order by av.created DESC \r\n\t";
}
if (!($result = $db->query($sql))) {
die('Error:' . $db->error());