本文整理汇总了PHP中postvalue函数的典型用法代码示例。如果您正苦于以下问题:PHP postvalue函数的具体用法?PHP postvalue怎么用?PHP postvalue使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了postvalue函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: showDBValue
public function showDBValue(&$data, $keylink)
{
if ($this->container->forExport) {
return "LONG BINARY DATA - CANNOT BE DISPLAYED";
}
$value = "";
if (@$data[$this->field] != NULL && $this->container->pageType != PAGE_PRINT) {
$videoId = 'video_' . GoodFieldName(htmlspecialchars($this->field)) . '_';
$videoId .= $this->getContainer()->id . "_";
if ($this->getContainer()->pageType != PAGE_ADD) {
$videoId .= $this->getContainer()->recId;
} else {
$videoId .= postvalue("id");
}
$type = 'video/flv';
$fileName = 'file.flv';
$fileNameF = $this->getContainer()->pSet->getFilenameField($this->field);
if ($fileNameF) {
$fileName = $data[$fileNameF];
if (!$fileName) {
$fileName = 'file.flv';
} else {
$type = getContentTypeByExtension(substr($fileName, strrpos($fileName, '.')));
}
}
$href = "mfhandler.php?filename=" . $fileName . "&table=" . rawurlencode($this->getContainer()->pSet->_table) . "&field=" . rawurlencode($this->field) . "&pageType=" . $this->getContainer()->pageType . $keylink;
if (isMobileIOS()) {
$value = '<video width="' . $this->getContainer()->pSet->getVideoWidth($this->field) . '" height="' . $this->getContainer()->pSet->getVideoHeight($this->field) . '" controls="controls">
<source src="' . $href . '" type="' . $type . '" />
Your browser does not support the video tag.
</video>';
} else {
$vWidth = $this->getContainer()->pSet->getVideoWidth($this->field);
$vHeight = $this->getContainer()->pSet->getVideoHeight($this->field);
if ($vWidth == 0) {
$vWidth = 300;
}
if ($vHeight == 0) {
$vHeight = 200;
}
$value .= '
<div style="width:' . $vWidth . 'px; height:' . $vHeight . 'px;">
<video class="projekktor" width="' . $vWidth . '" height="' . $vHeight . '" id="' . $videoId . '" type="' . $type . '" src="' . $href . '" >
</video></div>';
}
if ($this->pageObject != null) {
$this->pageObject->controlsMap['video'][] = $videoId;
}
} else {
$fileNameF = $this->getContainer()->pSet->getFilenameField($this->field);
if ($fileNameF) {
$fileName = $data[$fileNameF];
if (!$fileName) {
$value = $fileName;
}
}
}
return $value;
}
开发者ID:aagusti,项目名称:padl-tng,代码行数:59,代码来源:ViewDatabaseVideoField.php
示例2: setKeys
/**
* Set keys values
*
* @param {array}
*/
function setKeys($keys = array())
{
if (count($keys)) {
$this->keys = $keys;
return;
}
$tKeys = $this->pSet->getTableKeys();
for ($i = 0; $i < count($tKeys); $i++) {
$this->keys[$tKeys[$i]] = postvalue("editid" . ($i + 1));
}
$this->setKeysForJs();
}
开发者ID:aagusti,项目名称:padl-tng,代码行数:17,代码来源:viewpage.php
示例3: showDBValue
public function showDBValue(&$data, $keylink)
{
$value = "";
if (@$data[$this->field] != NULL && $this->container->pageType != PAGE_PRINT) {
$videoId = 'video_' . GoodFieldName(runner_htmlspecialchars($this->field)) . '_';
$videoId .= $this->getContainer()->id . "_";
if ($this->getContainer()->pageType != PAGE_ADD) {
$videoId .= $this->getContainer()->recId;
} else {
$videoId .= postvalue("id");
}
$type = 'video/mp4';
$fileName = 'file.mp4';
$fileNameF = $this->getContainer()->pSet->getFilenameField($this->field);
if ($fileNameF) {
$fileName = $data[$fileNameF];
if (!$fileName) {
$fileName = 'file.mp4';
} else {
$type = getContentTypeByExtension(substr($fileName, strrpos($fileName, '.')));
}
}
$href = GetTableLink("mfhandler", "", "filename=" . $fileName . "&table=" . rawurlencode($this->getContainer()->pSet->_table) . "&field=" . rawurlencode($this->field) . "&pageType=" . $this->getContainer()->pageType . $keylink);
$vWidth = $this->getContainer()->pSet->getVideoWidth($this->field);
$vHeight = $this->getContainer()->pSet->getVideoHeight($this->field);
if ($vWidth == 0) {
$vWidth = 300;
}
if ($vHeight == 0) {
$vHeight = 200;
}
$value .= '
<div style="width:' . $vWidth . 'px; height:' . $vHeight . 'px;">
<video class="projekktor" width="' . $vWidth . '" height="' . $vHeight . '" id="' . $videoId . '" type="' . $type . '" src="' . $href . '" >
</video></div>';
if ($this->pageObject != null) {
$this->pageObject->controlsMap['video'][] = $videoId;
}
} else {
$fileNameF = $this->getContainer()->pSet->getFilenameField($this->field);
if ($fileNameF) {
$fileName = $data[$fileNameF];
if (!$fileName) {
$value = $fileName;
}
}
}
return $value;
}
开发者ID:kcallow,项目名称:MatchMe,代码行数:49,代码来源:ViewDatabaseVideoField.php
示例4: displaySearchControl
public function displaySearchControl()
{
$this->searchControlBuilder = new PanelSearchControl($this->searchControllerId, $this->tName, $this->searchClauseObj, $this);
$defaultValue = $this->pSet->getDefaultValue($this->ctrlField);
$ctrlBlockArr = $this->searchControlBuilder->buildSearchCtrlBlockArr($this->id, $this->ctrlField, 0, '', false, true, $defaultValue, '');
// build array for encode
$resArr = array();
$resArr['control1'] = trim($this->xt->call_func($ctrlBlockArr['searchcontrol']));
$resArr['control2'] = trim($this->xt->call_func($ctrlBlockArr['searchcontrol1']));
$resArr['comboHtml'] = trim($ctrlBlockArr['searchtype']);
$resArr['delButt'] = trim($ctrlBlockArr['delCtrlButt']);
$resArr['delButtId'] = trim($this->searchControlBuilder->getDelButtonId($this->ctrlField, $this->id));
$resArr['divInd'] = trim($this->id);
$resArr['fLabel'] = GetFieldLabel(GoodFieldName($this->tName), GoodFieldName($this->ctrlField));
$resArr['ctrlMap'] = $this->controlsMap['controls'];
if (postvalue('isNeedSettings') == 'true') {
$this->fillSettings();
$resArr['settings'] = $this->jsSettings;
}
// return JSON
echo printJSON($resArr);
exit;
}
开发者ID:ryanblanchard,项目名称:Dashboard,代码行数:23,代码来源:searchpage.php
示例5: postvalue
*
* Rules:
* 1) All fields are required
* 2) usernm must be unique
* 3) usernm must match usernm2
* 4) passwd must be passwd2
*
*/
case "Register":
$firstnm = postvalue("firstnm", "");
$lastnm = postvalue("lastnm", "");
$phonenbr = postvalue("phonenbr", "");
$usernm = postvalue("usernm", "");
$usernm2 = postvalue("usernm2", "");
$passwd = postvalue("passwd", "");
$passwd2 = postvalue("passwd2", "");
$errlist = "<ul style='background-color: red; padding: 8px 40px 8px 40px;'>";
$errors = 0;
/* Required field checks */
if (!$firstnm) {
$errlist .= "<li>First name is required.</li>";
$errors++;
}
if (!$lastnm) {
$errlist .= "<li>Last name is required.</li>";
$errors++;
}
if (!$phonenbr) {
$errlist .= "<li>Phone number is required.</li>";
$errors++;
}
开发者ID:atlcurling,项目名称:tkt,代码行数:31,代码来源:logic.login.php
示例6: postvalue
}
$options["masterKeysReq"][$i] = $_REQUEST["masterkey" . $i];
$i++;
}
// Create $pageObject
$pageObject = ListPage::createListPage($strTableName, $options);
// Read Search parameters from the request
if (postvalue("saveSearch") && postvalue("searchName") && !is_null($pageObject->searchLogger)) {
$searchName = postvalue("searchName");
$searchParams = $pageObject->getSearchParamsForSaving();
$pageObject->searchLogger->saveSearch($searchName, $searchParams);
$pageObject->searchClauseObj->savedSearchIsRun = true;
$_SESSION[$pageObject->sessionPrefix . '_advsearch'] = serialize($pageObject->searchClauseObj);
echo my_json_encode($searchParams);
exit;
}
// Delete the saved search
if (postvalue("deleteSearch") && postvalue("searchName") && !is_null($pageObject->searchLogger)) {
$searchName = postvalue("searchName");
$pageObject->searchLogger->deleteSearch($searchName);
exit;
}
$gQuery->ReplaceFieldsWithDummies($pageObject->getNotListBlobFieldsIndices());
if ($mode != LIST_DETAILS) {
}
unset($_SESSION["message_add"]);
unset($_SESSION["message_edit"]);
// prepare code for build page
$pageObject->prepareForBuildPage();
// show page depends of mode
$pageObject->showPage();
开发者ID:ryanblanchard,项目名称:Dashboard,代码行数:31,代码来源:Fact_SalesTransaction_list.php
示例7: array
} else {
$xt->assign("footer", false);
$xt->assign("header", false);
$xt->assign("flybody", $pageObject->body);
$xt->assign("body", true);
$xt->assign("pdflink_block", false);
$pageObject->fillSetCntrlMaps();
$returnJSON['controlsMap'] = $pageObject->controlsHTMLMap;
$returnJSON['viewControlsMap'] = $pageObject->viewControlsHTMLMap;
$returnJSON['settings'] = $pageObject->jsSettings;
}
$xt->assign("style_block", true);
$xt->assign("stylefiles_block", true);
$editlink = "";
$editkeys = array();
$editkeys["editid1"] = postvalue("editid1");
foreach ($editkeys as $key => $val) {
if ($editlink) {
$editlink .= "&";
}
$editlink .= $key . "=" . $val;
}
$xt->assign("editlink_attrs", "id=\"editLink" . $id . "\" name=\"editLink" . $id . "\" onclick=\"window.location.href='pad_pad_customer_edit.php?" . $editlink . "'\"");
$strPerm = GetUserPermissions($strTableName);
if (CheckSecurity($ownerIdValue, "Edit") && !$inlineview && strpos($strPerm, "E") !== false) {
$xt->assign("edit_button", true);
} else {
$xt->assign("edit_button", false);
}
if (!$pdf && !$all && !$inlineview) {
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
开发者ID:aagusti,项目名称:padl-tng,代码行数:31,代码来源:pad_pad_customer_view.php
示例8: my_json_encode
$pageObject->body['end'] .= "window.settings = " . my_json_encode($pageObject->jsSettings) . ";";
$pageObject->body['end'] .= '</script>';
$pageObject->body['end'] .= "<script language=\"JavaScript\" src=\"include/runnerJS/RunnerAll.js\"></script>\r\n";
$pageObject->body["end"] .= "<script>" . $pageObject->PrepareJs() . "</script>";
$xt->assignbyref("body", $pageObject->body);
$xt->display($templatefile);
exit;
} else {
if ($mode == SEARCH_LOAD_CONTROL) {
$searchControlBuilder = new PanelSearchControl($searchControllerId, $strTableName, $pageObject->searchClauseObj, $pageObject);
$ctrlField = postvalue('ctrlField');
$ctrlBlockArr = $searchControlBuilder->buildSearchCtrlBlockArr($id, $ctrlField, 0, '', false, true, '', '');
// build array for encode
$resArr = array();
$resArr['control1'] = trim($xt->call_func($ctrlBlockArr['searchcontrol']));
$resArr['control2'] = trim($xt->call_func($ctrlBlockArr['searchcontrol1']));
$resArr['comboHtml'] = trim($ctrlBlockArr['searchtype']);
$resArr['delButt'] = trim($ctrlBlockArr['delCtrlButt']);
$resArr['delButtId'] = trim($searchControlBuilder->getDelButtonId($ctrlField, $id));
$resArr['divInd'] = trim($id);
$resArr['fLabel'] = GetFieldLabel(GoodFieldName($strTableName), GoodFieldName($ctrlField));
$resArr['ctrlMap'] = $pageObject->controlsMap['controls'];
if (postvalue('isNeedSettings') == 'true') {
$pageObject->fillSettings();
$resArr['settings'] = $pageObject->jsSettings;
}
// return JSON
echo my_json_encode($resArr);
exit;
}
}
开发者ID:aagusti,项目名称:padl-tng,代码行数:31,代码来源:public_tmp_bank2_search.php
示例9: postvalue
$params["tName"] = $strTableName;
$params["action"] = postvalue("a");
$params["needSearchClauseObj"] = false;
$params["baseTableName"] = postvalue("table");
$params["afterAdd_id"] = postvalue("afteradd");
$params["masterTable"] = postvalue("mastertable");
if ($pageMode == ADD_INLINE) {
// Inline add in a 'List page with search' lookup
$params["forListPageWithSearch"] = postvalue('forLookup');
$params["screenWidth"] = postvalue("screenWidth");
$params["screenHeight"] = postvalue("screenHeight");
$params["orientation"] = postvalue("orientation");
$params["masterPageType"] = postvalue("mainMPageType");
}
if ($pageMode == ADD_ONTHEFLY || $pageMode == ADD_INLINE && (postvalue('forLookup') || postvalue("category"))) {
//table where lookup is set
$params["mainTable"] = postvalue("table");
//field with lookup is set
$params["mainField"] = postvalue("field");
//the ptype od the page where lookup is set
$params["mainPageType"] = postvalue("pageType");
//the parent control value
$params["category"] = postvalue("category");
}
if ($pageMode == ADD_DASHBOARD) {
$params["dashElementName"] = postvalue("dashelement");
$params["dashTName"] = postvalue("table");
}
$pageObject = new AddPage($params);
$pageObject->init();
$pageObject->process();
开发者ID:ryanblanchard,项目名称:Dashboard,代码行数:31,代码来源:Fact_SalesTransaction_add.php
示例10: array
// update_uid -
$viewContainer->recId = $recordsCounter;
$value = $viewContainer->showDBValue("update_uid", $data, $keylink);
$row["update_uid_value"] = $value;
// npwpd_old -
$viewContainer->recId = $recordsCounter;
$value = $viewContainer->showDBValue("npwpd_old", $data, $keylink);
$row["npwpd_old_value"] = $value;
// id_old -
$viewContainer->recId = $recordsCounter;
$value = $viewContainer->showDBValue("id_old", $data, $keylink);
$row["id_old_value"] = $value;
$rowinfo[] = $row;
$data = $cipherer->DecryptFetchedArray($rs);
}
$xt->assign_loopsection("details_row", $rowinfo);
}
$returnJSON = array("success" => true);
$xt->load_template("pad_pad_customer_detailspreview.htm");
$returnJSON["body"] = $xt->fetch_loaded();
if ($mode != "inline") {
$returnJSON["counter"] = postvalue("counter");
$layout = GetPageLayout(GoodFieldName($strTableName), 'detailspreview');
if ($layout) {
$rtl = $xt->getReadingOrder() == 'RTL' ? 'RTL' : '';
$returnJSON["style"] = "styles/" . $layout->style . "/style" . $rtl . ".css";
$returnJSON["pageStyle"] = "pagestyles/" . $layout->name . $rtl . ".css";
$returnJSON["layout"] = $layout->style . " page-" . $layout->name . ".css";
}
}
echo "<textarea>" . htmlspecialchars(my_json_encode($returnJSON)) . "</textarea>";
开发者ID:aagusti,项目名称:padl-tng,代码行数:31,代码来源:pad_pad_customer_detailspreview.php
示例11: db_insertid
}
if (count($aKeys) == 0 && searchId) {
$lastId = db_insertid($conn);
if ($lastId > 0) {
$aKeys[$keyfields[0]] = $lastId;
}
}
}
return $aKeys;
}
$id = postvalue("id") != "" ? postvalue("id") : 1;
$error_message = "";
// if is postback (form sended) and import needed
if (@$_POST["a"] == "added") {
$value = postvalue("value_ImportFileName" . $id);
$type = postvalue("type_ImportFileName" . $id);
$importfile = getImportTableName("file_ImportFileName" . $id);
//check the file extension
$pos = strrpos($value, ".");
$ext = strtoupper(substr($value, $pos));
if ($eventObj->exists('BeforeImport')) {
if ($eventObj->BeforeImport() === false) {
exit(0);
}
}
if ($ext == ".XLS" || $ext == ".XLSX") {
ImportFromExcel($importfile);
} else {
ImportFromCSV($importfile);
}
if ($eventObj->exists('AfterImport')) {
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:31,代码来源:Readings_import.php
示例12: showPage
public function showPage()
{
if ($this->eventsObject->exists("BeforeShowChart")) {
$this->eventsObject->BeforeShowChart($this->xt, $this->templatefile, $this);
}
if ($this->mode == CHART_DETAILS || $this->mode == CHART_DASHBOARD || $this->mode == CHART_DASHDETAILS) {
$this->addControlsJSAndCSS();
$this->fillSetCntrlMaps();
$this->xt->unassign("header");
$this->xt->unassign("footer");
$this->body["begin"] = "";
$this->body["end"] = "";
$this->xt->assign("body", $this->body);
$bricksExcept = array("chart");
$this->xt->hideAllBricksExcept($bricksExcept);
if ($this->show_message_block) {
$this->xt->assign("message_block", true);
}
$this->displayAJAX($this->templatefile, $this->id + 1);
exit;
}
if ($this->mode == CHART_POPUPDETAILS) {
$bricksExcept = array("grid", "pagination");
$this->xt->unassign('header');
$this->xt->unassign('footer');
$this->body["begin"] = '';
$this->body["end"] = '';
$this->xt->hideAllBricksExcept($bricksExcept);
$this->xt->prepare_template($this->templatefile);
$respArr = array();
$respArr['success'] = true;
$respArr['body'] = $this->xt->fetch_loaded("body");
$respArr['counter'] = postvalue('counter');
$this->xt->assign("container_master", false);
echo printJSON($respArr);
exit;
}
$this->display($this->templatefile);
}
开发者ID:kcallow,项目名称:MatchMe,代码行数:39,代码来源:chartpage.php
示例13: GetTableByShort
$strTableName = GetTableByShort($table);
if (!checkTableName($table)) {
exit(0);
}
require_once "include/" . $table . "_variables.php";
$searchFor = postvalue('searchFor');
// if nothing to search
if ($searchFor == '') {
echo printJSON(array('success' => true, 'result' => ''));
return;
}
$_connection = $cman->byTable($strTableName);
// array of vals
$response = array();
$searchOpt = postvalue("start") ? "Starts with" : "Contains";
$searchField = GoodFieldName(postvalue('searchField'));
$strSecuritySql = SecuritySQL("Search", $strTableName);
$numberOfSuggests = GetGlobalData("searchSuggestsNumber", 10);
$pSet = new ProjectSettings($strTableName, PAGE_SEARCH);
if ($searchField == "") {
$allSearchFields = $pSet->getGoogleLikeFields();
} else {
// array of fields which were added in wizard for search
$allSearchFields = $pSet->getAllSearchFields();
}
require_once getabspath('classes/controls/EditControlsContainer.php');
$detailKeys = array();
$masterWhere = "";
$cipherer = new RunnerCipherer($strTableName);
$controls = new EditControlsContainer(null, $pSet, PAGE_LIST, $cipherer);
if (@$_SESSION[$strTableName . "_mastertable"] != "") {
开发者ID:sdev1,项目名称:CloudStockEnquiry,代码行数:31,代码来源:searchsuggest.php
示例14: 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;
}
}
开发者ID:kcallow,项目名称:MatchMe,代码行数:50,代码来源:FileField.php
示例15: delete
public function delete()
{
$fileName = postvalue("fileName");
$success = false;
if (isset($_SESSION["mupload_" . $this->formStamp][$fileName])) {
if (!$_SESSION["mupload_" . $this->formStamp][$fileName]["fromDB"]) {
$sessionFile = $_SESSION["mupload_" . $this->formStamp][$fileName]["file"];
$file_path = $sessionFile["name"];
if (is_file($file_path)) {
$success = unlink($file_path);
}
if ($success && $sessionFile["thumbnail"] != "") {
$file = $sessionFile["thumbnail"];
if (is_file($file)) {
unlink($file);
}
}
unset($_SESSION["mupload_" . $this->formStamp][$fileName]);
} else {
$_SESSION["mupload_" . $this->formStamp][$fileName]["deleted"] = true;
$success = true;
}
}
header('Content-type: application/json');
echo my_json_encode($success);
}
开发者ID:ryanblanchard,项目名称:Dashboard,代码行数:26,代码来源:uploadhandler.php
示例16:
else
$b_includes .= '$("#add_new_query").hide();';
$b_includes .= '
NEXT_PAGE_URL = "'.GetTableLink("webreport3").'";
PREV_PAGE_URL = "'.GetTableLink("webreport").'";';
$b_includes .= '$("td[id=row1], td[id=row2]").hide();'."\r\n";
foreach ($arr_tables_custom as $tbl)
{
if(!$tbl["isStorProc"])
{
$selected="";
if ( !empty( $_SESSION['webreports']['tables'] ) )
if ( in_array( $tbl["sqlname"], $_SESSION['webreports']['tables'] ) )
$selected = "selected";
if(postvalue("sqlname")==$tbl["sqlname"])
$selected = "selected";
$b_includes .= "$('<option ".$selected."></option>').attr('value', '".jsreplace($tbl["sqlname"])."').html('".jsreplace(getCaptionTable($tbl["sqlname"]))."').appendTo($('#tables'));"."\r\n";
}
}
$b_includes .= '
}
$("li").css("list-style-type","none");
$(".selected").css("padding-bottom","0px");
if($("#tables").get(0).selectedIndex==-1)
$("#tables").get(0).selectedIndex=0;
//if(li_selected_start!=li_selected)
// $("#row5,#row6").show();
//else if(table_name==$("#tables").val())
开发者ID:helbertfurbino,项目名称:sgmofinanceiro,代码行数:31,代码来源:webreport0.php
示例17: ini_set
* styletype - stype of style change
*/
ini_set("display_errors", "1");
ini_set("display_startup_errors", "1");
include "include/dbcommon.php";
header("Expires: Thu, 01 Jan 1970 00:00:01 GMT");
include "include/reportfunctions.php";
// #9875 It's expected that webreport_style table belongs to the webreport db connection
$_connection = $cman->getForWebReports();
$xml = new xml();
if (!postvalue('str_xml')) {
echo "Error: No se han obtenido resultados. Inténtelo de nuevo.";
exit(0);
}
$arr = $xml->xml_to_array(postvalue('str_xml'));
$repname = postvalue('repname');
if ($_POST['str_xml'] == "del_all") {
$strSQL = "DELETE FROM " . $_connection->addTableWrappers("webreport_style") . " WHERE " . $_connection->addFieldWrappers("repname") . "=" . $_connection->prepareString($repname);
$_connection->exec($strSQL);
die;
}
$arrayer = array();
foreach ($arr as $key => $style_record) {
if ($style_record['type'] == "table") {
$strSQL = "DELETE FROM " . $_connection->addTableWrappers("webreport_style") . " WHERE (" . $_connection->addFieldWrappers("repname") . "=" . $_connection->prepareString($repname) . " AND " . $_connection->addFieldWrappers("styletype") . "='" . $style_record['params']['styleType'] . "')";
$_connection->exec($strSQL);
}
if ($style_record['type'] == "group") {
if ($style_record['params']['groupName'] != 0) {
$strSQL = "DELETE FROM " . $_connection->addTableWrappers("webreport_style") . " WHERE (" . $_connection->addFieldWrappers("group") . " = " . (0 + $style_record["params"]["groupName"]) . " AND " . $_connection->addFieldWrappers("repname") . "=" . $_connection->prepareString($repname) . " AND " . $_connection->addFieldWrappers("styletype") . "='" . $style_record["params"]["styleType"] . "' AND (" . $_connection->addFieldWrappers("type") . "='cell' OR " . $_connection->addFieldWrappers("type") . "='group'))";
$_connection->exec($strSQL);
开发者ID:kcallow,项目名称:MatchMe,代码行数:31,代码来源:save-style.php
示例18: array
$_connection = $cman->byTable($strTableName);
if (!$pSet->checkFieldPermissions($field)) {
$returnJSON = array("success" => false, "error" => 'Error: You have not permission for read this text');
echo printJSON($returnJSON);
return;
}
if (!$gQuery->HasGroupBy()) {
// Do not select any fields except current (full text) field.
// If query has 'group by' clause then other fields are used in it and we may not simply cut 'em off.
// Just don't do anything in that case.
$gQuery->RemoveAllFieldsExcept($pSet->getFieldIndex($field));
}
$keysArr = $pSet->getTableKeys();
$keys = array();
foreach ($keysArr as $ind => $k) {
$keys[$k] = postvalue("key" . ($ind + 1));
}
$where = KeyWhere($keys);
$sql = $gQuery->gSQLWhere($where);
$qResult = $_connection->query($sql);
if (!$qResult || !($data = $cipherer->DecryptFetchedArray($qResult->fetchAssoc()))) {
$returnJSON = array("success" => false, "error" => 'Error: Wrong SQL query');
echo printJSON($returnJSON);
return;
}
$fieldValue = $data[$field];
$sessionPrefix = $pSet->getOriginalTableName();
if ($mode == LIST_DASHBOARD) {
//set the session prefix for the dashboard list page
$sessionPrefix = "Dashboard_" . $pSet->getOriginalTableName();
}
开发者ID:sdev1,项目名称:CloudStockEnquiry,代码行数:31,代码来源:fulltext.php
示例19: postvalue
$rfooter["endrecordheader_block"] = true;
}
$record_header["data"][] = $rheader;
$record_footer["data"][] = $rfooter;
}
$xt->assignbyref("record_header", $record_header);
$xt->assignbyref("record_footer", $record_footer);
$xt->assign("grid_header", true);
$xt->assign("grid_footer", true);
if ($eventObj->exists("BeforeShowPrint")) {
$eventObj->BeforeShowPrint($xt, $pageObject->templatefile, $pageObject);
}
if (!postvalue("pdf")) {
$xt->display($pageObject->templatefile);
} else {
$xt->load_template($pageObject->templatefile);
$page = $xt->fetch_loaded();
$pagewidth = postvalue("width") * 1.05;
$pageheight = postvalue("height") * 1.05;
$landscape = false;
if ($pagewidth > $pageheight) {
$landscape = true;
if ($pagewidth / $pageheight < 297 / 210) {
$pagewidth = 297 / 210 * $pageheight;
}
} else {
if ($pagewidth / $pageheight < 210 / 297) {
$pagewidth = 210 / 297 * $pageheight;
}
}
}
开发者ID:aagusti,项目名称:padl-tng,代码行数:31,代码来源:pad_pad_daftar_hist_print.php
示例20: array
}
if ($searchByLinkField) {
$likeConditionField = $LookupType == LT_QUERY ? $linkFieldName : $f;
} else {
$likeConditionField = $LookupType == LT_QUERY ? $displayFieldName : $f;
}
$likeWheres = array();
foreach ($values as $fieldValue) {
if ($LookupType == LT_QUERY) {
$likeWheres[] = $likeField . $lookupCipherer->GetLikeClause($likeConditionField, $fieldValue);
} else {
$likeWheres[] = $likeField . $cipherer->GetLikeClause($likeConditionField, $fieldValue);
}
}
$strLookupWhere .= implode(' OR ', $likeWheres);
if ($gSettings->useCategory($f) && ($isExistParent || postvalue('editMode') != MODE_SEARCH)) {
$arLookupWhere = array();
foreach ($lookupCategory as $arLookupCategory) {
$cvalue = make_db_value($gSettings->getCategoryControl($f), $arLookupCategory);
$arLookupWhere[] = $lookupConnection->addFieldWrappers($gSettings->getCategoryFilter($f)) . "=" . $cvalue;
}
$arLookupWhereToStr = count($arLookupWhere) == 1 ? $arLookupWhere[0] : "(" . implode(" OR ", $arLookupWhere) . ")";
if (count($arLookupWhere)) {
$strLookupWhere = whereAdd($strLookupWhere, $arLookupWhereToStr);
}
}
if (strlen($lookupOrderBy)) {
$lookupOrderBy = $lookupConnection->addFieldWrappers($lookupOrderBy);
if ($gSettings->isLookupDesc($f)) {
$lookupOrderBy .= ' DESC';
}
开发者ID:kcallow,项目名称:MatchMe,代码行数:31,代码来源:lookupsuggest.php
注:本文中的postvalue函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论