From d48209cb2b56bc216c30518782f84d71e0e91cc8 Mon Sep 17 00:00:00 2001 From: otsune Date: Sun, 5 Jul 2009 12:13:14 +0000 Subject: Change entrypage URL (via http://hatena.g.hatena.ne.jp/hatenabookmark/20090703/1246609167 ) git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@34300 d0d07461-0603-4401-acd4-de1884942a52 --- direct_bookmark.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/direct_bookmark.js b/direct_bookmark.js index 7dde497..dbec3f4 100644 --- a/direct_bookmark.js +++ b/direct_bookmark.js @@ -349,7 +349,7 @@ for Migemo search: require XUL/Migemo Extension description:'Hatena bookmark', account:['https://www.hatena.ne.jp', 'https://www.hatena.ne.jp', null], loginPrompt:{ user:'', password:'', description:'Enter username and password.' }, - entryPage:'http://b.hatena.ne.jp/entry/%URL%', + entryPage:'http://b.hatena.ne.jp/entry/%URL::HATENA%', poster:function(user,password,url,title,comment,tags){ var tagString = tags.length > 0 ? '[' + tags.join('][') + ']' : ""; var request = @@ -596,8 +596,9 @@ for Migemo search: require XUL/Migemo Extension return; } liberator.open(currentService.entryPage - .replace(/%URL(?:::(ESC|MD5))?%/g, function(x, t){ + .replace(/%URL(?:::(HATENA|ESC|MD5))?%/g, function(x, t){ if(!t) return liberator.modules.buffer.URL.replace(/#/, '%23'); + if(t == "HATENA") return liberator.modules.buffer.URL.replace(/^http:\/\//, '').replace(/^https:\/\//, 's/').replace(/#/, '%23'); if(t == "ESC") return encodeURIComponent(liberator.modules.buffer.URL); if(t == "MD5"){ var url = liberator.modules.buffer.URL; -- cgit v1.2.3