X-Git-Url: http://git.cielonegro.org/gitweb.cgi?p=Rakka.git;a=blobdiff_plain;f=js%2Fredirection.js;h=5ceff2680f4823bb6a0e59893f6a756398a62430;hp=1a0c99b0bf4aceac2dabd0e286bceb81166d4c0a;hb=87df74aaf1fc55047bac7ac234546db7547cf166;hpb=706ee842873fdceb9465cdf6a583176ab855fae2 diff --git a/js/redirection.js b/js/redirection.js index 1a0c99b..5ceff26 100644 --- a/js/redirection.js +++ b/js/redirection.js @@ -1,17 +1,8 @@ $(document).ready(function () { - var fragment; - - if ($.browser.mozilla) { - fragment = window.location.hash; // 何故か勝手に URI デコードされる - } - else { - fragment = decodeURIComponent(window.location.hash); - } - var m = fragment.match(/^#Redirect:(.*)$/); - if (m) { - var from = m[1]; + var from = Rakka.getHashedParam("Redirect"); + if (from != null) { var editButton = $.INPUT({className: "editButton", type: "button", @@ -26,4 +17,5 @@ $(document).ready(function () { $("div.title").after(box); } + }); \ No newline at end of file