Board Logo

styles and substituting +-
mhunter - 8/10/2005 at 09:47 PM

Hello

I have been playing around with tree menu free but believe I may need tree menu Pro for my site. Will I be able to substitute the + and - with other images and styles that will affect the link instead? In other words instead of:

+Home can I sub the image ' + ' AND the link Home so that when clicked it will expand AND link to whatever page?

Hope this makes sense. I'll also need the usual active or selected styles too - but I think thats built into the free version...although not that intuitively. Is the pro version easier to customize?

Thanks for any imput


tigra - 8/11/2005 at 09:48 PM

This can be implemented by either modifying the core code of free version or using the event handlers and API in Tigra Tree Menu PRO.


mhunter - 8/12/2005 at 08:47 PM

Can you point me in down the right path to edit the free version? I will try that first since I am not proficient with event handlers, although I do have the PRO version as well

Thanks


tigra - 8/13/2005 at 03:59 AM

You can put the +/- icon, item icon and item text in the same anchor tag and handle onclick event the way you want (open node, redirect browser etc).

Note that it take much more skills to modify the core script code than add event handlers. Additionally the handlers is documented feature and we provide support with that while with custom changes you're on your own.


mhunter - 8/15/2005 at 08:14 PM

Hello

Can you possibly forward an example of how to use the event handler in Tree PRO to accomplish this?

I have looked over the documentation but am not sure how to proceed with substituting the + and - for the link node.

Thanks for any advice


tigra - 8/15/2005 at 11:40 PM

You'll need to hook your own javascript function to onItemOpen which fired when you use +/- icon. In that function you call method select which opens the link and then return true which executes the standard handler for the event.

You can find information about events at:
http://www.softcomplex.com/products/tigra_tree_menu_pro/docs/#events

Also see the samples of events and API usage in the distribution package.


mhunter - 8/18/2005 at 03:16 PM

Ok - this is very interesting. I found a handler useage in demo 4 - thanks. I will have to figure out or find the appropriate javascript.

One question - What is the code for the +/-. I mean, what is the default. I'm assuming onItemOpen has some default code that is over ridden when explicitly defined in tree_tpl...??? Could I get some hints on how mine should look from this???

Thanks much


tigra - 8/18/2005 at 10:46 PM

By default the code toggles open/closed state of the tree item. This handler will called when you return true from your custom handler attached to onItemOpen event.


Softcomplex: http://www.softcomplex.com/
Back to forum: http://www.softcomplex.com/forum/