本文整理汇总了PHP中Staff::getStaffmemberById方法的典型用法代码示例。如果您正苦于以下问题:PHP Staff::getStaffmemberById方法的具体用法?PHP Staff::getStaffmemberById怎么用?PHP Staff::getStaffmemberById使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Staff
的用法示例。
在下文中一共展示了Staff::getStaffmemberById方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: DatabaseBean
<?php
include_once 'config.php';
include_once '../checkAdminPagePermissions.php';
$dbBean = new DatabaseBean();
$general = new General($dbBean);
$menu_id = empty($_REQUEST['menu_id']) ? $_SESSION['menu_id'] : $_REQUEST['menu_id'];
$heading = $general->getPageHeading($menu_id);
$Staff = new Staff($dbBean);
$rows = $Staff->getStaffmemberById($_REQUEST['id']);
?>
<!DOCTYPE html>
<!--[if IE 8]> <html lang="en" class="ie8 no-js"> <![endif]-->
<!--[if IE 9]> <html lang="en" class="ie9 no-js"> <![endif]-->
<!--[if !IE]><!-->
<html lang="en">
<!--<![endif]-->
<!-- BEGIN HEAD -->
<head>
<?php
include '../common.php';
?>
<!-- BEGIN PAGE LEVEL STYLES -->
<link rel="stylesheet" type="text/css" href="<?php
echo ADMIN_URL;
?>
/assets/global/plugins/datatables/plugins/bootstrap/dataTables.bootstrap.css"/>
<link rel="stylesheet" type="text/css" href="<?php
echo ADMIN_URL;
示例2: deleteStaffmember
public static function deleteStaffmember($large_img_path, $thumb_img_path, $idsToDelete)
{
global $dbBean;
if (count($idsToDelete) <= 0) {
return false;
}
$edited = false;
foreach ($idsToDelete as $ids) {
$s = Staff::getStaffmemberById($ids);
$image = $s->image;
$cond = array("id" => $ids);
$fieldvalues = array('is_deleted' => '1');
if (!($edited = $dbBean->UpdateRows("staff", $fieldvalues, $cond))) {
break;
}
if ($image != '') {
if (file_exists($large_img_path . $image)) {
unlink($large_img_path . $image);
}
if (file_exists($thumb_img_path . $image)) {
unlink($thumb_img_path . $image);
}
}
}
return $edited;
}