Get ID of clicked element which opened context menu using jQuery contextMenu Plugin

Viewed 16252

I use the jQuery contextMenu from Rodney Rehm in an SVG graphic. It works fine for basic usage.

But I need to get the ID (or any other property) of the SVG-Element which triggered the context menu to use it in the context menu's item list to get dynamic item names.

I work with the Simple Context Menu demo and now want to replace these static menu items with dynamic ones depending on the ID of the SVG element which was clicked on.

3 Answers
Related