Return to Snippet

Revision: 39745
at January 20, 2011 08:07 by shinokada


Initial Code
// methods defined here
public function getProductType()
{
return $this->_type;
}
public function setProductType($type)
{
$this->_type = $type;
}

Initial URL

                                

Initial Description
To access a protected or private property, you need to create getter and setter
methods inside the class file.

Initial Title
getter and setter for private and protected property

Initial Tags
php

Initial Language
PHP