Elxis CMS Forum

Support => General => Topic started by: armpouniotis on January 22, 2009, 22:35:37

Title: About mosMainBody()
Post by: armpouniotis on January 22, 2009, 22:35:37
Hi all !

This is what I want to do;

In my template I have set two modules to be displayed with the <?php mosMainBody(); ?> only at the main page of my site.

But... I don't want the <?php mosMainBody(); ?> to be shown at the main page. I want only the two modules to be displayed.

How can I do that ?

thank you in advance
Title: Re: About mosMainBody()
Post by: datahell on January 22, 2009, 23:27:55
If I understood well you want to display in your site's front-end just the 2 modules without any content items. To do so go to the frontpage manager and de-select everything from being displayed in front-page.

You can alternatively do a trick in your template's index.php file by writing the following:

Code: (php) [Select]
<?php 
if (($option != &#39;&#39;) && ($option != &#39;com_frontpage&#39;) && ($option != &#39;frontpage&#39;)) {
       
mosMainBody(); //Elxis main body will be loaded in every page except in Elxis&#39; front-page
}
?>

Note: I edited your posts in order to remove the php tags from your post titles.
Title: Re: About mosMainBody()
Post by: armpouniotis on January 23, 2009, 00:08:13
Thank you datahell,

you got the point !

I will try it and see if it works that way !

thank you very much !