本文整理汇总了PHP中FieldSubmitted函数的典型用法代码示例。如果您正苦于以下问题:PHP FieldSubmitted函数的具体用法?PHP FieldSubmitted怎么用?PHP FieldSubmitted使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了FieldSubmitted函数的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: readWebValue
function readWebValue(&$avalues, &$blobfields, $legacy1, $legacy2, &$filename_values)
{
$this->getPostValueAndType();
if (FieldSubmitted($this->goodFieldName . "_" . $this->id)) {
$this->webValue = prepare_for_db($this->field, $this->webValue, $this->webType);
} else {
$this->webValue = false;
}
if ($this->pageObject->pageType == PAGE_EDIT && $this->pageObject->pSetEdit->isReadonly($this->field)) {
if ($this->pageObject->pSetEdit->getAutoUpdateValue($this->field)) {
$this->webValue = $this->pageObject->pSetEdit->getAutoUpdateValue($this->field);
} else {
if ($this->pageObject->pSetEdit->getOwnerTable($this->field) != $this->pageObject->pSetEdit->getStrOriginalTableName()) {
$this->webValue = false;
}
}
}
if (!($this->webValue === false)) {
if ($this->connection->dbType == nDATABASE_Informix) {
if (IsTextType($this->pageObject->pSetEdit->getFieldType($this->field))) {
$blobfields[] = $this->field;
}
}
$avalues[$this->field] = $this->webValue;
}
}
示例2: md5
$value = false;
}
if (!($value === false)) {
if (0 && "Serial Num" == "Password" && $url_page == "admin_users_") {
$value = md5($value);
}
$avalues["Serial Num"] = $value;
}
}
// processibng Serial Num - end
// processing Entry Date - start
$inlineAddOption = true;
if ($inlineAddOption) {
$value = postvalue("value_Entry_Date_" . $id);
$type = postvalue("type_Entry_Date_" . $id);
if (FieldSubmitted("Entry Date_" . $id)) {
$value = prepare_for_db("Entry Date", $value, $type);
} else {
$value = false;
}
if (!($value === false)) {
if (0 && "Entry Date" == "Password" && $url_page == "admin_users_") {
$value = md5($value);
}
$avalues["Entry Date"] = $value;
}
}
// processibng Entry Date - end
// insert masterkey value if exists and if not specified
if (@$_SESSION[$sessionPrefix . "_mastertable"] == "dbo.LU_Module Condition") {
if (postvalue("masterkey1")) {
示例3: array
if ($inlineadd == ADD_SIMPLE || $inlineadd == ADD_MASTER || $inlineadd == ADD_POPUP) {
if ($pageObject->captchaExists()) {
$pageObject->doCaptchaCode();
}
}
// insert new record if we have to
if (@$_POST["a"] == "added") {
$afilename_values = array();
$avalues = array();
$blobfields = array();
// processing Type - start
$inlineAddOption = true;
if ($inlineAddOption) {
$value = postvalue("value_Type_" . $id);
$type = postvalue("type_Type_" . $id);
if (FieldSubmitted("Type_" . $id)) {
$value = prepare_for_db("Type", $value, $type);
} else {
$value = false;
}
if (!($value === false)) {
if (0 && "Type" == "Password" && $url_page == "admin_users_") {
$value = md5($value);
}
$avalues["Type"] = $value;
}
}
// processibng Type - end
$failed_inline_add = false;
// add filenames to values
foreach ($afilename_values as $akey => $value) {
示例4: readWebValue
function readWebValue(&$avalues, &$blobfields, $strWhereClause, $oldValuesRead, &$filename_values)
{
$filename = "";
$this->getPostValueAndType();
if (FieldSubmitted($this->goodFieldName . "_" . $this->id)) {
$fileNameForPrepareFunc = securityCheckFileName(postvalue("filename_" . $this->goodFieldName . "_" . $this->id));
if ($this->pageObject->pageType != PAGE_EDIT) {
$prepearedFile = prepare_file($this->webValue, $this->field, "file2", $fileNameForPrepareFunc, $this->id);
if ($prepearedFile !== false) {
$this->webValue = $prepearedFile["value"];
$filename = $prepearedFile["filename"];
} else {
$this->webValue = false;
}
} else {
if (substr($this->webType, 0, 4) == "file") {
$prepearedFile = prepare_file($this->webValue, $this->field, $this->webType, $fileNameForPrepareFunc, $this->id);
if ($prepearedFile !== false) {
$this->webValue = $prepearedFile["value"];
$filename = $prepearedFile["filename"];
} else {
$this->webValue = false;
}
} else {
if (substr($this->webType, 0, 6) == "upload") {
if ($this->webType == "upload1") {
// file deletion, read filename from the database
if (!$oldValuesRead) {
$rsold = db_query($this->pageObject->gQuery->gSQLWhere($strWhereClause), $this->conn);
$dataold = db_fetch_array($rsold);
$oldValuesRead = true;
}
$fileNameForPrepareFunc = $dataold[$this->field];
}
$this->webValue = prepare_upload($this->field, $this->webType, $fileNameForPrepareFunc, $this->webValue, "", $this->id, $this->pageObject);
}
}
}
} else {
$this->webValue = false;
}
if (!($this->webValue === false)) {
if ($this->webValue) {
if ($this->pageObject->pSetEdit->getCreateThumbnail($this->field)) {
$ext = CheckImageExtension(GetUploadedFileName("value_" . $this->goodFieldName . "_" . $this->id));
$thumb = CreateThumbnail($this->webValue, $this->pageObject->pSetEdit->getThumbnailSize($this->field), $ext);
$blobfields[] = $this->pageObject->pSetEdit->getStrThumbnail($this->field);
$avalues[$blobfields[count($blobfields) - 1]] = $thumb;
}
if ($this->pageObject->pSetEdit->getResizeOnUpload($this->field)) {
$ext = CheckImageExtension(GetUploadedFileName("value_" . $this->goodFieldName . "_" . $this->id));
$this->webValue = CreateThumbnail($this->webValue, $this->pageObject->pSetEdit->getNewImageSize($this->field), $ext);
}
} else {
if ($this->pageObject->pageType == PAGE_EDIT && $this->pageObject->pSetEdit->getCreateThumbnail($this->field)) {
$blobfields[] = $this->pageObject->pSetEdit->getStrThumbnail($this->field);
$avalues[$blobfields[count($blobfields) - 1]] = "";
}
}
$blobfields[] = $this->field;
$avalues[$this->field] = $this->webValue;
}
if ($filename && $this->pageObject->pSetEdit->getStrFilename($this->field)) {
$filename_values[$this->pageObject->pSetEdit->getStrFilename($this->field)] = $filename;
}
}
示例5: whereAdd
if (@$_POST["a"] == "edited") {
$strWhereClause = whereAdd($strWhereClause, KeyWhere($keys));
$oldValuesRead = false;
if ($eventObj->exists("AfterEdit") || $eventObj->exists("BeforeEdit") || $auditObj) {
// read old values
$rsold = db_query(gSQLWhere($strWhereClause), $conn);
$dataold = db_fetch_array($rsold);
$oldValuesRead = true;
}
$evalues = $efilename_values = $blobfields = array();
// processing Location - begin
$condition = 1;
if ($condition) {
$value = postvalue("value_Location_" . $id);
$type = postvalue("type_Location_" . $id);
if (FieldSubmitted("Location_" . $id)) {
$value = prepare_for_db("Location", $value, $type);
} else {
$value = false;
}
if ($value !== false) {
if (0 && "Location" == "Password" && $url_page == "admin_users_") {
$value = md5($value);
}
$evalues["Location"] = $value;
}
}
// processing Location - end
foreach ($efilename_values as $ekey => $value) {
$evalues[$ekey] = $value;
}
示例6: md5
$value = false;
}
if ($value !== false) {
if (0 && "Location" == "Password" && $url_page == "admin_users_") {
$value = md5($value);
}
$evalues["Location"] = $value;
}
}
// processing Location - end
// processing Customer Type - begin
$condition = 1;
if ($condition) {
$value = postvalue("value_Customer_Type_" . $id);
$type = postvalue("type_Customer_Type_" . $id);
if (FieldSubmitted("Customer Type_" . $id)) {
$value = prepare_for_db("Customer Type", $value, $type);
} else {
$value = false;
}
if ($value !== false) {
if (0 && "Customer Type" == "Password" && $url_page == "admin_users_") {
$value = md5($value);
}
$evalues["Customer Type"] = $value;
}
}
// processing Customer Type - end
foreach ($efilename_values as $ekey => $value) {
$evalues[$ekey] = $value;
}
示例7: readWebValue
/**
*
*/
function readWebValue(&$avalues, &$blobfields, $legacy1, $legacy2, &$filename_values)
{
$this->getPostValueAndType();
if (FieldSubmitted($this->goodFieldName . "_" . $this->id)) {
$fileNameForPrepareFunc = securityCheckFileName(postvalue("filename_" . $this->goodFieldName . "_" . $this->id));
if ($this->pageObject->pageType != PAGE_EDIT) {
$this->webValue = prepare_upload($this->field, "upload2", $fileNameForPrepareFunc, $fileNameForPrepareFunc, "", $this->id, $this->pageObject);
} else {
if (substr($this->webType, 0, 4) == "file") {
$prepearedFile = prepare_file($this->webValue, $this->field, $this->webType, $fileNameForPrepareFunc, $this->id);
if ($prepearedFile !== false) {
$this->webValue = $prepearedFile["value"];
$filename = $prepearedFile["filename"];
} else {
$this->webValue = false;
}
} else {
if (substr($this->webType, 0, 6) == "upload") {
if ($fileNameForPrepareFunc) {
$this->webValue = $fileNameForPrepareFunc;
}
if ($this->webType == "upload1") {
// file deletion, read filename from the database
$oldValues = $this->pageObject->getOldRecordData();
$fileNameForPrepareFunc = $oldValues[$this->field];
}
$this->webValue = prepare_upload($this->field, $this->webType, $fileNameForPrepareFunc, $this->webValue, "", $this->id, $this->pageObject);
}
}
}
} else {
$this->webValue = false;
}
if (!($this->webValue === false)) {
if ($this->webValue && $this->pageObject->pSetEdit->getCreateThumbnail($this->field)) {
$contents = GetUploadedFileContents("value_" . $this->goodFieldName . "_" . $this->id);
$ext = CheckImageExtension(GetUploadedFileName("value_" . $this->goodFieldName . "_" . $this->id));
$thumb = CreateThumbnail($contents, $this->pageObject->pSetEdit->getThumbnailSize($this->field), $ext);
$this->pageObject->filesToSave[] = new SaveFile($thumb, $this->pageObject->pSetEdit->GetStrThumbnail($this->field) . $this->webValue, $this->pageObject->pSetEdit->getUploadFolder($this->field), $this->pageObject->pSetEdit->isAbsolute($this->field));
}
$avalues[$this->field] = $this->webValue;
}
}
示例8: readWebValue
function readWebValue(&$avalues, &$blobfields, $strWhereClause, $oldValuesRead, &$filename_values)
{
$this->getPostValueAndType();
if (FieldSubmitted($this->goodFieldName."_".$this->id))
$this->webValue = prepare_for_db($this->field, $this->webValue, $this->webType);
else
$this->webValue = false;
if($this->pageObject->pageType == PAGE_EDIT && $this->pageObject->pSetEdit->isReadonly($this->field))
{
if( $this->pageObject->pSetEdit->getAutoUpdateValue($this->field) )
$this->webValue = $this->pageObject->pSetEdit->getAutoUpdateValue($this->field);
else
if($this->pageObject->pSetEdit->getOwnerTable($this->field) != $this->pageObject->pSetEdit->getStrOriginalTableName())
$this->webValue = false;
}
if(!($this->webValue===false))
{
$avalues[$this->field] = $this->webValue;
}
}
示例9: readWebValue
function readWebValue(&$avalues, &$blobfields, $strWhereClause, $oldValuesRead, &$filename_values = null)
{
$this->getPostValueAndType();
if (FieldSubmitted($this->goodFieldName . "_" . $this->id)) {
$fileNameForPrepareFunc = securityCheckFileName(postvalue("filename_" . $this->goodFieldName . "_" . $this->id));
if ($this->pageObject->pageType != PAGE_EDIT) {
$this->webValue = prepare_upload($this->field, "upload2", $fileNameForPrepareFunc, $fileNameForPrepareFunc, "", $this->id, $this->pageObject);
} else {
if (substr($this->webType, 0, 4) == "file") {
$prepearedFile = prepare_file($this->webValue, $this->field, $this->webType, $fileNameForPrepareFunc, $this->id);
if ($prepearedFile !== false) {
$this->webValue = $prepearedFile["value"];
$filename = $prepearedFile["filename"];
} else {
$this->webValue = false;
}
} else {
if (substr($this->webType, 0, 6) == "upload") {
if ($fileNameForPrepareFunc) {
$this->webValue = $fileNameForPrepareFunc;
}
if ($this->webType == "upload1") {
// file deletion, read filename from the database
if (!$oldValuesRead) {
$rsold = db_query($this->pageObject->gQuery->gSQLWhere($strWhereClause), $this->conn);
$dataold = db_fetch_array($rsold);
$oldValuesRead = true;
}
$fileNameForPrepareFunc = $dataold[$this->field];
}
$this->webValue = prepare_upload($this->field, $this->webType, $fileNameForPrepareFunc, $this->webValue, "", $this->id, $this->pageObject);
}
}
}
} else {
$this->webValue = false;
}
if (!($this->webValue === false)) {
if ($this->pageObject->pSet->getResizeOnUpload($this->field) || $this->pageObject->pSet->getCreateThumbnail($this->field)) {
$contents = GetUploadedFileContents("value_" . $this->goodFieldName . "_" . $this->id);
}
if ($this->webValue && $this->pageObject->pSet->getCreateThumbnail($this->field)) {
$ext = CheckImageExtension(GetUploadedFileName("value_" . $this->goodFieldName . "_" . $this->id));
$thumb = CreateThumbnail($contents, $this->pageObject->pSet->getThumbnailSize($this->field), $ext);
$this->pageObject->filesToSave[] = new SaveFile($thumb, $this->pageObject->pSet->GetStrThumbnail($this->goodFieldName) . $this->webValue, $this->pageObject->pSet->getUploadFolder($this->field), $this->pageObject->pSet->isAbsolute($this->field));
}
$avalues[$this->field] = $this->webValue;
}
}
示例10: md5
$value = false;
}
if (!($value === false)) {
if (0 && "Bill Amount" == "Password" && $url_page == "admin_users_") {
$value = md5($value);
}
$avalues["Bill Amount"] = $value;
}
}
// processibng Bill Amount - end
// processing Due Date - start
$inlineAddOption = true;
if ($inlineAddOption) {
$value = postvalue("value_Due_Date_" . $id);
$type = postvalue("type_Due_Date_" . $id);
if (FieldSubmitted("Due Date_" . $id)) {
$value = prepare_for_db("Due Date", $value, $type);
} else {
$value = false;
}
if (!($value === false)) {
if (0 && "Due Date" == "Password" && $url_page == "admin_users_") {
$value = md5($value);
}
$avalues["Due Date"] = $value;
}
}
// processibng Due Date - end
$failed_inline_add = false;
// add filenames to values
foreach ($afilename_values as $akey => $value) {
示例11: readWebValue
function readWebValue(&$avalues, &$blobfields, $legacy1, $legacy2, &$filename_values)
{
$this->getPostValueAndType();
$this->formStamp = postvalue("formStamp_" . $this->goodFieldName . "_" . $this->id);
if (FieldSubmitted($this->goodFieldName . "_" . $this->id) && $this->formStamp != "") {
$filesArray = my_json_decode($this->webValue);
if (!is_array($filesArray) || count($filesArray) == 0) {
$this->webValue = "";
} else {
if (count($_SESSION["mupload_" . $this->formStamp]) > 0) {
foreach ($_SESSION["mupload_" . $this->formStamp] as $fileArray) {
$fileArray["deleted"] = true;
}
}
$result = array();
$uploadDir = $this->pageObject->pSetEdit->getLinkPrefix($this->field);
$searchStr = "";
foreach ($filesArray as $file) {
if (isset($_SESSION["mupload_" . $this->formStamp][$file["name"]])) {
$sessionFile = $_SESSION["mupload_" . $this->formStamp][$file["name"]]["file"];
$searchStr .= $file["name"] . ",!";
$result[] = array("name" => $sessionFile["name"], "usrName" => $file["name"], "size" => $sessionFile["size"], "type" => $sessionFile["type"]);
if ($this->pageObject->pSetEdit->getCreateThumbnail($this->field) && $sessionFile["thumbnail"] != "") {
$lastIndex = count($result) - 1;
$result[$lastIndex]["thumbnail"] = $sessionFile["thumbnail"];
$result[$lastIndex]["thumbnail_type"] = $sessionFile["thumbnail_type"];
$result[$lastIndex]["thumbnail_size"] = $sessionFile["thumbnail_size"];
}
$_SESSION["mupload_" . $this->formStamp][$file["name"]]["deleted"] = false;
}
}
if (count($result) > 0) {
$result[0]["searchStr"] = $searchStr . ":sStrEnd";
$this->webValue = my_json_encode_unescaped_unicode($result);
} else {
$this->webValue = "";
}
}
} else {
$this->webValue = false;
}
if (!($this->webValue === false)) {
if ($this->connection->dbType == nDATABASE_Informix) {
if (IsTextType($this->pageObject->pSetEdit->getFieldType($this->field))) {
$blobfields[] = $this->field;
}
}
$avalues[$this->field] = $this->webValue;
}
}