[ 
https://issues.jboss.org/browse/RF-12797?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Serge Mürset updated RF-12797:
------------------------------

    Workaround Description: 
To make rich:editor work with RF-module, add this WebListener in your WAR:

{code}
import javax.servlet.ServletContext;
import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;
import javax.servlet.ServletRegistration.Dynamic;
import javax.servlet.annotation.WebListener;

import org.richfaces.webapp.ResourceServlet;
import org.richfaces.webapp.ResourceServletContainerInitializer;

@WebListener
public class RichFacesInitializer implements ServletContextListener {
 
    @Override
    public void contextInitialized(final ServletContextEvent sce) {
        final ServletContext servletContext = sce.getServletContext();
        Dynamic dynamicRegistration = 
servletContext.addServlet("AutoRegisteredEditorResourceServlet", 
ResourceServlet.class);
        
dynamicRegistration.addMapping(ResourceServletContainerInitializer.EDITOR_RESOURCES_DEFAULT_MAPPING);
    }
 
    @Override
    public void contextDestroyed(final ServletContextEvent sce) {
    }
}
{code}

  was:
To make rich:editor work with RF-module:

{code}
import javax.servlet.ServletContext;
import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;
import javax.servlet.ServletRegistration.Dynamic;
import javax.servlet.annotation.WebListener;

import org.richfaces.webapp.ResourceServlet;
import org.richfaces.webapp.ResourceServletContainerInitializer;

@WebListener
public class RichFacesInitializer implements ServletContextListener {
 
    @Override
    public void contextInitialized(final ServletContextEvent sce) {
        final ServletContext servletContext = sce.getServletContext();
        Dynamic dynamicRegistration = 
servletContext.addServlet("AutoRegisteredEditorResourceServlet", 
ResourceServlet.class);
        
dynamicRegistration.addMapping(ResourceServletContainerInitializer.EDITOR_RESOURCES_DEFAULT_MAPPING);
    }
 
    @Override
    public void contextDestroyed(final ServletContextEvent sce) {
    }
}
{code}


    
> rich:editor not rendered when using RichFaces module
> ----------------------------------------------------
>
>                 Key: RF-12797
>                 URL: https://issues.jboss.org/browse/RF-12797
>             Project: RichFaces
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: cdk, component-input
>    Affects Versions: 4.3.0.Final
>         Environment: JBoss 7.1.1
>            Reporter: Serge Mürset
>             Fix For: 5-Tracking
>
>         Attachments: editor-test.zip
>
>
> I want to configure my Webapp to use RichFaces as a JBoss module not a 
> library. To achieve this, I create the module org.richfaces with version 
> 4.3.0 in module directory of JBoss.
> As soon as I switch from library to module, the rich:editor is not rendered 
> anymore. In the Browser History i read 
> [15:07:25.511] GET 
> http://localhost:8080/editor-test/org.richfaces.resources/javax.faces.resource/org.richfaces.ckeditor/lang/de.js?t=D03G5XL
>  [HTTP/1.1 404 Not Found 1ms]
> I validated that the resource lang/de.js is available in classpath though. 
> 15:01:02,780 INFO  [stdout] (MSC service thread 1-5) The following 
> resource(s) are found at location 
> /META-INF/resources/org.richfaces.ckeditor/lang/de.js
> 15:01:02,781 INFO  [stdout] (MSC service thread 1-5) --- 
> jar:file:/opt/jboss-7.1.1/modules/org/richfaces/main/richfaces-components-ui-4.3.0.Final.jar!/META-INF/resources/org.richfaces.ckeditor/lang/de.js
> Weird enough, all other components I checked still work. I followed the 
> instructions of https://issues.jboss.org/browse/RF-12008.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

_______________________________________________
richfaces-issues mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/richfaces-issues

Reply via email to