NetTalk Central

NetTalk Web Server => Web Server - Ask For Help => Topic started by: olu on November 12, 2012, 02:04:21 AM

Title: sidebar menus
Post by: olu on November 12, 2012, 02:04:21 AM
Hi All,
Please how do i make the menu at the sidebar panel open one at a time. so that if i have one open and click on anothter the one open before closes and the clicked one opens
Title: Re: sidebar menus
Post by: Bruce on November 12, 2012, 07:20:15 AM
use Accordion menu type, not TaskPanel.

cheers
Bruce
Title: Re: sidebar menus
Post by: olu on November 13, 2012, 04:47:55 AM
Thanks Bruce, that did the trick but just one problem the menu is expanding to a certain size in all menus, so am having menus of just one item the height is the same with one with 7items so making it look very empty. Any way to get it to resize to amount of items in each menu
Title: Re: sidebar menus
Post by: Robert Iliuta on November 13, 2012, 11:22:38 AM
Hallo Olu,

To solve your problem follow this steps:

1.) go to procedure you have the menu on embed :
"Set jQuery Accordion Menu Options"

2.) write there this code:
loc:options = Choose(loc:options='','',clip(loc:options) & ',') & 'autoHeight: false , navigation: true'

compile and see the results :o)

Regards,
Robert
Title: Re: sidebar menus
Post by: olu on November 13, 2012, 12:24:08 PM
Hi Robert you are a star that worked perfectly. Thanks.
Title: Re: sidebar menus
Post by: Robert Iliuta on November 14, 2012, 05:57:28 AM
you welcome!
Robert
Title: Re: sidebar menus
Post by: olu on November 19, 2012, 03:57:19 AM
Hi All,
Just one more quick question on this if i wanted to have it that if a menu is already open and i click on the menu again, to get it to contract all menus?
Title: Re: sidebar menus
Post by: Bruce on November 19, 2012, 05:25:22 AM
Hi Olu,

for features of the Accordion widget see here;
http://jqueryui.com/accordion/
be sure to read the API to see the options that it has.
http://api.jqueryui.com/accordion/

Robert's already showed you the way in which you can translate those options into the loc:options field.

Cheers
Bruce
Title: Re: sidebar menus
Post by: Bruce on November 19, 2012, 05:27:02 AM
I think this is the option you want;
http://api.jqueryui.com/accordion/#option-collapsible

Bruce
Title: Re: sidebar menus
Post by: markster on November 19, 2012, 03:37:19 PM
The "Collapsible" option is displayed in the API documentation, but I cannot see any API documentation to an AutoHeight parameter even though I added the code displayed earlier in this thread and it worked fine. Where did the parameter come from? Same for Navigation?...

Mark

Title: Re: sidebar menus
Post by: Bruce on November 19, 2012, 09:32:53 PM
ok, the doc I pointed to with that link was to jQueryUI version 1.9.
The one being used by NetTalk 6 is 1.8.23

The following link is for the API docs for 1.8
http://api.jqueryui.com/1.8/
for accordion specifically; (widgets / accordion)
http://api.jqueryui.com/1.8/accordion/

jQueryUI 1.9 is a fairly large update and it has refactored some of the widgets (including accordion) to make the interfaces to the various widgets more consistent.

cheers
Bruce


Title: Re: sidebar menus
Post by: markster on November 24, 2012, 09:53:54 AM
Thanks. I'll keep an eye on the jQuery version being used within NetTalk down the road.

Mark