📄 j.js
字号:
function addBookmark(){
var _title=document.title;
var _url=document.location.href;
if (window.sidebar) { window.sidebar.addPanel(_title, _url,""); } else if( document.all ) {window.external.AddFavorite( _url, _title);} else if( window.opera && window.print ) {return true;}}
function copySend(){
var _title=document.title;
var _url=document.location.href;
if( document.all ) {
var _text=_title+' - '+ _url;
clipboardData.setData('Text',_text);
document.getElementById("copySendBtn").innerHTML="<span style='color:red'>已经复制成功,请用 <strong>Ctrl+V</strong> 粘贴</span>";
}}
function setHomePage(){
if(document.implementation && document.implementation.createDocument)
{
// Mozilla
try {
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
}
catch (e)
{
alert("此操作被浏览器拒绝!\n请在浏览器地址栏输入“about:config”并回车\n然后将[signed.applets.codebase_principal_support]设置为'true'");
return;
}
var prefs = Components.classes['@mozilla.org/preferences-service;1'].getService(Components.interfaces.nsIPrefBranch);
prefs.setCharPref('browser.startup.homepage', Application.SiteUrl);
}else{
// IE
document.body.style.behavior="url(#default#homepage)";
document.body.setHomePage(document.location.href);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -