When to call parent constructor?

From: Date: Sat, 29 Oct 2005 14:10:50 +0000
Subject: When to call parent constructor?
Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-13128@lists.php.net to get a copy of this message
I've subclassed Smarty - should I call the parent constructor before or after setting my own options in my constructor? i.e. should I do: class My_Smarty extends Smarty {
    //Constructor
    public function __construct() {
        //Call parent constructor
        parent::Smarty();
        $this->request_use_auto_globals = true; //Don't use old-style $HTTP_*_VARS globals
    }
} or class My_Smarty extends Smarty {
    //Constructor
    public function __construct() {
        $this->request_use_auto_globals = true; //Don't use old-style $HTTP_*_VARS globals
        //Call parent constructor
        parent::Smarty();
    }
} ? Marcus -- Marcus Bointon marcus@bointon.com | http://www.bointon.com/

« previous php.smarty.general (#13128) next »