<?php
/*
Base Class
By Sarawut Lorvijit
Created : 12/04/2009
Modified : 26/04/2009
Please send e-mail to me (hide@address.com) for your interest in this.
*/
class base{
protected $m_data = array();
function __construct($p_initial = NULL){
$this->m_data['initial'] = $p_initial;
}
function __destruct(){
unset($this->m_data['initial']);
}
protected function __set($p_name, $p_value){
//$this->m_data[$p_name] = $p_value;
}
protected function __get($p_name){
if(array_key_exists($p_name, $this->m_data)){
$result = $this->m_data[$p_name];
}else{
$result = "Invalid property";
}
return $result;
}
function retrieve(){
return $this->m_data;
}
}
?>