svnno****@sourc*****
svnno****@sourc*****
2009年 10月 13日 (火) 23:05:34 JST
Revision: 1334 http://sourceforge.jp/projects/sie/svn/view?view=rev&revision=1334 Author: dhrname Date: 2009-10-13 23:05:34 +0900 (Tue, 13 Oct 2009) Log Message: ----------- Modified Paths: -------------- branches/05x/052/sie.js Modified: branches/05x/052/sie.js =================================================================== --- branches/05x/052/sie.js 2009-10-13 14:03:55 UTC (rev 1333) +++ branches/05x/052/sie.js 2009-10-13 14:05:34 UTC (rev 1334) @@ -73,7 +73,8 @@ da.obj = []; da.obj[i] = ary[i]; da.num = i + 1; da.content = ait.replace(/\shref=/g, " target='_top' xlink:href="); da.success = true; ca(da); } else { - ait = ait.replace(/\shref=/g, " target='_top' xlink:href="); + var base = location.href.replace(/\/[^\/]+?$/,"/"); //URIの最後尾にあるファイル名は消す。例: /n/sie.js -> /n/ + ait = ait.replace(/\shref=(['"a-z]+?):\/\//g, " target='_top' xlink:href=$1://").replace(/\shref=(.)/g, " target='_top' xlink:href=$1"+base); var s = textToSVG(ait,ary[i].getAttribute("width"),ary[i].getAttribute("height")); ary[i].parentNode.insertBefore(s,ary[i]); }