function ittips_BookmarkLink(title, link) { //title = "Webpage Title"; //url = "http://www.hkedcity.net/edb/teachingresources/main.php?site_key=chi"; //url = "http://www.hkedcity.net/edb/teachingresources/main.php?site_key=eng"; //url = "http://www.hkedcity.net/edb/teachingresources/main.php?site_key=maths"; //url = "http://www.hkedcity.net/edb/teachingresources/main.php?site_key=gs"; var ua=navigator.userAgent.toLowerCase(); var isKonq=(ua.indexOf('konqueror')!=-1); var isSafari=(ua.indexOf('webkit')!=-1); var isMac=(ua.indexOf('mac')!=-1); var buttonStr=isMac?'Command/Cmd':'CTRL'; if (window.sidebar) { // Mozilla Firefox Bookmark //window.sidebar.addPanel(title, link,""); alert('請按下Ctrl/Cmd + D將此網站加入書籤。'); } else if( window.external ) { // IE Favorite window.external.AddFavorite( link, title); } else if(isKonq) { alert('請按下CTRL + B將此網站加入書籤。'); } else if(window.opera) { void(0); // do nothing here (Opera 7+) } else if(window.home || isSafari) { // Firefox, Netscape, Safari, iCab alert('請按下'+buttonStr+' + D請按下'); } else if(!window.print || isMac) { // IE5/Mac and Safari 1.0 alert('請按下Command/Cmd + D請按下'); } else { alert('如要將此網站加入書籤,請使用瀏覽器的加入書籤功能。'); } }