本文整理汇总了PHP中company::open方法的典型用法代码示例。如果您正苦于以下问题:PHP company::open方法的具体用法?PHP company::open怎么用?PHP company::open使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类company
的用法示例。
在下文中一共展示了company::open方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: user
$list_countries = $country->list_countries();
$errorUserPass = false;
$errorInternal = false;
$recoverPass = false;
$errorPayment = false;
$errorprofiles = false;
if (isset($_GET["profiles"]) && trim($_GET["profiles"]) == 'false') {
$errorprofiles = true;
}
if (isset($_POST['login_username'])) {
if (count($_POST['login_username']) > 0) {
$user = new user();
$returnLogin = $user->login($_POST['login_username'], $_POST['login_password']);
if ($returnLogin) {
$company = new company();
$company->open($returnLogin->fk_company);
if ($company->status_payment == 0) {
$errorPayment = true;
} else {
$status_conf = $returnLogin->status_conf;
$id = $returnLogin->id;
if ($status_conf == 1) {
$_SESSION['emailsession'] = $_POST['login_username'];
$_SESSION['loginsession'] = $id;
redirect("/pages/menu.php");
} else {
redirect("/pages/verifyemail.php?user=" . $id);
}
}
} else {
$errorUserPass = true;
示例2: redirect
$config['bd']['host'] = 'flushoutsolutionscom.ipagemysql.com';
$config['bd']['user'] = 'learnuser';
$config['bd']['password'] = 'Le@Rn2205';
$config['bd']['base'] = 'dblearn';
$config['bd']['port'] = '3306';
}
}
function redirect($url)
{
die("<script>location.href='" . $url . "'</script>");
}
if (isset($_SESSION['loginsession'])) {
$user = new user();
$user->open($_SESSION['loginsession']);
$company = new company();
$company->open($user->fk_company);
$menu = new menu();
$isAdmin = false;
$list_Access = $menu->getAccess($user->email);
if ($list_Access) {
foreach ($list_Access as $value) {
if (is_array($list_modules)) {
if (in_array($value, $list_modules)) {
continue;
}
}
$list_modules[] = $value;
if ($value['fk_profile'] == 1) {
$isAdmin = true;
}
if ($value['start_module'] == 1 and $value['first_profile'] == 1) {