Changeset 468 for trunk/lib/PEdit.inc.php
- Timestamp:
- Feb 20, 2014 3:03:59 AM (10 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
-
Property
svn:mergeinfo
set to
/branches/eli_branch merged eligible
-
Property
svn:mergeinfo
set to
-
trunk/lib/PEdit.inc.php
r441 r468 70 70 71 71 // PEdit object parameters. 72 var$_params = array(72 private $_params = array( 73 73 'data_dir' => '', 74 74 'character_set' => 'utf-8', … … 77 77 ); 78 78 79 var$_data = array(); // Array to store loaded data.80 var$_data_file = ''; // Full file path to the pedit data file.81 var$_authorized = false; // User is authenticated to see extended functions.82 var$_data_loaded = false;83 var$op = '';79 private $_data = array(); // Array to store loaded data. 80 private $_data_file = ''; // Full file path to the pedit data file. 81 private $_authorized = false; // User is authenticated to see extended functions. 82 private $_data_loaded = false; 83 public $op = ''; 84 84 85 85 /** … … 93 93 * @param optional array $params A hash containing connection parameters. 94 94 */ 95 function PEdit($params)95 public function __construct($params) 96 96 { 97 97 $this->setParam($params); … … 121 121 * @param array $params Array of parameters (key => val pairs). 122 122 */ 123 function setParam($params)123 public function setParam($params) 124 124 { 125 125 $app =& App::getInstance(); … … 140 140 * @return mixed Configured parameter value. 141 141 */ 142 function getParam($param)142 public function getParam($param) 143 143 { 144 144 $app =& App::getInstance(); … … 159 159 * @since 12 Apr 2006 12:43:47 160 160 */ 161 function start($initialize_data_file=false)161 public function start($initialize_data_file=false) 162 162 { 163 163 $app =& App::getInstance(); … … 217 217 * @param array $options Additional options to store with this data. 218 218 */ 219 function set($name, $options=array())219 public function set($name, $options=array()) 220 220 { 221 221 $app =& App::getInstance(); … … 236 236 * @return string The trimmed content of the named data. 237 237 */ 238 function get($name)238 public function get($name) 239 239 { 240 240 $name = preg_replace('/\s/', '_', $name); … … 251 251 * @return bool False if unauthorized or current page is a version. 252 252 */ 253 function formBegin()253 public function formBegin() 254 254 { 255 255 $app =& App::getInstance(); … … 288 288 * @access public 289 289 */ 290 function printAllForms()290 public function printAllForms() 291 291 { 292 292 if ($this->_authorized && $this->op == 'Edit' && is_array($this->_data) && $this->_data_loaded) { … … 305 305 * @param string $type Type of form to print. Currently only 'text' and 'textarea' supported. 306 306 */ 307 function printForm($name, $type='text')307 public function printForm($name, $type='text') 308 308 { 309 309 if ($this->_authorized && $this->op == 'Edit' && $this->_data_loaded) { … … 345 345 * @return bool False if unauthorized or current page is a version. 346 346 */ 347 function formEnd()347 public function formEnd() 348 348 { 349 349 if (!$this->_authorized || empty($this->_data)) { … … 399 399 * @access public 400 400 */ 401 function printVersions()401 public function printVersions() 402 402 { 403 403 $app =& App::getInstance(); … … 442 442 * @since 12 Apr 2006 10:52:35 443 443 */ 444 function _fileHash()444 private function _fileHash() 445 445 { 446 446 $app =& App::getInstance(); … … 457 457 * @since 11 Apr 2006 20:36:26 458 458 */ 459 function _loadDataFile()459 private function _loadDataFile() 460 460 { 461 461 $app =& App::getInstance(); … … 496 496 * @since 11 Apr 2006 20:53:42 497 497 */ 498 function _initializeDataFile()498 private function _initializeDataFile() 499 499 { 500 500 $app =& App::getInstance(); … … 512 512 * @return bool False if unauthorized or on failure. True on success. 513 513 */ 514 function _writeData()514 private function _writeData() 515 515 { 516 516 $app =& App::getInstance(); … … 560 560 * @since 11 Apr 2006 22:48:30 561 561 */ 562 function _filePutContents($filename, $content)562 private function _filePutContents($filename, $content) 563 563 { 564 564 $app =& App::getInstance(); … … 610 610 * @return bool False on failure. True on success. 611 611 */ 612 function _createVersion()612 private function _createVersion() 613 613 { 614 614 $app =& App::getInstance(); … … 648 648 * @since 12 Apr 2006 11:08:11 649 649 */ 650 function _deleteOldVersions()650 private function _deleteOldVersions() 651 651 { 652 652 $app =& App::getInstance(); … … 676 676 * @return array Array of versions. 677 677 */ 678 function _getVersions()678 private function _getVersions() 679 679 { 680 680 $version_files = array(); … … 707 707 * @return bool False on failure. True on success. 708 708 */ 709 function _restoreVersion($version)709 private function _restoreVersion($version) 710 710 { 711 711 $app =& App::getInstance(); … … 742 742 743 743 } // End class. 744 745 ?>
Note: See TracChangeset
for help on using the changeset viewer.