51 lines
2.3 KiB
Plaintext
51 lines
2.3 KiB
Plaintext
|
|
<script type="text/javascript" src="/Content/smarteditor/js/service/HuskyEZCreator.js" charset="utf-8"></script>
|
||
|
|
<script type="text/javascript">
|
||
|
|
var oEditors = [];
|
||
|
|
var currelPHID = "";
|
||
|
|
//function pushImage(fileNames, fileNewNames, fileSizes, fileTypes) {
|
||
|
|
// for (var i = 0; i < fileNames.length; i++) {
|
||
|
|
// pasteHTML("<img class='userInputImage' alt='' style='max-width:700px;' src='/Files/Temp/" + $(fileNewNames[i]).val().split(';')[1] + "'/>");
|
||
|
|
// }
|
||
|
|
//}
|
||
|
|
function pasteHTML(sHTML) {
|
||
|
|
oEditors.getById[currelPHID].exec("PASTE_HTML", [sHTML]);
|
||
|
|
}
|
||
|
|
|
||
|
|
function selectImageFile(btn) {
|
||
|
|
currelPHID = $(btn).attr("phid");
|
||
|
|
|
||
|
|
//var x = new Date();
|
||
|
|
//window.open("/Scripts/SE2.8.2/imageUpload.html?" + x.getTime(), "selectimage", "width=400 height=300");
|
||
|
|
openMainFileUpload("png,jpg,gif", "/ZAXCommon/UploadMainFile?fd=Editor", "pushImage2");
|
||
|
|
}
|
||
|
|
function pushImage2() {
|
||
|
|
if (capResult.Code == 1000) {
|
||
|
|
//pasteHTML("<img class='userInputImage' alt='' style='max-width:700px;' src='" + capResult.obj.uri + "'/>");
|
||
|
|
pasteHTML("<img class='userInputImage' alt='' src='" + capResult.Obj.uri + "'/>");
|
||
|
|
}
|
||
|
|
mainFileClose();
|
||
|
|
}
|
||
|
|
//function editorSubmit(gi) {
|
||
|
|
// gi = gi == undefined || gi == null ? 1 : gi;
|
||
|
|
// $.each($(".editorarea"), function (i, r) {
|
||
|
|
// if (gi == 2) {
|
||
|
|
// //<embed src='http://localhost:81/Files/Contents/ADELEColdShoulder.mp4' />
|
||
|
|
// var id = $(r).attr("id");
|
||
|
|
// try {
|
||
|
|
// $("#" + id).text(oEditors.getById[id].getRawContents());
|
||
|
|
// $("#" + id).val(escape(oEditors.getById[id].getRawContents()));
|
||
|
|
// } catch (e) { }
|
||
|
|
// }
|
||
|
|
// else {
|
||
|
|
// var id = $(r).attr("id");
|
||
|
|
// if (oEditors.getById[id] != undefined) {
|
||
|
|
// oEditors.getById[id].exec("UPDATE_CONTENTS_FIELD", []); // 에디터의 내용이 textarea에 적용됩니다.
|
||
|
|
// try {
|
||
|
|
// $("#" + id).text($("#" + id).val());
|
||
|
|
// $("#" + id).val(escape($("#" + id).val()));
|
||
|
|
// } catch (e) { }
|
||
|
|
// }
|
||
|
|
// }
|
||
|
|
// });
|
||
|
|
//}
|
||
|
|
</script>
|