Creating dropdowns from scratch

Forums Forums Menus Creating dropdowns from scratch

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #60
    Anonymous
    Member

    Hi Ryan

    I need to ask you a question, I would like to know IF it is possible to make the dropdown menues from “scratchâ€

    #2242

    Yep, it’s definitely possible. In fact it’s not particularly difficult either. Below is an example of the code used to generate a menu with Tomato, Capsicum and Cucumber on the top level and Red, Green and Black options under the Tomato dropdown. You can add as many levels of navigation as you want, just make sure you follow the syntax for placing unordered lists (UL) inside the list item (LI) you want the dropdown/flyout to appear inside.

    [code:vfytpo3n]<ul id="suckerfishnav">
    <li><a href="">Tomato</a>
    <ul>
    <li><a href="">Red</a></li>
    <li><a href="">Green</a></li>
    <li><a href="">Black</a></li>
    </ul>
    </li>
    <li><a href="">Capsicum</a></li>
    <li><a href="">Cucumber</a></li>
    </ul>[/code:vfytpo3n]

    If you need any more help, just leave another comment and I’ll see what I can do.

    #2243
    Anonymous
    Member

    Hi Ryan

    Thanks for taking your time to write back. Your reply have helped me allot, It took a second to understand where to put the link to the page from that code but now Im “on my way thereâ€

    #2244

    I like the look of your site so far. Perhaps you should try my new beta plugin though so that you can modify it easily to match your site.

    The beta plugin is available here … https://ryan.hellyer.kiwi/2008/02/20/sucke … n-11-beta/
    And you can generate the CSS for the dropdown here … https://ryan.hellyer.kiwi/dropdowns/

    #2245
    Anonymous
    Member

    Hi Ryan

    Thanks, I uploaded the new version and got it to work, but after i used the CSS page of yours it somehow changed my whole layout and even if i disable the plugin and tried your old one it is still gray all over and the font size is not as it should. Also i have noticed that in Firefox the meny looks like it should but in IE the menue is getting cut after the 3rd menu item. I dont understand why this happens, this happens even if i change theme.

    the meny i have put together looks like this incl the “top partâ€

    #2246

    There are lots of problems in the code you have there. I need to go have dinner right now, but I’ll be back in an hour or so to help.

    #2247

    Hi Daniel.

    &quot;Daniel&quot; wrote:
    even if i disable the plugin and tried your old one it is still gray all over and the font size is not as it should.

    I don’t think this is caused by the plugin.

    In the code you provided, you are using a whole bunch of code which you don’t need at all.

    The plugin automatically adds the javascript so there is no need to add those to your HTML, I’m assuming you got those from the Dropdown Generator page, but I only posted them there for those who are NOT using the plugin.

    If you are wanting to create your own custom designed menu then literally all you need is the unordered list which you have correct in your above HTML.

    If you still find the menu isn’t look correct then let me know and I’ll see what I can do.

    This has shown up an interesting problem I hadn’t thought of before. If non English language bloggers want to use the plugin, the titles of each dropdown (pages, categories, archives etc.) will be in English. Whereas I should probably be using some sort of WordPress function which will change depending on your language settings. I’ll try to fix that in a future version of the plugin.

    #2248
    &quot;Ryan&quot; wrote:
    Whereas I should probably be using some sort of WordPress function which will change depending on your language settings. I’ll try to fix that in a future version of the plugin.

    I forgot to mention that this feature is now present in the beta version[/url:2l7o6l97] of the plugin, or at least you can alter the titles to whatever you want, there is no need for language files – this seemed like a better solution anyway as some users wanted alternative English words used too.

    #2249
    delbertpeach
    Member

    From looking at other posts I gather it’s not that simple, but couldn’t custom menus be added this way as well?

    I’ve put in code similar to what you’ve shown above in my header file after the call to suckerfish in the header, but it comes out in a new, second menu bar under the original one. how to just add those links so they stay in the same orignal menu bar?

    #2250

    There is some information about custom coding your menu HTML from scratch here … https://geek.hellyer.kiwi/forum/index.php?to … 07#msg1707

    This method essentially bypasses the plugin and displays only the code you ask for. You could take a step further by disabling the plugin and adding the necessary javascript to your head section and manually adding the dropdowns CSS to your themes CSS file.

    #2251
    Anonymous
    Member

    I need some help.

    I brought your sample code (below) into my site
    and it appears fine. But since the info doesnt appear in the manage pages section of the WP backside how do I add content onto these pages ?

    <ul id="suckerfishnav">
    <li><a href="">Tomato</a>
    <ul>
    <li><a href="">Red</a></li>
    <li><a href="">Green</a></li>
    <li><a href="">Black</a></li>
    </ul>
    </li>
    <li><a href="">Capsicum</a></li>
    <li><a href="">Cucumber</a></li>
    </ul>

    #2252

    What do you mean by ‘brought your sample code in’? The code above is just a sample of the HTML used to display a menu using the CSS from the generator.

    There is a settings page in the WP Multi-level Navigation plugin for altering the content of the menu.

Viewing 12 posts - 1 through 12 (of 12 total)
  • You must be logged in to reply to this topic.