에 DocumentBaseUrl을 변경할 수 없습니다 TinyMCE에로드 생산에, 나는 네 404 얻을 때 : 어쩌면이 파일 tiny_mce.js에서 비동기 적으로 호출된다내가 레일 3.2.3를 사용하고, 그리고 TinyMCE에
"NetworkError: 404 Not Found - http://[my-domain]/[current-path]//langs/en.js"
"NetworkError: 404 Not Found - http://[my-domain]/[current-path]//plugins/fullscreen/editor_plugin.js"
"NetworkError: 404 Not Found - http://[my-domain]/[current-path]//themes/advanced/editor_template.js"
"NetworkError: 404 Not Found - http://[my-domain]/[current-path]//plugins/media/editor_plugin.js"
을 그들 때문에 내 출처에 등재되어 있지 않아. 내 JS는 다음과 같습니다
tinyMCE.init({
theme: "advanced",
mode: "textareas",
plugins: "fullscreen, media",
height: 300,
relative_urls :true,
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_buttons1 : "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,search,replace,|,bullist,numlist,|,outdent,indent,|undo,redo,|,link,unlink,anchor,image,cleanup,code,|,insertdate,inserttime,preview,hr,removeformat,visualaid,|,sub,sup,|,fullscreen,spellchecker",
theme_advanced_buttons2 : "styleselect,formatselect,imageListBox,media",
theme_advanced_buttons3 : "",
editor_selector : "mceEditor",
extended_valid_elements : "form[action|accept|accept-charset|enctype|method|name|onsubmit|id|name]",
convert_urls : false,
remove_script_host : false
});
function toggleTinyMCE(id) {
if (!tinyMCE.get(id))
tinyMCE.execCommand('mceAddControl', false, id);
else
tinyMCE.execCommand('mceRemoveControl', false, id);
}
내 TinyMCE에 파일의 모든 디렉터리 응용 프로그램/자산/자바 스크립트/tiny_mce에, 그래서 상관없이 내가 그들을 설정 무엇을 내 초기화 PARAMS에 document_base_url
및 base_url
을 추가하는 시도,하지만 한 내가 TinyMCE를 방화범을 가지고 조사 할 때, 나는 그들의 값이 내가 입력 한 것으로 바뀌지 않는다는 것을 안다.
나는에 Kete에 의한 레일 플러그인 TinyMCE에 대한 존재한다는 것을 알고 있지만, its README 그것이 레일 사용하지 않는 것이 좋습니다한다고> = 3.1
이 질문에 대한 대답은 많은 도움/application.rb 설정에 추가하여 자산 pipline을 준수합니다. com/questions/7325364/tinymce-loading-lang-plugins-theme-from-incorrect 디렉토리 –