smarteditor2 폰트추가하는 방법 부탁드립니다.

매출이 오르면 내리는 수수료! 지금 수수료센터에서 전자결제(PG)수수료 비교견적 신청해 보세요!
smarteditor2 폰트추가하는 방법 부탁드립니다.

QA

smarteditor2 폰트추가하는 방법 부탁드립니다.

답변 2

본문

smarteditor2 폰트추가하는 방법 부탁드립니다. 

 

제목 그대로 폰트를 추가하고 싶습니다.

 

일본 게시판을 만드는데 한글폰트 말고 일본폰트 Meiryo를 추가하려고 하는데 잘 안되네요.

 

검색해봐도 내용도 안나오고 우연히 파일 열어보다 smarteditor2/js/smarteditor2.js 파일 10393줄에

 

// [SMARTEDITORSUS-245] 서비스 적용 시 글꼴정보를 넘기지 않으면 기본 글꼴 목록이 보이지 않는 오류

if(!this.htOptions || !this.htOptions.aDefaultFontList || this.htOptions.aDefaultFontList.length === 0){

this.addFont("돋움,Dotum", "돋움", 0, "", "", 1, null, true);

this.addFont("돋움체,DotumChe,AppleGothic", "돋움체", 0, "", "", 1, null, true);

this.addFont("굴림,Gulim", "굴림", 0, "", "", 1, null, true);

this.addFont("굴림체,GulimChe", "굴림체", 0, "", "", 1, null, true);

this.addFont("바탕,Batang,AppleMyungjo", "바탕", 0, "", "", 1, null, true);

this.addFont("바탕체,BatangChe", "바탕체", 0, "", "", 1, null, true);

this.addFont("궁서,Gungsuh,GungSeo", "궁서", 0, "", "", 1, null, true);

this.addFont('Arial', 'Arial', 0, "", "", 1, "abcd", true);

this.addFont('Tahoma', 'Tahoma', 0, "", "", 1, "abcd", true);

this.addFont('Times New Roman', 'Times New Roman', 0, "", "", 1, "abcd", true);

this.addFont('Verdana', 'Verdana', 0, "", "", 1, "abcd", true);

this.addFont('Courier New', 'Courier New', 0, "", "", 1, "abcd", true);

this.addFont('Meiryo', 'Meiryo', 0, "", "", 1, "abcd", true);

}

 

나와서 맨 아래 Meiryo 를 추가했는데 안나오네요.

 

폰트 추가할 수 있는 방법 좀 부탁드리겠습니다.

 

감사합니다.

이 질문에 댓글 쓰기 :

답변 2

실제 js 로드는 smarteditor2.min.js 를 사용하고 있지 않나요?

지금 수정하신 코드가 smarteditor2.min.js 에서는 수정되지 않은 채 있으니 그럴 겁니다.

에디터에서 사용된 

<script type="text/javascript" src="./js/smarteditor2.min.js" charset="utf-8"></script>

이 부분이

<script type="text/javascript" src="./js/smarteditor2.js" charset="utf-8"></script>

이렇게 수정되어야 커스텀 한 JS를 사용할 수 있습니다.

 

물론 에디터 개발자는 그러지 말라고 충고하더군요.

http://forum.developers.naver.com/t/topic/4338

다른 방법을 제시하고 있으니 그걸 따르는게 최선이 아닐까요? 

답변을 작성하시기 전에 로그인 해주세요.
QA 내용 검색
질문등록
  • 질문이 없습니다.
전체 0
© SIRSOFT
현재 페이지 제일 처음으로