Jump to content

if(MainController::$activeModule = 'Frontpage') problem


MaciejO

Recommended Posts

Hi there,

I am trying to run if(MainController::$activeModule = 'Frontpage') inside layout.tpl, it seems like its working but its really not. I am trying to present diffrent div's for a homepage and diffrent for all other modules.

Code in layout.tpl:

<?php
if(MainController::$activeModule = 'Frontpage')
{
 echo 'This is a frontpage';
}
else
{
 echo 'This is not a frontpage';
}
?>

After going to my site, I can see This is a frontpage, this is correct, I add index.php, its still correct. BUT when I do index.php/login I should get response This is not a frontpage, and what I get is This is a frontpage.

Could anyone help me on this one?

Mac... :ph34r:

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...