JSFiddle - React, Tailwind, and code Playground by David Underwood August 12, 2014 HTML <textarea rows="4" cols="50" class="riTextBox"> At w3schools.com you will learn how to make a website. We offer free tutorials in all web development technologies. </textarea> <div id="richEditToolbar"></div> JavaScript var tb = $('textarea.riTextBox'); console.log('tb',tb); $('textarea.riTextBox').bind("contextmenu", function(event) { event.preventDefault(); $("<div class='custom-menu'>Custom menu</div>") .appendTo("body") .css({top: event.pageY + "px", left: event.pageX + "px"}); });