Issue
I have created a template home.php
in app/frontend/templates/home.php
I include this template if my user isn't connected. I try to include 2 partials :
<?php echo get_partial('sfGuardAuth/signin_form', array('form' => $form)) ?>
<?php echo get_partial('news/listNews', array('listNews' => $listNews)) ?>
But when I want to use variables $form
and $listNews
, I have errors :
Notice: Undefined variable: form
Notice: Undefined variable: listNews
Why ?
Solution
Using components resolves the problem
Answered By - Elorfin Answer Checked By - Mildred Charles (PHPFixing Admin)
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.