<script type= "Text/javascript" >
function Norightclick (PID) {
Pid:flash ' s parentnode ID
var el = document.getElementById (PID);
if (El.addeventlistener) {
El.addeventlistener ("MouseDown", function (event) {
if (Event.button = = 2) {
Event.stoppropagation (); For Firefox
Event.preventdefault (); For Chrome
}
}, True);
} else {
El.attachevent ("onmousedown", function () {
if (Event.button = = 2) {
El.setcapture ();
}
});
El.attachevent ("OnMouseUp", function () {
El.releasecapture ();
});
El.oncontextmenu = function () {
return false;
};
}
};
Window.onload = function () {
Norightclick ("Flashid");//flashid is the ID of the parent tag of the Flash player you want to disable. Note: The ID of the Flash Player is not.
}
For example: <div id= "Flashid" >
<object id= "Flashcontent" > here is the Flash Player </object>
</div>
Disable the Flash right-click menu