Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

CategoriesSimple module to add categories to the menu bar

13»

Comments

  • Options
    AaronWebsteyAaronWebstey Headband Afficionado Cole Harbour, NS ✭✭✭

    Thanks again @vrijvlinder‌ ! Sorry to waste your time on this so far.

  • Options
    peregrineperegrine MVP
    edited December 2014

    Based on this kluge

    http://cssdeck.com/labs/another-simple-css3-dropdown-menu

    this worked for me in bittersweet theme (you need to position go button with search box).

    viewing from firefox.

    add this to custom.css

    ul.presentation.drop {
      text-align: left;
      display: inline;
      margin: 0;
      padding: 15px 4px 17px 0;
      list-style: none;
      -webkit-box-shadow: 0 0 5px rgba(0, 0, 0, 0.15);
      -moz-box-shadow: 0 0 5px rgba(0, 0, 0, 0.15);
      box-shadow: 0 0 5px rgba(0, 0, 0, 0.15);
    }
    ul.presentation li {
      display: inline-block;
      margin-right:  5px;
      position: relative;
      padding: 15px 20px;
      cursor: pointer;
      -webkit-transition: all 0.2s;
      -moz-transition: all 0.2s;
      -ms-transition: all 0.2s;
      -o-transition: all 0.2s;
      transition: all 0.2s;
    }
    ul.presentation li:hover {
      background: #555;
      color: #fff;
      z-index:9999;
    }
    ul.presentation li ul {
      padding: 0;
      position: absolute;
      top: 48px;
      left: 0;
      width: 150px;
      -webkit-box-shadow: none;
      -moz-box-shadow: none;
      box-shadow: none;
      display: none;
      opacity: 0;
      visibility: hidden;
      -webkit-transiton: opacity 0.2s;
      -moz-transition: opacity 0.2s;
      -ms-transition: opacity 0.2s;
      -o-transition: opacity 0.2s;
      -transition: opacity 0.2s;
    }
    ul.presentation li ul li { 
      background: #555; 
      display: block; 
      color: #fff;
      text-shadow: 0 -1px 0 #000;
    }
    ul.presentation li ul li:hover { background: #666; }
    ul li:hover ul {
      display: block;
      opacity: 1;
      visibility: visible;
    }
    
    .mymenu {
     color:green;
    display:inline-flex;
    }
    

    default.master.tpl

     <div id="Head">
        <div class="Row">
           <span class="mymenu"> 
        <ul class="presentation">
      <li>
        Vanilla-Forum
        <ul class="presentation">
          <li><a href="http://vanillaforums.org/categories/blog">Blog</a></li>
          <li><a href="http://vanillaforums.org/categories/tutorials">Tutorials</a></li>
          <li><a href="http://vanillaforums.org/categories/vanilla-2-1">Vanilla 2.1 Help </a></li>
        </ul>   
        </ul> 
     <ul class="SiteMenu">
          {dashboard_link}
           {discussions_link}
           {activity_link}
           {inbox_link}
           {custom_menu}
           {profile_link}
           {signinout_link}
          </ul>
          <div id="Search">{searchbox}</div>
    </span>
        </div>
      </div>
      <div class="BreadcrumbsWrapper">
        <div class="Row">
         {breadcrumbs}
        </div>
      </div>
    

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options
    AaronWebsteyAaronWebstey Headband Afficionado Cole Harbour, NS ✭✭✭

    There is something seriously wrong inside your brain - that was way too fast and of course, works perfectly! I'll show you the end result once I get my module inserting all the right list items.

  • Options
    peregrineperegrine MVP
    edited December 2014

    use the existing module.

     <div id="Head">
        <div class="Row">
           <span class="mymenu"> 
        <ul class="presentation">
      <li>
        Categories
        <ul class="presentation">
         {module name="CategoriesModule"}
        </ul>   
        </ul> 
     <ul class="SiteMenu">
          {dashboard_link}
           {discussions_link}
           {activity_link}
           {inbox_link}
           {custom_menu}
           {profile_link}
           {signinout_link}
          </ul>
          <div id="Search">{searchbox}</div>
    </span>
        </div>
      </div>
      <div class="BreadcrumbsWrapper">
    
    
    
    
    
    ul.presentation .Aside {
    display:none;
    }
    
    ul.presentation h4 {
    padding-bottom:10px;
    margin:none;
    color:black;
    background:black;
    }
    

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options
    vrijvlindervrijvlinder Papillon-Sauvage MVP

    I don't understand why it has to be so complicated when something already works. In these pics I am using the categoriesdropdown and Index plugin. One works with jquery the other pure css.

    The benefit of my theme is that I wrote all the css for the dropdowns as well as other plugins that work with the theme. I don't care what you use. I simply don't want people to say they don't work when they obviously do.

  • Options
    AaronWebsteyAaronWebstey Headband Afficionado Cole Harbour, NS ✭✭✭

    @vrijvlinder‌ I'm sorry, didn't mean to trash your theme or your plugins. With the theme, I've got pretty limited time to spend and I've already got my customized one so close to how I want it. Plus, my users (particularly, the guy I'm working for) aren't going to want too drastic of a style change (like the current one or not, they've gotten used to it), and it seems like it'll be a lot faster to finish customizing what I've got. I could be wrong, but that's my take on it right now.

    As far as the categories dropdown plugin goes; yes, I probably should have spent more time trying to make it work. In fact I may give that a try tonight, as I'd rather use an established plugin if possible.

    On the upside, @peregrine‌ take a look at this: http://trstri.com/forum-dev/

    I had to fudge around with the CSS a bit to get the root links to work right (I don't use cats as headings, so the top menu bar li's are linked cats too), and as you can see it's not quite perfect - you can be inside the li element, but not hovering on the link, and the link text will turn back to grey - but it's pretty darned close. Members list, Inbox, and Dashboard links appear on the top right when logged in, which I like too.

Sign In or Register to comment.