Find out more about the “Show Off Your Avatar Campaign
RocketTheme  |  General  |  General Discussion  |  Topic: Hide left and right menu while viewing SMF « previous next »
Pages: [1] Go Down Print
Author Topic: Hide left and right menu while viewing SMF  (Read 2039 times)
Jeremy Fuller
Rocketeer
***
Offline Offline

Posts: 54


Hide left and right menu while viewing SMF
« on: July 05, 2006, 06:16:57 PM »

How do I hide the menus on the left and right while viewing SMF.

I posted at joomla hacks my problem
http://www.joomlahacks.com/component/option,com_smf/Itemid,94/topic,732.0


Someone at joomlahacks said to use the following code:


Quote
<tr class="canvas_main">
      <!-- MAIN -->
      <?php
        $_opt = "";
        if (isset($_REQUEST['option'])) $_opt = $_REQUEST['option']; ?>
      <!-- MENU -->
      <?php if ( mosCountModules("left") && $_opt != "com_smf") { ?>
      <td width="190" valign="top"><img src="<?php echo $mosConfig_live_site;?>/templates/mambohacks3/images/blank.gif" alt="" width="180" height="1" />        <?php mosLoadModules ('left', -3); ?></td>
      <?php } ?>
    </tr>


I using that code did not work with my div tags.
Is there something I can do that will work with my css code:


Quote
<?php if (mosCountModules('left')) { ?>
<div id="sidebar">
<div class="inside">

<?php mosLoadModules('left',-2);?>

</div></div>
<?php } ?>
</div>



Any ideas?
Logged
Stew Thompson
Hero Rocketteer
*****
Offline Offline

Posts: 552


WWW
Re: Hide left and right menu while viewing SMF
« Reply #1 on: July 05, 2006, 07:23:31 PM »

If you are using a newer template, all you need to do is unpublish ALL modules (ie. menus) on your SMF page.  What template are you using, by the way?
Logged

Jeremy Fuller
Rocketeer
***
Offline Offline

Posts: 54


Re: Hide left and right menu while viewing SMF
« Reply #2 on: July 05, 2006, 08:16:49 PM »

I made a template using only css.

There is a problem with what you suggested, I have a lot of sections that don't have menus.
A lot of the content that I want ads on, I don't want on the forums.

So is there a way to achieve this using php code like the guy from joomlahack suggested?
Logged
Pages: [1] Go Up Print 
RocketTheme  |  General  |  General Discussion  |  Topic: Hide left and right menu while viewing SMF « previous next »
Jump to: