불여우에서만 티스토리 자바스크립트가 안되네요 ㅠ
Posted: 2014 03 20 21:03 58
Code: Select all
var key = new Array();
key['h'] = "/";
key['l'] = "/location";
key['t'] = "/tag";
key['m'] = "/media";
key['g'] = "/guestbook";
key['w'] = "/owner/entry/post";
key['1'] = "/?page=1";
key['2'] = "/?page=2";
key['3'] = "/?page=3";
key['4'] = "/?page=4";
key['5'] = "/?page=5";
key['6'] = "/?page=6";
key['7'] = "/?page=7";
key['8'] = "/?page=8";
key['9'] = "/?page=9";
function getKey(keyStroke) {
if ((event.srcElement.tagName != 'INPUT') && (event.srcElement.tagName != 'TEXTAREA')){
isNetscape=(document.layers);
eventChooser = (isNetscape) ? keyStroke.which : event.keyCode;
which = String.fromCharCode(eventChooser).toLowerCase();
for (var i in key)
if (which == i) window.location = key[i];
}
}
document.onkeypress = getKey;
파폭에서만 안되네요. 어떻게 해야할지 아시는 분은 꼭 알려주시면 좋겠습니다..