Finally!!.. I have it working now . I had to replace the line
editPlugin.put("features", "*");
with a JSONArray object for the features that I wanted (I tested with the "copy" and "paste" features as an example)
JSONArray editPluginFeatures = new JSONArray(); editPluginFeatures.put("copy"); editPluginFeatures.put("cut"); editPlugin.put("features", editPluginFeatures);
so the full example code for the "copy" & "paste" features is..
JSONObject editPlugin = new JSONObject(); editPlugin.put(JcrConstants.JCR_PRIMARYTYPE, JcrConstants.NT_UNSTRUCTURED); editPlugin.put("defaultPasteMode", "plaintext"); JSONArray editPluginFeatures = new JSONArray(); editPluginFeatures.put("copy"); editPluginFeatures.put("cut"); editPlugin.put("features", editPluginFeatures); rtePlugins.put("edit", editPlugin);
I can now start to apply all the features and others options as I need. Thanks to everyone for their feedback