1
lucidlee
MultiMenus 1.8: can't control number of columns
  • 2006/4/21 13:18

  • lucidlee

  • Just popping in

  • Posts: 33

  • Since: 2004/10/21


I've just upgraded to 1.8 and am having trouble getting a site menu to behave as before. It now wants to wrap itself into 2 or 3 columns in the righthand block where before it would just use one. Looking into the documentation I notice that the column creation is controlled by Quote:
<{if $count >= block.columns_limit}>// Check wether the counter has reached the total number of links to display in a single column
If yes, generate a new column
but although I've searched through the various mm and config db tables as well as the block code I can"t find where Quote:
$block.columns_limit
is set.

It seems obvious that I should be able to do this by selecting the number of columns in the menu preferences but this doesn't work reliably, ie selecting 1 column results in two or three in the block and setting 4 gives me five columns. I have adjusted the block width from 80 to 190 px (inside the containing right block of 200px) but this also has no effect on the column count.

Can anyone suggest how to get the menu to behave again?

I should say that this comes as I try to resurrect the site after it went quite haywire and got worse after i did a db table repair. I've only regained a semblance of normalcy after uninstalling newbb and multimenus and reinstalling the custom theme. After installing MM1.8 I totally rebuilt the menus rather than reload from backups. And now i'm getting these anomalies.

Xoops vers: 2.0.13.2/php 4.4.0/mySQL 4.15-max/Apache 2.0/
Lee
-----------
Complexity? Its just lots of simple things connected in lots of simple ways...

2
blueteen
Re: MultiMenus 1.8: can't control number of columns
  • 2006/4/21 14:16

  • blueteen

  • Quite a regular

  • Posts: 379

  • Since: 2004/7/16


hello,
on which menu do you want to use multiple columns ?
i've tried on "vertical switch menu", without problems.
can you give us a link ?

3
lucidlee
Re: MultiMenus 1.8: can't control number of columns
  • 2006/4/25 6:47

  • lucidlee

  • Just popping in

  • Posts: 33

  • Since: 2004/10/21


I'm no longer having problems with the menu breaking up into multiple unwanted columns. Instead on another [dropdown] menu it is creating a pop of arbitrary width. The source code of the generated page has this:
<select size="1" name="multimenu03" 
onchange="Go(multimenu03.options[multimenu03.options.selectedIndex].value)">
<
option value="" selected="selected">

&
nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
option>
Why is this generated? multimenu_doplist.html has this source code
<{if $block.format == "droplist"}>
        <
form action="">
        <
select size="1" name="multimenu<{$block.mm}>" 
    
<{else}>
        <
form action="" method="post">
        <
select size="<{$block.marquee_height}>" name="multimenu<{$block.mm}>" 
    
<{/if}>
            
onchange="Go(multimenu<{$block.mm}>.options[multimenu<{$block.mm}>.options.selectedIndex].value)">
        <
option value="" selected="selected">
        
        <{
section name=spacer loop=$block.block_size}><{" "}><{/section}>
        
        option>
Although not a coder of any ability I'm guessing the loop generates  s until $block.block_size is reached but I don't see how its value is determined. Can anyone decipher this for me? And what is the solution?

Update: Solved it! the title width controls how many characters are allowd in an entry but block width controls the width of the dropdown control. Pretty obvious really as long as you ignore its placement under Animation Settings
Lee
-----------
Complexity? Its just lots of simple things connected in lots of simple ways...

4
blueteen
Re: MultiMenus 1.8: can't control number of columns
  • 2006/4/25 7:01

  • blueteen

  • Quite a regular

  • Posts: 379

  • Since: 2004/7/16


hi,
the menu width is managed in blocks options webpage.
go to multimenu's administration webpage
choose your dropdown menu block
delete the value for : width
by default, it's set to 160 (means 160 spaces)

5
blueteen
Re: MultiMenus 1.8: can't control number of columns
  • 2006/4/25 7:10

  • blueteen

  • Quite a regular

  • Posts: 379

  • Since: 2004/7/16


you have another little problem :

Quote:

Main Menu
title="">


this is solved in the last version of multiMenu (1.8.1)

8 menus

16 menus

translated in english soon
list of changes
http://www.frxoops.org/modules/news/article.php?storyid=982

you can update your multimenu_menu.html template
with :


<{
assign var=td value=-1}>
    <
table cellspacing="0" cellpadding="0">
    <
tr>
    <
td id="mainmenu" width="<{if $block.columns>1}><{math equation="x/y" x=100 y=$block.columns }><{else}>100<{/if}>%">
<{foreach 
item=imenu from=$block.contents}>
<{if 
$imenu.submenu == 0}>
    <{
assign var=td value=$td+1}>
    <{if 
$td $block.columns_limit}>
        td>
        <
td id="mainmenu" width="<{if $block.columns>1}><{math equation="x/y" x=100 y=$block.columns }><{else}>100<{/if}>%">
        <{
assign var=td value=0}>
    <{/if}>

<{if 
$td == or $top == 1}>
    <
class="menuTop" <{if $imenu.link}>href="<{$imenu.linkurl}>" <{$imenu.target}><{/if}>title="<{$imenu.alt_title}>"><{$imenu.image}><{$imenu.title}>a>
<{
assign var="top" value="0"}><{counter print=false assign=count}>
<{else}> 
    <
class="menuMain" <{if $imenu.link}>href="<{$imenu.linkurl}>" <{$imenu.target}><{/if}>title="<{$imenu.alt_title}>">
<{
$imenu.image}><{$imenu.title}>a>
<{/if}>
<{elseif 
$imenu.submenu == OR $imenu.submenu == 2}>
<{if 
$top == 1}>
    <
class="menuSubTop" <{if $imenu.link}>href="<{$imenu.linkurl}>" <{$imenu.target}><{/if}>title="<{$imenu.alt_title}>"><{$imenu.image}><{$imenu.title}>a>
<{
assign var="top" value="0"}>
<{else}>
    <
class="menuSub" <{if $imenu.link}>href="<{$imenu.linkurl}>" <{$imenu.target}><{/if}>title="<{$imenu.alt_title}>"><{$imenu.image}><{$imenu.title}>a>
<{/if}>
<{elseif 
$imenu.submenu == 3}>
    <{if 
$imenu.link}><class="menuNote" href="<{$imenu.linkurl}>" <{$imenu.target}>title="<{$imenu.alt_title}>"><{/if}><{$imenu.image}><{$imenu.title}>a>
<{
assign var="top" value="1"}>
<{elseif 
$imenu.submenu == 4}>

    <{
assign var=td value=$td+1}>
    <{if 
$td $block.columns_limit}>
        td>
        <
td id="mainmenu" width="<{if $block.columns>1}><{math equation="x/y" x=100 y=$block.columns }><{else}>100<{/if}>%">
        <{
assign var=td value=0}>
    <{/if}>

    <
h3><{$imenu.link}><{$imenu.image}><{$imenu.title}><{$imenu.a}>h3>
<{
counter print=false assign=count}>
<{
assign var="top" value="1"}>
<{/if}>

<{/foreach}>
td>
tr>
table>

Login

Who's Online

320 user(s) are online (253 user(s) are browsing Support Forums)


Members: 0


Guests: 320


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits