本文整理汇总了PHP中DmQuery::insert方法的典型用法代码示例。如果您正苦于以下问题:PHP DmQuery::insert方法的具体用法?PHP DmQuery::insert怎么用?PHP DmQuery::insert使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DmQuery
的用法示例。
在下文中一共展示了DmQuery::insert方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: header
$_POST["description"] = $dm->getDescription();
$dm->setMaxFines($_POST["max_fines"]);
$_POST["max_fines"] = $dm->getMaxFines();
if (!$dm->validateData()) {
$pageErrors["description"] = $dm->getDescriptionError();
$_SESSION["postVars"] = $_POST;
$_SESSION["pageErrors"] = $pageErrors;
header("Location: ../admin/mbr_classify_new_form.php");
exit;
}
#**************************************************************************
#* Insert new domain table row
#**************************************************************************
$dmQ = new DmQuery();
$dmQ->connect();
$dmQ->insert("mbr_classify_dm", $dm);
$dmQ->close();
#**************************************************************************
#* Destroy form values and errors
#**************************************************************************
unset($_SESSION["postVars"]);
unset($_SESSION["pageErrors"]);
#**************************************************************************
#* Show success page
#**************************************************************************
require_once "../shared/header.php";
echo $loc->getText("Classification type, %desc%, has been added.", array('desc' => $dm->getDescription()));
?>
<br><br>
<a href="../admin/mbr_classify_list.php"><?php
echo $loc->getText("return to member classification list");
示例2: header
}
if (!empty($pageErrors)) {
$_SESSION["postVars"] = $_POST;
$_SESSION["pageErrors"] = $pageErrors;
header("Location: ../admin/member_fields_new_form.php");
exit;
}
#**************************************************************************
#* Insert new domain table row
#**************************************************************************
$dm = new Dm();
$dm->setCode($_POST["code"]);
$dm->setDescription($_POST["description"]);
$dmQ = new DmQuery();
$dmQ->connect();
$dmQ->insert("member_fields_dm", $dm);
$dmQ->close();
#**************************************************************************
#* Destroy form values and errors
#**************************************************************************
unset($_SESSION["postVars"]);
unset($_SESSION["pageErrors"]);
#**************************************************************************
#* Show success page
#**************************************************************************
require_once "../shared/header.php";
echo $loc->getText("Member field, %desc%, has been added.", array('desc' => $dm->getDescription()));
?>
<br><br>
<a href="../admin/member_fields_list.php"><?php
echo $loc->getText("return to member fields list");
示例3: H
$_POST["description"] = $dm->getDescription();
$dm->setImageFile($_POST["imageFile"]);
$_POST["imageFile"] = $dm->getImageFile();
if (!$dm->validateData()) {
$pageErrors["description"] = $dm->getDescriptionError();
$_SESSION["postVars"] = $_POST;
$_SESSION["pageErrors"] = $pageErrors;
header("Location: ../admin/materials_new_form.php");
exit;
}
#**************************************************************************
#* Insert new domain table row
#**************************************************************************
$dmQ = new DmQuery();
$dmQ->connect();
$dmQ->insert("material_type_dm", $dm);
$dmQ->close();
#**************************************************************************
#* Destroy form values and errors
#**************************************************************************
unset($_SESSION["postVars"]);
unset($_SESSION["pageErrors"]);
#**************************************************************************
#* Show success page
#**************************************************************************
require_once "../shared/header.php";
echo $loc->getText("admin_materials_delMaterialType");
echo H($dm->getDescription());
?>
<br><br>
<a href="../admin/materials_list.php"><?php
示例4: H
$dm->setCode($_POST["code"]);
$_POST["code"] = $dm->getCode();
//print_r ($dm);
if (!$dm->validateData()) {
$pageErrors["description"] = $dm->getDescriptionError();
$_SESSION["postVars"] = $_POST;
$_SESSION["pageErrors"] = $pageErrors;
header("Location: ../admin/matstat_new_form.php");
exit;
}
#**************************************************************************
#* Insert new domain table row
#**************************************************************************
$dmQ = new DmQuery();
$dmQ->connect();
$dmQ->insert("biblio_status_dm", $dm);
$dmQ->close();
#**************************************************************************
#* Destroy form values and errors
#**************************************************************************
unset($_SESSION["postVars"]);
unset($_SESSION["pageErrors"]);
#**************************************************************************
#* Show success page
#**************************************************************************
require_once "../shared/header.php";
echo $loc->getText("admin_materials_listMaterialstate") . " ";
echo H($dm->getDescription()) . " " . $loc->getText("adminCollections_newAdded");
?>
<br><br>
<a href="../admin/matstat_list.php"><?php
示例5: H
$_POST["dailyLateFee"] = $dm->getDailyLateFee();
if (!$dm->validateData()) {
$pageErrors["description"] = $dm->getDescriptionError();
$pageErrors["daysDueBack"] = $dm->getDaysDueBackError();
$pageErrors["dailyLateFee"] = $dm->getDailyLateFeeError();
$_SESSION["postVars"] = $_POST;
$_SESSION["pageErrors"] = $pageErrors;
header("Location: ../admin/collections_new_form.php");
exit;
}
#**************************************************************************
#* Insert new domain table row
#**************************************************************************
$dmQ = new DmQuery();
$dmQ->connect();
$dmQ->insert("collection_dm", $dm);
$dmQ->close();
#**************************************************************************
#* Destroy form values and errors
#**************************************************************************
unset($_SESSION["postVars"]);
unset($_SESSION["pageErrors"]);
#**************************************************************************
#* Show success page
#**************************************************************************
require_once "../shared/header.php";
echo $loc->getText("adminCollections_delStart");
echo H($dm->getDescription());
echo $loc->getText("adminCollections_newAdded");
?>
<br><br>