Thanks for your reply Ant but I resolve the problem using $sf_context var from
the view layout.php. Now the code is:
$moduleName = $sf_context->getModuleName();
if (isset($moduleName)) {
switch ($moduleName) {
case "geslicsoft":
include_partial('LicenciasAdminMenu');
break;
case "gesrecursos":
include_partial('LevantamientoAdminMenu');
break;
case "gesdessoft":
include_partial('SoftwareAdminMenu');
break;
case "gesmantenimiento":
include_partial('MantenimientoAdminMenu');
break;
}
} else {
include_partial('MainMenu');
}
Now it works perfectly and I don't have anymore the preExecute function in my
class.
Cheers and thanks for all
Ing. Reynier Pérez Mira
Grupo de Soporte al Desarrollo - Dirección Técnica IP
> i think it has to do with assignment in pre execute. I beleive i had
> trouble with this before as well. For some reason i dont think
> assignment for the template works in preExecute. I think it only works
> for assignment within the actions, not within the template. I think
> this has to do with how preExecute is called and use of __set to
> magically assing the template variable form within an execution
> method. Of course i could be completely wrong.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---