// PHPMaker 5 configuration for Table ogloszenia $ogloszenia = new cogloszenia; // Initialize table object // Define table class class cogloszenia { // Define table level constants var $TableVar; var $TableName; var $SelectLimit = FALSE; var $id; var $tytul; var $data; var $skrot; var $tekst; var $zalacznik1; var $zalacznik2; var $zalacznik3; var $foto1; var $foto2; var $foto3; var $foto4; var $foto5; var $foto6; var $fields = array(); function cogloszenia() { $this->TableVar = "ogloszenia"; $this->TableName = "ogloszenia"; $this->SelectLimit = TRUE; $this->id = new cField('ogloszenia', 'x_id', 'id', "`id`", 3, -1, FALSE); $this->fields['id'] =& $this->id; $this->tytul = new cField('ogloszenia', 'x_tytul', 'tytul', "`tytul`", 200, -1, FALSE); $this->fields['tytul'] =& $this->tytul; $this->data = new cField('ogloszenia', 'x_data', 'data', "`data`", 200, -1, FALSE); $this->fields['data'] =& $this->data; $this->skrot = new cField('ogloszenia', 'x_skrot', 'skrot', "`skrot`", 201, -1, FALSE); $this->fields['skrot'] =& $this->skrot; $this->tekst = new cField('ogloszenia', 'x_tekst', 'tekst', "`tekst`", 201, -1, FALSE); $this->fields['tekst'] =& $this->tekst; $this->zalacznik1 = new cField('ogloszenia', 'x_zalacznik1', 'zalacznik1', "`zalacznik1`", 200, -1, TRUE); $this->fields['zalacznik1'] =& $this->zalacznik1; $this->zalacznik2 = new cField('ogloszenia', 'x_zalacznik2', 'zalacznik2', "`zalacznik2`", 200, -1, TRUE); $this->fields['zalacznik2'] =& $this->zalacznik2; $this->zalacznik3 = new cField('ogloszenia', 'x_zalacznik3', 'zalacznik3', "`zalacznik3`", 200, -1, TRUE); $this->fields['zalacznik3'] =& $this->zalacznik3; $this->foto1 = new cField('ogloszenia', 'x_foto1', 'foto1', "`foto1`", 200, -1, TRUE); $this->fields['foto1'] =& $this->foto1; $this->foto2 = new cField('ogloszenia', 'x_foto2', 'foto2', "`foto2`", 200, -1, TRUE); $this->fields['foto2'] =& $this->foto2; $this->foto3 = new cField('ogloszenia', 'x_foto3', 'foto3', "`foto3`", 200, -1, TRUE); $this->fields['foto3'] =& $this->foto3; $this->foto4 = new cField('ogloszenia', 'x_foto4', 'foto4', "`foto4`", 200, -1, TRUE); $this->fields['foto4'] =& $this->foto4; $this->foto5 = new cField('ogloszenia', 'x_foto5', 'foto5', "`foto5`", 200, -1, TRUE); $this->fields['foto5'] =& $this->foto5; $this->foto6 = new cField('ogloszenia', 'x_foto6', 'foto6', "`foto6`", 200, -1, TRUE); $this->fields['foto6'] =& $this->foto6; } // Records per page function getRecordsPerPage() { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_REC_PER_PAGE]; } function setRecordsPerPage($v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_REC_PER_PAGE] = $v; } // Start record number function getStartRecordNumber() { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_START_REC]; } function setStartRecordNumber($v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_START_REC] = $v; } // Advanced search function getAdvancedSearch($fld) { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_ADVANCED_SEARCH . "_" . $fld]; } function setAdvancedSearch($fld, $v) { if (@$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_ADVANCED_SEARCH . "_" . $fld] <> $v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_ADVANCED_SEARCH . "_" . $fld] = $v; } } // Basic search Keyword function getBasicSearchKeyword() { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_BASIC_SEARCH]; } function setBasicSearchKeyword($v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_BASIC_SEARCH] = $v; } // Basic Search Type function getBasicSearchType() { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_BASIC_SEARCH_TYPE]; } function setBasicSearchType($v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_BASIC_SEARCH_TYPE] = $v; } // Search where clause function getSearchWhere() { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_SEARCH_WHERE]; } function setSearchWhere($v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_SEARCH_WHERE] = $v; } // Single column sort function UpdateSort(&$ofld) { if ($this->CurrentOrder == $ofld->FldName) { $sSortField = $ofld->FldExpression; $sLastSort = $ofld->getSort(); if ($this->CurrentOrderType == "ASC" || $this->CurrentOrderType == "DESC") { $sThisSort = $this->CurrentOrderType; } else { $sThisSort = ($sLastSort == "ASC") ? "DESC" : "ASC"; } $ofld->setSort($sThisSort); $this->setSessionOrderBy($sSortField . " " . $sThisSort); // Save to Session } else { $ofld->setSort(""); } } // Session WHERE Clause function getSessionWhere() { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_WHERE]; } function setSessionWhere($v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_WHERE] = $v; } // Session ORDER BY function getSessionOrderBy() { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_ORDER_BY]; } function setSessionOrderBy($v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_ORDER_BY] = $v; } // Session Key function getKey($fld) { return @$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_KEY . "_" . $fld]; } function setKey($fld, $v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_KEY . "_" . $fld] = $v; } // Table level SQL function SqlSelect() { // Select return "SELECT * FROM `ogloszenia`"; } function SqlWhere() { // Where return ""; } function SqlGroupBy() { // Group By return ""; } function SqlHaving() { // Having return ""; } function SqlOrderBy() { // Order By return "`data` DESC"; } // SQL variables var $CurrentFilter; // Current filter var $CurrentOrder; // Current order var $CurrentOrderType; // Current order type // Report table sql function SQL() { $sFilter = $this->CurrentFilter; $sSort = $this->getSessionOrderBy(); return ew_BuildSql($this->SqlSelect(), $this->SqlWhere(), $this->SqlGroupBy(), $this->SqlHaving(), $this->SqlOrderBy(), $sFilter, $sSort); } // Return table sql with list page filter function SelectSQL() { $sFilter = $this->getSessionWhere(); if ($this->CurrentFilter <> "") { if ($sFilter <> "") $sFilter .= " AND "; $sFilter .= $this->CurrentFilter; } $sSort = $this->getSessionOrderBy(); return ew_BuildSql($this->SqlSelect(), $this->SqlWhere(), $this->SqlGroupBy(), $this->SqlHaving(), $this->SqlOrderBy(), $sFilter, $sSort); } // Return record count function SelectRecordCount() { global $conn; $cnt = -1; $sFilter = $this->CurrentFilter; $this->Recordset_Selecting($this->CurrentFilter); if ($this->SelectLimit) { $sSelect = $this->SelectSQL(); if (strtoupper(substr($sSelect, 0, 13)) == "SELECT * FROM") { $sSelect = "SELECT COUNT(*) FROM" . substr($sSelect, 13); if ($rs = $conn->Execute($sSelect)) { if (!$rs->EOF) $cnt = $rs->fields[0]; $rs->Close(); } } } if ($cnt == -1) { if ($rs = $conn->Execute($this->SelectSQL())) { $cnt = $rs->RecordCount(); $rs->Close(); } } $this->CurrentFilter = $sFilter; return intval($cnt); } // INSERT statement function InsertSQL(&$rs) { $names = ""; $values = ""; foreach ($rs as $name => $value) { $names .= $this->fields[$name]->FldExpression . ","; $values .= (is_null($value) ? "NULL" : ew_QuotedValue($value, $this->fields[$name]->FldDataType)) . ","; } if (substr($names, -1) == ",") $names = substr($names, 0, strlen($names)-1); if (substr($values, -1) == ",") $values = substr($values, 0, strlen($values)-1); return "INSERT INTO `ogloszenia` ($names) VALUES ($values)"; } // UPDATE statement function UpdateSQL(&$rs) { $SQL = "UPDATE `ogloszenia` SET "; foreach ($rs as $name => $value) { $SQL .= $this->fields[$name]->FldExpression . "=" . (is_null($value) ? "NULL" : ew_QuotedValue($value, $this->fields[$name]->FldDataType)) . ","; } if (substr($SQL, -1) == ",") $SQL = substr($SQL, 0, strlen($SQL)-1); if ($this->CurrentFilter <> "") $SQL .= " WHERE " . $this->CurrentFilter; return $SQL; } // DELETE statement function DeleteSQL(&$rs) { $SQL = "DELETE FROM `ogloszenia` WHERE "; $SQL .= EW_DB_QUOTE_START . 'id' . EW_DB_QUOTE_END . '=' . ew_QuotedValue($rs['id'], $this->id->FldDataType) . ' AND '; if (substr($SQL, -5) == " AND ") $SQL = substr($SQL, 0, strlen($SQL)-5); if ($this->CurrentFilter <> "") $SQL .= " AND " . $this->CurrentFilter; return $SQL; } // Key filter for table function SqlKeyFilter() { return "`id` = @id@"; } // Return url function getReturnUrl() { if (@$_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_RETURN_URL] <> "") { return $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_RETURN_URL]; } else { return "licytacje.php"; } } function setReturnUrl($v) { $_SESSION[EW_PROJECT_NAME . "_" . $this->TableVar . "_" . EW_TABLE_RETURN_URL] = $v; } // View url function ViewUrl() { return $this->KeyUrl("licytacja.php"); } // Key url function KeyUrl($url, $action = "") { $sUrl = $url . "?"; if ($action <> "") $sUrl .= $action . "&"; if (!is_null($this->id->CurrentValue)) { $sUrl .= "id=" . urlencode($this->id->CurrentValue); } else { return "javascript:alert('Invalid Record! Key is null');"; } return $sUrl; } // Function LoadRs // - Load Row based on Key Value function LoadRs($sFilter) { global $conn; // Set up filter (Sql Where Clause) and get Return Sql $this->CurrentFilter = $sFilter; $sSql = $this->SQL(); return $conn->Execute($sSql); } // Load row values from rs function LoadListRowValues(&$rs) { $this->id->setDbValue($rs->fields('id')); $this->tytul->setDbValue($rs->fields('tytul')); $this->data->setDbValue($rs->fields('data')); $this->skrot->setDbValue($rs->fields('skrot')); $this->tekst->setDbValue($rs->fields('tekst')); $this->zalacznik1->Upload->DbValue = $rs->fields('zalacznik1'); $this->zalacznik2->Upload->DbValue = $rs->fields('zalacznik2'); $this->zalacznik3->Upload->DbValue = $rs->fields('zalacznik3'); $this->foto1->Upload->DbValue = $rs->fields('foto1'); $this->foto2->Upload->DbValue = $rs->fields('foto2'); $this->foto3->Upload->DbValue = $rs->fields('foto3'); $this->foto4->Upload->DbValue = $rs->fields('foto4'); $this->foto5->Upload->DbValue = $rs->fields('foto5'); $this->foto6->Upload->DbValue = $rs->fields('foto6'); } // Render list row values function RenderListRow() { global $conn, $Security; // id $this->id->ViewValue = $this->id->CurrentValue; $this->id->CssStyle = ""; $this->id->CssClass = ""; $this->id->ViewCustomAttributes = ""; // tytul $this->tytul->ViewValue = $this->tytul->CurrentValue; $this->tytul->CssStyle = ""; $this->tytul->CssClass = ""; $this->tytul->ViewCustomAttributes = ""; // data $this->data->ViewValue = $this->data->CurrentValue; $this->data->CssStyle = ""; $this->data->CssClass = ""; $this->data->ViewCustomAttributes = ""; // skrot $this->skrot->ViewValue = $this->skrot->CurrentValue; $this->skrot->CssStyle = ""; $this->skrot->CssClass = ""; $this->skrot->ViewCustomAttributes = ""; // foto1 if (!is_null($this->foto1->Upload->DbValue)) { $this->foto1->ViewValue = $this->foto1->Upload->DbValue; $this->foto1->ImageAlt = ""; } else { $this->foto1->ViewValue = ""; } $this->foto1->CssStyle = ""; $this->foto1->CssClass = ""; $this->foto1->ViewCustomAttributes = ""; // id $this->id->HrefValue = ""; // tytul $this->tytul->HrefValue = ""; // data $this->data->HrefValue = ""; // skrot $this->skrot->HrefValue = ""; // foto1 $this->foto1->HrefValue = ""; } var $CurrentAction; // Current action var $EventName; // Event name var $EventCancelled; // Event cancelled var $CancelMessage; // Cancel message var $RowType; // Row Type var $CssClass; // Css class var $CssStyle; // Css style var $RowClientEvents; // Row client events // Display Attribute function DisplayAttributes() { $sAtt = ""; if (trim($this->CssStyle) <> "") { $sAtt .= " style=\"" . trim($this->CssStyle) . "\""; } if (trim($this->CssClass) <> "") { $sAtt .= " class=\"" . trim($this->CssClass) . "\""; } if ($this->Export == "") { if (trim($this->RowClientEvents) <> "") { $sAtt .= " " . $this->RowClientEvents; } } return $sAtt; } // Export var $Export; // ---------------- // Field objects // ---------------- function fields($fldname) { return $this->fields[$fldname]; } // Table level events // Recordset Selecting event function Recordset_Selecting(&$filter) { // Enter your code here } // Recordset Selected event function Recordset_Selected(&$rs) { //echo "Recordset Selected"; } // Row_Selecting event function Row_Selecting(&$filter) { // Enter your code here } // Row Selected event function Row_Selected(&$rs) { //echo "Row Selected"; } // Row Rendering event function Row_Rendering() { // Enter your code here } // Row Rendered event function Row_Rendered() { // To view properties of field class, use: //var_dump($this->); } // Row Inserting event function Row_Inserting(&$rs) { // Enter your code here // To cancel, set return value to False return TRUE; } // Row Inserted event function Row_Inserted(&$rs) { //echo "Row Inserted"; } // Row Updating event function Row_Updating(&$rsold, &$rsnew) { // Enter your code here // To cancel, set return value to False return TRUE; } // Row Updated event function Row_Updated(&$rsold, &$rsnew) { //echo "Row Updated"; } // Row Deleting event function Row_Deleting($rs) { // Enter your code here // To cancel, set return value to False return TRUE; } // Row Deleted event function Row_Deleted(&$rs) { //echo "Row Deleted"; } } ?>
Fatal error: Call to undefined function Page_Load() in /home/aigel/ftp/komornik-koszalin.pl/ogloszenia.php on line 34