Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • ewalind Friend
    #137986

    I have made 2 submenues to a parent menu. My problem is that the parent menu is still clickable and linking to something. I have been reading through the mageia forum to search for a solution for this, and found a thread where i could download a Base.class.php file that should fix it. But the problem still persists. I have tried to change the type of the parent menu to “separator” but then the menu disappears from the mainmenu line. Is there another workaround?

    Anonymous Moderator
    #290645

    Please open file templatesja_mageiaja_menusBase.class.php:

    – at about line 160, find follwing code:

    [PHP]if ($tmp->type == ‘separator’)
    {
    return ‘<a href=”#” title=””><span class=”separator”>’.$image.$tmp->name.'</span></a>’;
    }[/PHP]

    and change to:

    [PHP]//if ($tmp->type == ‘separator’)
    //{
    //return ‘<a href=”#” title=””><span class=”separator”>’.$image.$tmp->name.'</span></a>’;
    //}[/PHP]

    – at about line 197, find following code:
    [PHP]
    $data = ‘<a href=”‘.$tmp->url.'” ‘.$active.’ ‘.$id.’ ‘.$title.’>’.$image.$txt.'</a>’;
    [/PHP]
    and change to:

    [PHP]
    if ($tmp->type == ‘separator’)
    {
    $data = ‘<a href=”#” ‘.$active.’ ‘.$id.’ ‘.$title.’>’.$image.$txt.'</a>’;
    } else {
    $data = ‘<a href=”‘.$tmp->url.'” ‘.$active.’ ‘.$id.’ ‘.$title.’>’.$image.$txt.'</a>’;
    }
    [/PHP]
    – You select the image, which you want to inactive to separator type.

    Hope it helps

    ewalind Friend
    #290725

    Hi developer, this did solve my problem – but its still not perfect (now how is that for a good old thank you 😉 ). No of cause i am greatfull but here is the thing:

    Now the top menu is functioning as it should, but the left menu does not show the arrow bullit as the other menus have – how to fix this? You can try and go to http://www.el-medico.dk to see what i mean. Also i just discovered that when you click on CV (the menu your fix was ment for) the topmenu becomes a few pixils lower – why is this?

    Hope that you can help me finish it perfecly – thank you so much for your time and efford in advance!

    Phill Moderator
    #290730

    Here is how I would do it.

    Return all the edited code back to its original state.

    Edit the parent menu you wish to change its type to an “external link” and set the link to #

    Take a look at http://www.windsurf.me.uk and you will see it working there.

    ewalind Friend
    #290733

    Guess i could try that – but can you tell me why the top menu shrinks a couple of px when the parent menu is pressed?

    ewalind Friend
    #290737

    Phil you wouldnt know why there is this huge gap in the menu when site is viewed in ie6? The funny thing is that this error does not exist in the template live demo.

    Phill Moderator
    #290740

    <em>@ewalind 111333 wrote:</em><blockquote>Guess i could try that – but can you tell me why the top menu shrinks a couple of px when the parent menu is pressed?</blockquote>

    It is an IE feature, try it in Chrome, Firefox, Mozilla or almost any other browser and it does not happen.

    imsleepy Friend
    #290741

    <em>@phill luckhurst 111329 wrote:</em><blockquote>Here is how I would do it.

    Return all the edited code back to its original state.

    Edit the parent menu you wish to change its type to an “external link” and set the link to #

    Take a look at http://www.windsurf.me.uk and you will see it working there.</blockquote>

    Once again…. thank you.

    I have been watching this thread because it was something I also wanted to do but couldn’t figure out how in an EASY way. Really didn’t want to edit a bunch of code. I always worry about too many edits in case a security update comes out…. then I have to try to remember everything I edited.

    Thanks again!

    Phill Moderator
    #290742

    <em>@ewalind 111337 wrote:</em><blockquote>Phil you wouldnt know why there is this huge gap in the menu when site is viewed in ie6? The funny thing is that this error does not exist in the template live demo.</blockquote>

    Sorry, do not have IE6 so I cannot check. Anyone who uses IE6 should be given a dose of Hetracil IMO ;).

    ewalind Friend
    #290840

    true true, but the sad fact is that alot of users out there (especially the target people of my mothers consultancy homepage) use ie6. And as i said the joomlart demo of mageia template does not make the gap between the header and the breadcrumb line – so someone must know a fix for this! This is what bothers me

Viewing 10 posts - 1 through 10 (of 10 total)

This topic contains 10 replies, has 4 voices, and was last updated by  ewalind 15 years, 2 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum