'<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" class=\"div2\">\n' +
'<tr>\n' +
'<td bgcolor=\"' + menubarcolor+ '\" width=\"50\" valign=\"bottom\" align=\"center\" bgcolor=\"buttonface\">\n' +
'<\/td>\n'+
'<td bgcolor=\"buttonface\">\n'+
'<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\">';
var menubottom = '<\/table><\/td><\/tr><\/table><\/div>';
document.write(menutop+menustr+menubottom);
//prompt('aa',menutop+menustr+menubottom)
document.body.oncontextmenu=new function('return popupmouserightbuttonupmenu();');
document.body.onclick=new function('if(event.srcelement.tagname !=\'input\') mousemenu.style.visibility=\'hidden\'');
document.body.onscroll=new function('mousemenu.style.visibility=\'hidden\';');
document.body.onselectstart=new function('mousemenu.style.visibility=\'hidden\';');
window.onresizestart=new function('mousemenu.style.visibility=\'hidden\';');
}
var ns4 = (document.layers);
var ie4 = (document.all);
var win = window;
var n = 0;
function findinpage(str) {
var txt, i, found;
if (str == '')
return false;
if (ns4) {
if (!win.find(str))
while(win.find(str, false, true))
n++;
else
n++;
if (n == 0)
alert('文档搜索完毕。');
}
if (ie4) {
txt = win.document.body.createtextrange();
for (i = 0; i <= n && (found = txt.findtext(str)) != false; i++) {
txt.movestart('character', 1);
txt.moveend('textedit');
}
if (found) {
txt.movestart('character', -1);
txt.findtext(str);
txt.select();
txt.scrollintoview();
n++;
}
else {
if (n > 0) {
n = 0;
findinpage(str);
}
else
alert('文档搜索完毕。');
}
}
return false;
}
</script>
</head>
<body>
自定义鼠标右键弹出式菜单
<script language="javascript">
<!--
var menubarcolor ='#6600ff';
drawmouserightbuttonupmenu();
//-->
</script>
</body>