에디터가 비정상적입니다.

1. 정확한 제품 또는 플러그인 이름

kboard 에서 워드프레스 내장에디터가 가능하지 않습니다.

 

 

2. 상세 내용

https://imgur.com/a/mVrJcie

이미지 처럼 에디터가 뜨질 않아요..

 

 

3. 확인 가능한 상세 페이지 주소

https://www.cosmosfarm.com/demo/?mod=editor

 

4. 수정한 코드 내역 (있다면)

function에 아래코드를 추가하였으나, 노출되지 않습ㅇ니다.

tiny가 불러오질 않아요.

// jQuery까지 포함해서 필요한 모든 스크립트 강제 로딩
	function force_load_editor_with_jquery() {
		if (!is_admin() && isset($_GET['mod']) && $_GET['mod'] === 'editor') {
			// jQuery 등록 및 로딩
			wp_enqueue_script('jquery');

			// 에디터 관련 스크립트
			wp_register_script('tinymce', includes_url('js/tinymce/tinymce.min.js'), [], null, true);
			wp_enqueue_script('tinymce');

			wp_register_script('wp-editor', includes_url('js/editor.js'), ['tinymce'], null, true);
			wp_enqueue_script('wp-editor');

			wp_register_script('quicktags', includes_url('js/quicktags.js'), [], null, true);
			wp_enqueue_script('quicktags');

			// 에디터 버튼 스타일
			wp_enqueue_style('editor-buttons', includes_url('css/editor.css'));
		}
	}
	add_action('wp_enqueue_scripts', 'force_load_editor_with_jquery', 5);


	add_action('wp_footer', function () {
		if (isset($_GET['mod']) && $_GET['mod'] === 'editor') {
			$tinymce_url = includes_url('js/tinymce/tinymce.min.js');
			$editor_url = includes_url('js/editor.js');
			$quicktags_url = includes_url('js/quicktags.js');
			?>
			<!-- ✅ TinyMCE 및 에디터 스크립트 수동 삽입 -->
			<script src="<?php echo esc_url($tinymce_url); ?>"></script>
			<script src="<?php echo esc_url($editor_url); ?>"></script>
			<script src="<?php echo esc_url($quicktags_url); ?>"></script>
			<link rel="stylesheet" href="<?php echo includes_url('css/editor.css'); ?>">

			<!-- ✅ 에디터 초기화 -->
			<script>
				jQuery(function ($) {
					if (typeof tinymce !== 'undefined') {
						tinymce.init({
							selector: '#kboard_content',
							height: 400,
							plugins: 'lists link',
							toolbar: 'undo redo | bold italic underline | bullist numlist | link unlink',
							branding: false
						});
					}
				});
			</script>
			<?php
		}
	});

 

좋은 정보와 인맥을 동시에, 워드프레스 사용자 단톡방 참여하기
좋은 정보와 인맥을 동시에, 워드프레스 사용자 단톡방 참여하기
워드프레스 에러 기술지원 서비스 전문가에게 맡기세요

AI 상담