在gemfile中加入(后面版本别丢)
gem ‘rails_kindeditor‘, ‘~> 0.5.0‘
$ bundle
创建配置文件,并且引入js
rails g rails_kindeditor:install
rails kindeditor:assets
js获取编辑器的内容
rails页面中加入以下表单
?<%= form_for @article do |f| %> ???<%= f.kindeditor :content, :editor_id => ‘my_editor‘ %> ?<% end %>
js
?my_editor.html();
rails使用Kindeditor网页编辑器
原文地址:https://www.cnblogs.com/virus1996/p/9324800.html