News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

joomla template modification

Started by ormuz, January 02, 2006, 01:23:20 PM

Previous topic - Next topic

ormuz

How to make my left table collapsable?

I have the 'menu' and 'left' module positions there

part of my index.php:

Quote<div class="center" align="center">
  <table class="minimal" width="910" id="main">
    <tr>
      <td width="18" class="left_shadow"><img src="<?php echo $mosConfig_live_site;?>/templates/xxxxx/images/spacer.png" alt="spacer.png, 0 kB" title="spacer" class="" height="1" width="18" /><br /></td>
      <td width="834" class="wrapper">
   
         <div id="topnav">
            <div id="topnav_links">
               <?php mosLoadModules ( 'user3', -1 ); ?>
            </div>
         </div>
        <div id="header">&nbsp;</div>
        <div class="clr"></div>
        <div>
           <div id="spacerbar">
             <?php mosPathWay(); ?>
           </div>
           <table class="maintable" width="100%">
              <tr valign="top">
                 <td class="sidenav">
                    <div id="menu">
                       <?php mosLoadModules ( 'menu' ); ?>   
                    </div>
                    <div id="left">
                       <?php mosLoadModules ( 'left' ); ?>   
                    </div>
                    <img src="<?php echo $mosConfig_live_site;?>/templates/xxxxx/images/spacer.png" alt="spacer.png, 0 kB" title="spacer" class="" height="1" width="163" /><br />
                 </td>
                 <td class="greyline">
                    <img src="<?php echo $mosConfig_live_site;?>/templates/xxxxx/images/spacer.png" alt="spacer.png, 0 kB" title="spacer" class="" height="50" width="1" /><br />
                 </td>
                 <td class="middle">
                   <?php if (mosCountModules( 'top' ) > 0) { ?>
                   <div id="newsflash">
                       <?php mosLoadModules ( 'top', -1 ); ?>
                   </div>
                    <?php } ?>
                    <div id="mainpage">
                       <?php mosLoadModules ('banner', -1); ?>
                       <?php mosMainBody(); ?>
                       <?php mosLoadModules ('user5'); ?>
                        <?php mosLoadModules ('user6',-2); ?>
</div>
                 </td>
                 <?php if (mosCountModules( 'right') > 0) { ?>
                 <td class="greyline">
                    <img src="<?php echo $mosConfig_live_site;?>/templates/xxxxx/images/spacer.png" alt="spacer.png, 0 kB" title="spacer" class="" height="50" width="1" /><br />
                 </td>
                 <td class="sidenav">
                    <div id="right">
                       <?php mosLoadModules ( 'right' ); ?>
                    </div>

sorry my enlish!

chadness

Do you want it to be so that the user can collapse it, or so that it will collapse if no modules are present?

ormuz

2º choise, collapse if no modules are present.

like in this topic -> http://www.simplemachines.org/community/index.php?topic=39380.0

and like my right sidenav:
<?php if (mosCountModules'right') > 0) { ?>

Kindred

well, if you alreayd have the code, why don't you just apply it?


<?php if ((mosCountModules'left' ) > 0) || (mosCountModules'menu' ) > 0)) { ?>

just above the

<td class="sidenav">

and then close it using <?php } ?> after the </td>
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

ormuz

#4
if you don't know nothing of php, that can be very hard...  ::) let me try!

SOLVED

thnk u guys... this was the only forum who help me with this small problem!

U can block it!

Advertisement: