I've created an instance of a class
$smarty = new smarty();
then I create an other instance of an other class and sending the
$smarty instance to that class
$user = new user($smarty);
This is the user class
class user {
var $smarty
function user($smartyIns tance){
$smarty = $smartyInstance ;
// but when I do
$smarty->method("some parameters");
// it doesn't work
// how fix it ?
}
}
$smarty = new smarty();
then I create an other instance of an other class and sending the
$smarty instance to that class
$user = new user($smarty);
This is the user class
class user {
var $smarty
function user($smartyIns tance){
$smarty = $smartyInstance ;
// but when I do
$smarty->method("some parameters");
// it doesn't work
// how fix it ?
}
}
Comment