var pnir;
var document;
var id;
var window;
pnir = new ActiveXObject("Sleipnir.API");
id = pnir.GetDocumentID(pnir.ActiveIndex);
document = pnir.GetDocumentObject(id);
window = pnir.GetWindowObject(id);
if (document == null) {
pnir.MessageBox("Cannot create DocumentObject.");
}
else {
var url =window.location.href.replace(/\?\d\d\d\d\d\d\d\d(#.*)?$/, '');
window.location.href = '[]http://a.hatena.ne.jp/append?[]' + url;
document = null;
}
pnir = null;