oiooj / cool-php-captcha

Automatically exported from code.google.com/p/cool-php-captcha
GNU General Public License v3.0
0 stars 0 forks source link

enhancement configuration #13

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
public function __construct() {}
/**
 * public function __construct(array $array = array()){
 *     $this->config($array);
 * }
 */

public function config(array $array = array()){
    if($array !== array()){
        foreach($array as $key => $value){
            if(property_exists(__CLASS__ , $key)){
                $this->$key = $value;
            }
        }
    }
}

Original issue reported on code.google.com by davidsie...@gmail.com on 4 Oct 2010 at 9:23

GoogleCodeExporter commented 9 years ago
Nice, but not necessary feature

Original comment by joserodr...@gmail.com on 23 Dec 2010 at 1:56