This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 185189

Summary: run XHTML file as a JSF file
Product: javaee Reporter: Jindrich Sedek <jsedek>
Component: JSFAssignee: Martin Fousek <marfous>
Status: NEW ---    
Severity: normal Keywords: PLAN
Priority: P2    
Version: 6.x   
Hardware: PC   
OS: Linux   
Issue Type: ENHANCEMENT Exception Reporter:

Description Jindrich Sedek 2010-04-28 15:09:57 UTC
Imagine having a web project with a bunch of XHTML files. Something like Scrum Toys sample project.

Invoking run file on XHTML behaves the same way in Web project - it doesn't consider JSF enabled, so it just opens XHTML code in browser. It doesn't help much during development.

It would be good if there was an action Run as JSF in case there is JSF enabled and there is a rule mapping this XHTML to a JSF page.

For example you have this piece of code in web.xml:
    <servlet>
        <servlet-name>Faces Servlet</servlet-name>
        <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    </servlet>
    <servlet-mapping>
        <servlet-name>Faces Servlet</servlet-name>
        <url-pattern>*.jsf</url-pattern>
    </servlet-mapping>

The action should open /xyz/test.jsf instead of /xyz/test.xhtml.

It would make JSF testing and debugging much easier