本文整理汇总了PHP中dbconnection::getRoomId方法的典型用法代码示例。如果您正苦于以下问题:PHP dbconnection::getRoomId方法的具体用法?PHP dbconnection::getRoomId怎么用?PHP dbconnection::getRoomId使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类dbconnection
的用法示例。
在下文中一共展示了dbconnection::getRoomId方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
}
$_user = "../layout/users.php";
$edtuid = $_POST['edtuid'];
$rid = $_POST['rid'];
$uname = $_POST['username'];
$email = $_POST['email'];
$rname = $_POST['rnum'];
$ext = $_POST['ext'];
$fname = $_POST['fname'];
$lname = $_POST['lname'];
if ($vobj->ifUserExists($uname)) {
echo "Ussser already exists";
exit;
}
if ($vobj->ifEmailExists($email)) {
echo "email already exists";
exit;
}
// if($pwd != $cpwd){
// echo "Passwords did not match";
// exit;
// }
if (!$vobj->ifRoomExists($rname)) {
echo "Room number : " . $uname . " does not exists in the system";
exit;
}
$rid = $dbobj->getRoomId($rname);
echo "before";
$dbobj->Update("update user set `uname`='{$uname}',`email`='{$email}',`rid`='{$rid}',`ext`='{$ext}' where `uid`='{$edtuid}'");
echo "after";
header("location:" . $_user);
示例2: basename
echo "User already exists";
exit;
}
if ($vobj->ifEmailExists($email)) {
echo "email already exists";
exit;
}
if ($pwd != $cpwd) {
echo "Passwords did not match";
exit;
}
if (!$vobj->ifRoomExists($rnum)) {
echo "Room number : " . $rnum . " does not exists in the system";
exit;
} else {
$rid = $dbobj->getRoomId($rnum);
}
// if($vobj->ifExtExists($ext)){
// echo "User already exists";
// exit;
// }
// upload image
$target_dir = "../images/user/";
$target_file = $target_dir . basename($_FILES["fileToUpload"]["name"]);
$uploadOk = 1;
$imageFileType = pathinfo($target_file, PATHINFO_EXTENSION);
$imgname = $uname . "." . $imageFileType;
$target_file = $target_dir . $imgname;
// Check if image file is a actual image or fake image
if (isset($_POST["submit"])) {
$check = getimagesize($_FILES["fileToUpload"]["tmp_name"]);