|
Posted by nephish on 11/27/12 11:57
hey there, is this ok?
class MyClass
{
var $start;
var $finish;
function MyClass($start, $finish)
{
$this->start = $start;
$this->finish=$finish,
$this->sensor_array = get_sensor_array();
}
function get_sensor_array
{
so some stuff to populate $this->sensor_array;
return array($this->sensor_array);
}
}
another question i have,
why do i need to declare variables with the var if i can declare them
in the constructor without it ?
just a couple of questions.
if you have read this far, thanks for your time
sk
Navigation:
[Reply to this message]
|