kindeditor视频添加默认图片

This commit is contained in:
luoquan 2016-03-11 10:21:16 +08:00
parent 7d70e63f8d
commit 62f91865e0
2 changed files with 7 additions and 2 deletions

View File

@ -931,12 +931,17 @@ function _mediaAttrs(srcTag) {
}
function _mediaEmbed(attrs,target) {
if(target && target === "media"){
var html = ["","<img src=\"../../images/video.png\" "];
var html = [[],"<img src=\"../../images/video.png\" "];
_each(attrs, function(key, val) {
if(key === "src"){
html[0] = "<a href=\"" + val + "\" target=\"_blank\">";
html[0].push("<a href=\"javascript:window.open('", val,"','newwindow',''\">");
}else{
html.push(key, "=\"" , val , "\" ");
if(key === "width"){
}else if(key === "height"){
}
}
});
html.push("/></a>");

BIN
public/images/video.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB