CodeCanyon

Context Menu Class

  • Has been a member for 2-3 years
  • Helped protect Envato Marketplaces against copyright violations
  • Exclusive Author
  • Sold between 1 and 100 dollars
  • Bought between 10 and 49 items
  • United States
  • Referred between 10 and 49 users
iapcsolutions says

This is sweet! Good luck with sales. Bookmarked

2 years ago
Author
sarthemaker sarthemaker replied

Thanks iapcsolutions!

2 years ago
  • Has been a member for 2-3 years
  • Exclusive Author
  • Sold between 5 000 and 10 000 dollars
  • Bought between 1 and 9 items
  • United Kingdom
  • Referred between 1 and 9 users
phpdude says

Very very cool! Wish I had a use for it right now, have bookmarked for the day that I do require it.

Best of luck with sales.

2 years ago
Author
sarthemaker sarthemaker replied

Thanks for the great comment phpdude!

2 years ago
  • Has been a member for 3-4 years
  • Bought between 1000 and 4999 items
  • Canada
  • Referred between 1 and 9 users
chrismccoy says

nice product, bookmarked to buy ;)

2 years ago
Author
sarthemaker sarthemaker replied

Thanks chrismccoy!

2 years ago
  • Has been a member for 1-2 years
  • Bought between 1 and 9 items
jabba52 says
Purchased

Hi there, I’ve purchased your script and I’m noticing that the icons were not provided in the zip file. Is there another file I have to download?

Thanks

1 year ago
Author
sarthemaker sarthemaker replied

Hi jabba52,

The icons aren’t included with the script. I didn’t make them, I downloaded them from: http://www.iconfinder.com/ to use in the demo.

1 year ago
  • Has been a member for 1-2 years
  • Bought between 1 and 9 items
jabba52 says
Purchased

Sarthemaker, if this is too technical a question for the comments section please let me know and I’ll contact via email I guess?

I’ve got everything working on my client site but I can’t seem to assign the right click ‘save’ menu choice to saving the video associated with the element I’m right-clicking on. Would you be able to share with me how it’s done? I can’t seem to interpret the help documentation for that particular need; admittedly, I’m not too advanced. :(

Thanks again

1 year ago
Author
sarthemaker sarthemaker replied

Hi jabba52,

If you could email me the code you are currently using for the context menu I can try to figure out the problem.

1 year ago
  • Has been a member for 5-6 years
  • Bought between 10 and 49 items
saracibar says
Purchased

Hi, how can I register elements by class instead of by the element’s ID? I want to use this context menu in a dynamically generated list, something like:

Category 1 Category 2 - Subcategory 21 - Subcategory 22 - Subcategory 23 - Subcategory 24 Category 4 Category 5 - Subcategory 51 - Subcategory 52 Category 6

The context menu would have the same buttons (edit and delete) and the same functions for every element (category or subcategory) in the list. Each element in the list will have an ID but I want to use the same menu for all them. How can I do this without registering every single id? Can I do this through a class instead?

Thanks!

1 year ago
Author
sarthemaker sarthemaker replied

Hi saracibar,

You can only register elements by id or a javascript element object. If you want to register them by class, you could create a function to find all elements with a certain class, here is one to do that: http://snipplr.com/view/1696/get-elements-by-class-name/ and then loop through each element and register it with the context menu.

here is an example (using the function from the url above):

var elements = getElementsByClassName("enter_your_class_here"); for(var i = 0; i < elements.length; i++) { contextMenu.register(elements[i]); }
1 year ago
  • Has been a member for 3-4 years
  • Bought between 100 and 499 items
  • Italy
dalcingarage says

Thanks for free file…
Dany

11 months ago
Author
sarthemaker sarthemaker replied

Your Welcome!

11 months ago
  • Has been a member for 2-3 years
  • Exclusive Author
  • Sold between 100 and 1 000 dollars
  • Bought between 10 and 49 items
Thecodingdude says

Excellent free file! (Best one there has been for a long time).

I actually wanted to buy this :P

Thanks, will be very useful!

11 months ago
Author
sarthemaker sarthemaker replied

Thanks Thecodingdude,

Glad you liked it. :)

11 months ago
  • Has been a member for 2-3 years
  • Exclusive Author
  • Bought between 10 and 49 items
xAdz says

Thanks for the free file!

11 months ago
Author
sarthemaker sarthemaker replied

You’re Welcome!

11 months ago
  • Has been a member for 0-1 years
  • Won a Competition
  • Attended a Community Meetup
  • Author had a Free File of the Month
  • Exclusive Author
  • Sold between 100 and 1 000 dollars
  • Bought between 1 and 9 items
  • Referred between 10 and 49 users
roodper says

Good job , easy to use :D Thanks for free file

11 months ago
Author
sarthemaker sarthemaker replied

Thanks, and You’re Welcome!

11 months ago
  • Has been a member for 0-1 years
Halco says

Hi, I’m new. How can I add this to my blog? (Blogger)

11 months ago
Author
sarthemaker sarthemaker replied

Hi Halco,

I’ve never used Blogger so I’m not sure how it works, but you will just need to include the JavaScript and CSS files however Blogger let’s you, and add some extra JavaScript for the menu items (The documentation explains how to do this).

11 months ago
  • Has been a member for 3-4 years
  • Repeatedly Helped protect Envato Marketplaces against copyright violations
  • Exclusive Author
  • Sold between 5 000 and 10 000 dollars
  • Bought between 50 and 99 items
  • India
  • Referred between 10 and 49 users
DanielPaul says

Nice… :)

11 months ago
Author
sarthemaker sarthemaker replied

Thanks!

11 months ago
  • Has been a member for 2-3 years
  • Exclusive Author
  • Sold between 1 000 and 5 000 dollars
  • Bought between 50 and 99 items
  • United Kingdom
  • Referred between 1 and 9 users
JonnySnip3r says

I am so surprised you have so little sales this is an awesome item!!

11 months ago
Author
sarthemaker sarthemaker replied

Thanks JonnySnip3r!

11 months ago
  • Has been a member for 0-1 years
  • Exclusive Author
JashDass says

really good script man. 8-)

10 months ago
Author
sarthemaker sarthemaker replied

Thank you JashDass!

10 months ago
  • Has been a member for 2-3 years
  • Exclusive Author
  • Bought between 1 and 9 items
  • Romania
refuzake says

Hello,

Is posible to add links on this ?

Good job, appreciate!

10 months ago
Author
sarthemaker sarthemaker replied

Hi refuzake,

Thanks!

You can make an item goto a url by making it’s callback function something like this:

function() { window.location = “Put URL Here”; }

10 months ago
  • Has been a member for 3-4 years
  • Exclusive Author
  • Sold between 100 and 1 000 dollars
  • Bought between 1 and 9 items
  • United Kingdom
MrChuckles says

Stunning, doesn’t work in Opera though, but no one uses that anyway.

10 months ago
Author
sarthemaker sarthemaker replied

Thank you MrChuckles! Ya, Opera doesn’t allow custom contextual menus.

10 months ago
  • Has been a member for 1-2 years
  • Exclusive Author
shaan360 says

Thank you :)

10 months ago
Author
sarthemaker sarthemaker replied

You’re welcome! :)

10 months ago
  • Has been a member for 4-5 years
rbart86 says

Hi, Would it be possible to change the right-click to a left-click (or both), so that user was forced to open this menu basically? Thanks

10 months ago
Author
sarthemaker sarthemaker replied

Hi rbart86,

Yes, to change the right click to a left click: first open ContextMenu.js, then do a find for: CM_addEvent(document, ‘contextmenu’, this.show); now change the text: ‘contextmenu’ to ‘click’.

This will make the contextmenu’s open with a left click.

To make it open with both right and left clicks, just add the line: CM_addEvent(document, ‘click’, this.show); underneath the line: CM_addEvent(document, ‘contextmenu’, this.show);

I hope that answers your question. :)

9 months ago
  • Has been a member for 0-1 years
  • Bought between 10 and 49 items
  • Russian Federation
Poxy says

Hi. Looks very neat. But can it have target=”_blank” option or open link in popup?

Yep. I got it!

window.open(“http://www.google.com”, “mywindow”, “location=1,status=1,scrollbars=1, width=100,height=100”)

2 months ago
Author
sarthemaker sarthemaker replied

Thanks Poxy! I’m Glad you figured it out.

2 months ago

by
by
by
by
by