Moodle 2.2 - Custom Menu - FAQ

Moodle 2.2 - Custom Menu - FAQ

Mary Evans發表於
Number of replies: 18

Here's a link to the answers of the most FAQ about the Custom Menu

CLICK HERE

評比平均分數: -
In reply to Mary Evans

Re: Moodle 2.2 - Custom Menu - FAQ

Dr. Indira Koneru發表於

Hi Mary,

I wish to have bold text for the top level menu items. How can I do that?

Indira

In reply to Dr. Indira Koneru

Re: Moodle 2.2 - Custom Menu - FAQ

Richard Oelmann發表於
Core developers的相片 Plugin developers的相片 Testers的相片

Indira,

That would involve changing the css for the custommenu, and the specifics of that will vary slighlty with what theme you are using.

I would suggest using firebug for firefox (or a similar tool in another browser) to identify the rule needed - alternatively the CSS tool plugin by Sam the Martin has posted in another thread in the forum.

Richard

In reply to Richard Oelmann

Re: Moodle 2.2 - Custom Menu - FAQ

Dr. Indira Koneru發表於

Richard,

I downloaded CSS tool plugin. But, I don't find the add-ons (themes, blocks, course formats) I FTPed in my site!

Indira

In reply to Dr. Indira Koneru

Re: Moodle 2.2 - Custom Menu - FAQ

Mary Evans發表於

Hi Indira,

When you say you can't find themes/blocks/course that you uploaded to your site with FTP.

Where are you looking?

Each item you upload should be placed in the correct folder...for example:

new themes FTPd to site should be in this directory -> moodle/themes/...

new blocks FTPd to site should be in this directory -> moodle/blocks/...

new course formats FTPd to site should be in this directory -> moodle/course/format...

I hope this helps?

Mary

In reply to Dr. Indira Koneru

Re: Moodle 2.2 - Custom Menu - FAQ

Mary Evans發表於

Hi Indira,

If you have the latest version of Afterburner theme (Moodle 2.2) which has the Custom CSS Settings page, you could try adding the following CSS into that section...and SAVE settings.

In reply to Mary Evans

Re: Moodle 2.2 - Custom Menu - FAQ

Dr. Indira Koneru發表於

Thanks Mary,

the following code worked for me:

ul.dropdown li  { font-weight: bold }

Now, I can see menu items in bold font.  

Indira

In reply to Mary Evans

Re: Moodle 2.2 - Custom Menu - FAQ

Dr. Indira Koneru發表於

Hi Mary,

Menu items open in the same window. I want my Moodle users view the items in a new window. Any tips for that!

Indira

In reply to Dr. Indira Koneru

Re: Moodle 2.2 - Custom Menu - FAQ

Mary Evans發表於

Hi Indira,

It is not possible now to do this, however it is not generally recommended to do that anyway. The way browsers work is that the choice is left to the user as they can, with a right-click, open the link in a new tab or in the same window. They can also set every link to open in a new tab or in same window.

HTH

Mary

In reply to Dr. Indira Koneru

Re: Moodle 2.2 - Custom Menu - FAQ

R. Gusmão發表於

I Mary,

I would like to know if its possible and how to do this changes in Afterburner.

I want to create a top of the page menu permantly when navigating, and fix the wrapper.

Is it possible? how can I do this.

Thanks in advance

In reply to R. Gusmão

Re: Moodle 2.2 - Custom Menu - FAQ

Mary Evans發表於

Hi,

I understand about the Menu, but what do you mean about 'fix the wrapper?' Or do you mean fix to the wrapper?

You could try this in default.php

First remove the custommenu code from its current position, which is just below the header...

<!-- END OF HEADER -->
<!-- START CUSTOMMENU AND NAVBAR -->
    <div id="navcontainer">
        <?php if ($hascustommenu) { ?>
                <div id="custommenu" class="javascript-disabled"><?php echo $custommenu; ?></div>
        <?php } ?>
    </div>

And then add it between page-wrapper and page like so...

<div id="page-wrapper">
<div id="navcontainer">
<?php if ($hascustommenu) { ?>
         <div id="custommenu" class="javascript-disabled"><?php echo $custommenu; ?></div>
<?php } ?>
</div>
<div id="page">

Cheers

Mary

In reply to Mary Evans

Re: Moodle 2.2 - Custom Menu - FAQ

Kamila Wuwer發表於

In my custom theme based on 'afterburner' am using Custom Menu. When hovering over the tabs the colour changes. I am trying to get that tab (the active tab?) to remain highlighted, indicating the current page. Any help will be greatly appreciated.

In reply to Kamila Wuwer

Re: Moodle 2.2 - Custom Menu - FAQ

Mary Evans發表於

Try copy/pasting this CSS into your Afterburner Custom CSS box

#custommenu ul.dropdown li a:active

In reply to Mary Evans

Re: Moodle 2.2 - Custom Menu - FAQ

Kamila Wuwer發表於

Thank you for your response.

Did you mean pasting into the menu.css file? Something like that?

#custommenu ul.dropdown li a:active{
 border:0;
    background-color: #fff;
    color: #036;
 }

This does not work. Unless you has something else in mind. 

In reply to Kamila Wuwer

Re: Moodle 2.2 - Custom Menu - FAQ

Mary Evans發表於

Something like that should work, but the custommenu is not an easy thing to tame!

Which part of the menu do you want to highlight exactly?  Is it the menu item in the menu bar itself? Because from memory it does change color, doesn't it?

If you could post an image displaying the part of the menu you would like to see changed then I will try to get the code you want.

Alternatively try this to see if the links change color...or do what you want them to?

ul.dropdown li:hover { background-color: red; color: white;}

ul.dropdown li:active { background-color: blue; color: white;}

ul.dropdown li:focus { background-color: green; color: white;}

You can add this to the Afterburner setting page Custom CSS box

Site Administration > Appearance > Themes >Afterburner

You will also need to enable Theme Designer Mode in...

Site Administration > Appearance > Themes > Theme settings

Let me know how you get on?

Mary

In reply to Kamila Wuwer

Re: Moodle 2.2 - Custom Menu - FAQ

Mary Evans發表於

Hi Kamila,

I was working on this last night and realised, a little bit too late, what it is you were actually asking.

To get a menu to stay active on the page it links to requires that page to have a tag in the menu which says 'selected' or something similar, and have the CSS style it.

In a normal website you would add the menu to each page, and code it accordingly. In Moodle this is not practical, so inshort it is not achivable.

I am not saying it cannot be done, as it probably can with a lot of extra coding.

Mary

In reply to Mary Evans

Re: Moodle 2.2 - Custom Menu - FAQ

Kamila Wuwer發表於

Exactly. So I am looking for a way to inform the system that at this moment a page with certain id is active and the it should trigger the 'active' class for that 'li:a or li.a' css item. The problem is that my php as well as the entire moodle structure is still limited and I am not sure how to acomplish the above.