plugin + maven

Community Driven Extensions Project
Post Reply
eugui
Posts: 5
Joined: 15 Sep 2014, 15:47

26 Sep 2014, 14:08

Hi,

I have this in my pom.xml

Code: Select all

        <dependency>
           <groupId>org.primefaces.extensions</groupId>
           <artifactId>primefaces-extensions</artifactId>
           <version>1.2.1</version>
        </dependency>
        <dependency>
           <groupId>org.primefaces.extensions</groupId>
           <artifactId>resources-ckeditor</artifactId>
           <version>1.2.1</version>
        </dependency>
In my .xhtml:

Code: Select all

                        <pe:ckEditor 
                            id="texto" 
                            value="#{compNoticiaManutencaoMB.noticia.texto}" 
                            defaultLanguage="br"
                            interfaceColor="#D8D8D8" 
                            customConfig="/sgcdweb/javax.faces.resource/ckeditor.js.xhtml?ln=js"
                             /> 


I want to add plugins in this ckeditor, how I do this? I tried do put extraPlugin in ckeditor.js but I get error.

ckeditor.js

Code: Select all

CKEDITOR.editorConfig = function(config) {   
    config.language = 'pt-br';
    config.extraPlugins = 'abbr';    
};
Error:
Uncaught [CKEDITOR.resourceManager.load] Resource name "abbr" was not found at "http://localhost:8080/sgcdweb/javax.fac ... ns&v=1.2.1".

The correct url to access this plugin.js is:
http://localhost:8080/sgcdweb/javax.fac ... ugins/abbr

PF version 4
ckeditor 4.2

eugui
Posts: 5
Joined: 15 Sep 2014, 15:47

26 Sep 2014, 20:56

the solution:

Code: Select all

CKEDITOR.editorConfig = function(config) {
    
    config.language = 'pt-br';
    
    config.extraPlugins = 'abbr';
    CKEDITOR.plugins.addExternal( 'abbr', '../plugin.js.xhtml', '?ln=js/ckeditor/plugins/abbr/#' );
};

Post Reply

Return to “Extensions”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 8 guests