Ultimate Web Site Drop Down Menu Forum

Ultimate Web Site Drop Down Menu Forum (http://www.udm4.com/forum/index.php)
-   Troubleshooting (http://www.udm4.com/forum/forumdisplay.php?f=12)
-   -   Auto open a sub menu (http://www.udm4.com/forum/showthread.php?t=432)

08-23-2007 02:16 PM

Auto open a sub menu
 
Hi,

Is there a way that you can tell UDM to automatically open a submenu by putting something in the <ul> or <li>?

I have tried the x-snapshot module but I do not like it. Because it waits for the menu and page to load you get a short period before the menu re-opens.

As my menu list is generated from my CMS using PHP I know which sub menu should be open so if there was a way I could specify this initially that would be great.


Many thanks.

bcarl314 08-24-2007 01:46 AM

Depending on your set up, you could try the you-are-here extension on your udm menu:

http://www.udm4.com/demos/extension-youarehere.php

jorge.aragon 10-03-2007 08:33 PM

Hello,

would you please be so kind to help a new user?

How is it done with these two extensions?

I can not imagine, my programming skills are low.

Could you please post example code for this?

Best regards and many thanks for answering ;)

Jorge

bcarl314 10-03-2007 10:33 PM

Can you clarify what you're looking to do? Which two extensions?

Thanks

jorge.aragon 10-05-2007 02:58 PM

Hello,

well, simple.

I want to open a submenu triggered by the url the user is coming to.

Try: http://www.aragon.ws/udm/index-frame.php

Try: http://www.aragon.ws/udm/index-frame.php?liga=primera
In this case I want to open "International" and "Primera División"
so that you know where you are.

Thats it.

Is there a way to manage this?

Best regards, Jorge

bcarl314 10-05-2007 04:08 PM

Thanks for the link. Unfortunately, the you-are-here extension doesn't really work so well with frame based pages. Its in the implementation notes:

http://www.udm4.com/menu/modules/you...mentationNotes

One thing you might be able to do is code the php to set the display property of the right elements to "block".

Maybe try this. At the top of the menu php file, add this...

Code:

<?php
        //the open array will contain a bunch of empty elements that you need to correspond to your menu
        $open = array(
                "International"=>"",
                "Champions"=>"" //add others as needed
               
        );
        if(isset($_GET['liga'])) {
                //here we reset the style to be block based on the value of the url parameter.
                switch($_GET['liga']) {
                        case "primera":
                                $open['International'] = " style='display:block;' ";       
                                break;
                        case "champion":
                                $open['Champions'] = " style='display:block;' ";
                                break;
                }       
        }
?>

Then in your UDM <ul> <li> list make changes like this....

Code:

  <li class="onclick" <?=$open['International']?>><a class="nohref">International</a>
          <ul>

                  <li class="onclick"><a target="main_frame" href="/Ligen/SPORTAL/e_primera.php">E - Primera Divisi&oacute;n</a></li>
                  <li class="onclick"><a target="main_frame" href="/Ligen/e_segunda.php">E - Liga BBVA (Segunda Divisi&oacute;n)</a></li>
                ...
                ...
                ...
          </ul>
  </li>
  <li class="onclick" <?=$open['International']?>><a class="nohref">Champions League</a>
          <ul>

                  <li class="onclick"><a target="main_frame" href="/Ligen/CHAMPIONS/champions_a.php">Gruppe A</a></li>
                  <li class="onclick"><a target="main_frame" href="/Ligen/CHAMPIONS/champions_b.php">Gruppe B - mit Schalke 04 &amp; FC Valencia</a></li>
                ...
                ...
          </ul>
  </li>


jorge.aragon 10-05-2007 05:11 PM

Does not work.

see:

http://www.aragon.ws/udm/xphpmenue.php?liga=primera


????


Best regards, Jorge

jorge.aragon 10-17-2007 12:16 PM

Hello,

no ideas?

I am looking after the hint with the x-snapshot extension but can not imagine how to realize this.

Is there really no way? It would be quite useful for such an excellent menu system !

Best regards, Jorge

10-17-2007 03:06 PM

One option would be to request some custom development to get the menu to work on your site. Let me know if you'd be interested in that.

http://www.udm4.com/contact/quote/

jorge.aragon 10-17-2007 03:16 PM

Hello,

nice idea.... but I think this could be a general feature for many people.
As you see I was not the first one to ask this.

I will try to see how I go further...

Best regards
Jorge


All times are GMT. The time now is 07:13 AM.

Powered by vBulletin® Version 3.0.1
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.