mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-08 11:11:39 +09:00
#18532314 r7139 추가 수정, 메일 주소 링크도 주소 수정 안함.
git-svn-id: http://xe-core.googlecode.com/svn/sandbox@7142 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
97836937ad
commit
460860d2fb
1 changed files with 2 additions and 2 deletions
|
|
@ -211,10 +211,10 @@ function editorReplaceHTML(iframe_obj, content) {
|
|||
|
||||
function editorReplacePath(content) {
|
||||
// 태그 내 src, href, url의 XE 상대경로를 http로 시작하는 full path로 변경
|
||||
content = content.replace(/\<([^\>\<]*?)(src=|href=|url\()("|\')*?([^"\'\)]+)("|\'|\))*?(\s|>)*/ig, function(m0,m1,m2,m3,m4,m5,m6) {
|
||||
content = content.replace(/\<([^\>\<]*)(src=|href=|url\()("|\')*?([^"\'\)]+)("|\'|\))*(\s|>)*/ig, function(m0,m1,m2,m3,m4,m5,m6) {
|
||||
if(m2=="url(") { m3=''; m5=')'; } else { if(typeof(m3)=='undefined') m3 = '"'; if(typeof(m5)=='undefined') m5 = '"'; if(typeof(m6)=='undefined') m6 = ''; }
|
||||
var val = jQuery.trim(m4).replace(/^\.\//,'');
|
||||
if(/^(http|https|ftp|telnet|mms|\/|\.\.|\#)/i.test(val)) return m0;
|
||||
if(/^(http\:|https\:|ftp\:|telnet\:|mms\:|mailto\:|\/|\.\.|\#)/i.test(val)) return m0;
|
||||
return '<'+m1+m2+m3+request_uri+val+m5+m6;
|
||||
});
|
||||
return content;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue