Welcome Guest Search | Active Topics | Sign In | Register

Menu Item's Parent Item Options
Ray Bradley
Posted: Friday, May 23, 2008 8:48:09 AM
Rank: Member
Groups: Member

Joined: 10/31/2007
Posts: 18
I would think there would be a node.getParentItemText property? But I can't find one...

ABC Company
---- Location1
---- Location2
---- Location3

If the user clicks on Location3... I want THAT text "Location3"
... and also the parent's item text... "ABC Company"?

I've tried using the
var node = info.getItem();
var nodeGroup = info.getItemGroup();
node.getPath()
node.getText() (Gets me the item's text/value... )

No help...



eo_support
Posted: Friday, May 23, 2008 10:24:37 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi Ray,

You would do something like this:

Code: JavaScript
var node = info.getItem();
var parentGroup = node.getParentGroup();
var parentItem = parentGroup.getParentItem();
var parentItemText = parentItem.getText();

Thanks


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.