Skip to content

id not work for kindeditor_tag #101

@dreamable

Description

@dreamable

If we want to specify id instead of the default one from name, it won't work on the js part.
For example
<%= kindeditor_tag "name", value, input_html: {id: "my_id"} %>
In the generate html, the id for text_area is "my_id", but the js, it still use the default id "#name".

The fix should be in the rails_kindeditor/lib/rails_kindeditor/helper.rb file, change line 9 to
output << javascript_tag(js_replace(input_html[:id], options))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions