Return-Path: Delivered-To: apmail-myfaces-users-archive@www.apache.org Received: (qmail 78628 invoked from network); 21 Feb 2006 20:57:28 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 21 Feb 2006 20:57:28 -0000 Received: (qmail 16928 invoked by uid 500); 21 Feb 2006 20:57:22 -0000 Delivered-To: apmail-myfaces-users-archive@myfaces.apache.org Received: (qmail 16874 invoked by uid 500); 21 Feb 2006 20:57:22 -0000 Mailing-List: contact users-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Discussion" Delivered-To: mailing list users@myfaces.apache.org Received: (qmail 16863 invoked by uid 99); 21 Feb 2006 20:57:22 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Feb 2006 12:57:22 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=HTML_MESSAGE X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [209.251.33.34] (HELO mail.chessys.com) (209.251.33.34) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Feb 2006 12:57:18 -0800 Received: from Jeremy [209.251.44.105] by mail.chessys.com with ESMTP (SMTPD-8.21) id AE9119DC; Tue, 21 Feb 2006 15:56:49 -0500 From: "Jeremy Sager" To: "'MyFaces Discussion'" Subject: RE: MyFAces with FAcelets Date: Tue, 21 Feb 2006 16:02:43 -0500 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_01E5_01C63700.4035C070" X-Mailer: Microsoft Office Outlook, Build 11.0.5510 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 thread-index: AcY3DfHzPaQn4yguSlObTphGZ3WrXQAGwXIw In-Reply-To: <20060221124071.SM36472@scanner.syssrc.com> Message-Id: <20060221155699.SM36320@Jeremy> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N This is a multi-part message in MIME format. ------=_NextPart_000_01E5_01C63700.4035C070 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit A few things to examine: Remember in facelets, you are using xhtml, which requires all tags to have an ending, whereas in html you can get away with not doing that. which could be the problem. Not properly ending all tags can cause pages to not render. Are you using the correct jar files for facelets? Do you have this in your faces-config.xml? com.sun.facelets.FaceletViewHandler Also, are you using ADF stuff? This can cause additional complications and facelets needs to be configured differently than in the wiki article. Jeremy Sager Data Communications Product Manager Chesapeake System Solutions 410.356.6805 x120 JSager@chessys.com _____ From: Adam Brod [mailto:ABrod@intralinks.com] Sent: Tuesday, February 21, 2006 12:40 PM To: MyFaces Discussion Subject: Re: MyFAces with FAcelets That's really a question for the Facelets user group. However, yes, you can have components in your templates, but you have to be a bit careful to define the view component to include all the components. Adam Brod Product Development Team "Marco Mistroni" 02/21/2006 12:15 PM Please respond to "MyFaces Discussion" To "MyFaces Discussion" cc Subject Re: MyFAces with FAcelets Hello guys, ok i figured out what's the problem... it's my template layout page that has somethign wrong in it.. when i replaced it iwth the template that comes with facelets demo application everything works fine... i guess i'll get back here when i will find out what's wrong with my original template..... one quick question: can a template include JSF elements? will i have problems? thanks and regards marco On 2/21/06, Marco Mistroni wrote: hello richard, thanx for your reply unfortunately, when i enter pagename.jsf i get following error type Status report message /TestJSFApp/main.jsf description The requested resource (/TestJSFApp/main.jsf) is not available. pls note that this was working when i was usingn tiles....... i can't imagine what could be thep roblem am i specifying the wrong handler in jsf-config ? en resources.MessageResources com.sun.facelets.FaceletViewHandler ....... ? thanx and regards marco On 2/21/06, Richard Frazer wrote: What's the url you are trying to hit? Based on the web.xml below, you are mapping the faces servlet to *.jsf. The url you enter should be .jsf, not .xhtml. _____ From: Marco Mistroni < mmistroni@gmail.com> Reply-To: MyFaces Discussion < users@myfaces.apache.org> Date: Tue, 21 Feb 2006 16:45:12 +0000 To: MyFaces Discussion < users@myfaces.apache.org> Subject: Re: MyFAces with FAcelets Hello Adam, when i access main.xhtml, INternet explorer does not 'recongnize' it and ask me if i want to open the page..... so, yes, something is not configured properly, but i can' tfigure out what... it looks like it does not recongize facelets tags at all.. since the text that is not supposed to be shown instead it is shown.. here's my main.xhtml http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "> This text will not be displayed.Wrong! iw till be.. BudgetApp version 1.3 - Budget Queries This text will also not be displayed. Simple Test for entry here' s again my wbe.xml http://java.sun.com/dtd/web-app_2_3.dtd "> contextConfigLocation /WEB-INF/core-context.xml /WEB-INF/web-context.xml /WEB-INF/aop-context.xml /WEB-INF/applicationContext-acegi-security.xml /WEB-INF/applicationContext-common-authorization.xml /WEB-INF/applicationContext-common-business.xml /WEB-INF/faces-context.xml /WEB-INF/dataSourcePopulator.xml javax.servlet.jsp.jstl.fmt.localizationContext resources.MessageResources javax.faces.CONFIG_FILES /WEB-INF/faces- config.xml,/WEB-INF/faces-managed-beans.xml,/WEB-INF/faces-navigation.xml

facelets.REFRESH_PERIOD 2 facelets.DEVELOPMENT true javax.faces.STATE_SAVING_METHOD client javax.faces.DEFAULT_SUFFIX .xhtml com.sun.faces.validateXml true Set this flag to true if you want the JavaServer Faces Reference Implementation to validate the XML in your faces-config.xml resources against the DTD. Default value is false. com.sun.faces.verifyObjects true Set this flag to true if you want the JavaServer Faces Reference Implementation to verify that all of the application objects you have configured (components, converters, renderers, and validators) can be successfully created. Default value is false. Acegi Filter Chain Proxy net.sf.acegisecurity.util.FilterToBeanProxy targetClass net.sf.acegisecurity.util.FilterChainProxy contextHolderAwareFilter net.sf.acegisecurity.util.FilterToBeanProxy targetClass net.sf.acegisecurity.wrapper.ContextHolderAwareRequestFilter anonymousProcessingFilter net.sf.acegisecurity.util.FilterToBeanProxy targetClass net.sf.acegisecurity.util.FilterChainProxy extensionsFilter org.apache.myfaces.component.html.util.ExtensionsFilter uploadMaxFileSize 100m Set the size limit for uploaded files. Format: 10 - 10 bytes 10k - 10 KB 10m - 10 MB 1g - 1 GB uploadThresholdSize 100k Set the threshold size - files below this limit are stored in memory, files above this limit are stored on disk. Format: 10 - 10 bytes 10k - 10 KB 10m - 10 MB 1g - 1 GB RequestHandled de.mindmatters.faces.spring.support.RequestHandledFilter Acegi Filter Chain Proxy /* contextHolderAwareFilter /* anonymousProcessingFilter /* RequestHandled *.jsf extensionsFilter *.jsf extensionsFilter /faces/* org.springframework.web.context.ContextLoaderListener org.apache.myfaces.webapp.StartupServletContextListener de.mindmatters.faces.spring.support.ContextLoaderListener net.sf.acegisecurity.ui.session.HttpSessionEventPublisher Faces Servlet javax.faces.webapp.FacesServlet 1 Faces Servlet *.jsf login.jsp /WEB-INF/struts-html.tld /WEB-INF/tld/struts-html.tld http://worldcorp.co.uk/jsf/component/tags /WEB-INF/tld/jsfapp.tld /WEB-INF/struts-tiles.tld /WEB-INF/tld/struts-tiles.tld root
hope you can still help me out.... thanks and regards marco ------=_NextPart_000_01E5_01C63700.4035C070 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

A few things to = examine:

 

Remember in facelets, you are using xhtml, which requires all tags = to have an ending, whereas in html you can get away with not doing that… = which could be the problem. Not properly ending all tags can cause pages to = not render.

 

Are you using the correct jar files = for facelets?

 

Do you have this in your = faces-config.xml?

 

<faces-config>        =
; 
  <application>
    <view-handler>
      =
com.sun.facelets.FaceletViewHandler
    =
</view-handler>    =
  </application> =
</faces-config>

 

 

Also, are you using ADF stuff? This = can cause additional complications and facelets = needs to be configured differently than in the wiki = article.

 

Jeremy = Sager

Data = Communications Product Manager

= Chesapeake System Solutions

410.356.6805 = x120

JSager@chessys.com


From: Adam = Brod [mailto:ABrod@intralinks.com]
Sent: Tuesday, February = 21, 2006 12:40 PM
To: MyFaces Discussion
Subject: Re: MyFAces with = FAcelets

 


That's really a question for the Facelets user = group.  However, yes, you can have components in your templates, but you have to be a bit careful to define the view component to include all the components.

Adam Brod

Product Development Team

"Marco = Mistroni" <mmistroni@gmail.com> =

02/21/2006 12:15 PM

Please respond to
"MyFaces = Discussion" <users@myfaces.apache.org>

To

"MyFaces Discussion" = <users@myfaces.apache.org>

cc

 

Subject

Re: MyFAces with = FAcelets

 

 

 




Hello guys,
 ok i figured out what's the problem... it's my  template = layout  page that has somethign wrong in it..
when i replaced it iwth the template that comes with facelets demo = application everything works fine...

i guess i'll get back here when i will find out what's wrong with my = original template.....

one quick question: can a template include JSF elements? will i have = problems?

thanks and regards

marco

On 2/21/06, Marco = Mistroni <mmistroni@gmail.com> wrote: =
hello richard,
 thanx for your reply

unfortunately, when i enter  pagename.jsf i get following = error

type Status report

message /TestJSFApp/main.jsf =

description The requested = resource (/TestJSFApp/main.jsf) is not available.


pls note that this was working when i was usingn tiles.......  i = can't imagine what could be thep roblem

am i specifying the wrong handler in jsf-config ?


<faces-config>
     <application>
      <locale-config>
      =  <default-locale>en</default-locale>
      </locale-config>
      <message-bundle>resources.MessageResources</message-bundle> =
      <view-handler>
     com.sun.facelets.FaceletViewHandler
   </view-handler>    
   </application>

 .......
</faces-config>

?

thanx and regards
marco





On 2/21/06, Richard = Frazer <Richard.Frazer@sas.com> wrote:
What's the url you are trying to hit?  Based = on the web.xml below, you are mapping the faces servlet to *.jsf.  The url = you enter should be <pagename>.jsf, not <pagename>.xhtml.


From: = Marco Mistroni <mmistroni@gmail.com<= /font>>
Reply-To:
MyFaces = Discussion <
users@myfaces.apache.org>
Date:
Tue, 21 Feb 2006 16:45:12 +0000
To:
MyFaces = Discussion <
users@myfaces.apache.org>
Subject:
Re: MyFAces with FAcelets

Hello Adam,
 when i access main.xhtml, INternet explorer does not 'recongnize' = it and ask me if i want to open the page.....
so, yes, something is not configured properly, but i can' tfigure out = what...

it looks like it does not recongize facelets tags at all.. since the = text that is not supposed to be shown
instead it is shown..

here's my main.xhtml

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 = Transitional//EN" "
http://www.w3.org/TR/xhtml1= /DTD/xhtml1-transitional.dtd <http://www.w3.org/TR/xh= tml1/DTD/xhtml1-transitional.dtd> ">

<html xmlns=3D"
http://www.w3.org/1999/xhtml <http://www.w3.org/1999/= xhtml> "
     xmlns:ui=3D"
http://java.sun.com/jsf/fac= elets"
>
   
<body>

  <ui:composition template=3D"/layout/verticalClassicLayout.xhtml"
>

    This text will not be displayed.Wrong! iw till be..

     <ui:define name=3D"title"
>
        BudgetApp version 1.3 - Budget Queries
     </ui:define>

    This text will also not be displayed.


     <ui:define
name=3D"body">
 Simple Test for entry
     </ui:define>


  </ui:composition>

 
</body>
</html>    




here' s again my wbe.xml

<?xml version=3D" 1.0" = encoding=3D"UTF-8"?>

<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web = Application 2.3//EN" "
http://java.sun.com/dtd/web-app_2_3.dtd =  <http://java.sun.com/dtd= /web-app_2_3.dtd> ">


<web-app >
<context-param>
  =  <param-name>contextConfigLocation</param-name>
   <param-value>
       /WEB-INF/core-context.xml
       /WEB-INF/web-context.xml
       /WEB-INF/aop-context.xml
      =  /WEB-INF/applicationContext-acegi-security.xml
      =  /WEB-INF/applicationContext-common-authorization.xml
      =  /WEB-INF/applicationContext-common-business.xml
           /WEB-INF/faces-context.xml
       /WEB-INF/dataSourcePopulator.xml
       
   </param-value>
</context-param>

<context-param>
 <param-name>javax.servlet.jsp.jstl.fmt.localizationContext </param-name>
 <param-value>resources.MessageResources</param-value> </context-param>

<context-param>
     <param-name>javax.faces.CONFIG_FILES</param-name>
     <param-value>/WEB-INF/faces- config.xml,/WEB-INF/faces-managed-beans.xml,/WEB-INF/faces-navigation.xml= </param-value>
</context-param>

<context-param>
       <param-name>facelets.REFRESH_PERIOD</param-name>
       <param-value>2</param-value>
   </context-param>

   <context-param>
      =  <param-name>facelets.DEVELOPMENT</param-name>
       <param-value>true</param-value> =
   </context-param>

   <context-param>
       <param-name>javax.faces.STATE_SAVING_METHOD</param-name>= ;
      =  <param-value>client</param-value>
   </context-param>
   <context-param>
      =  <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
=       =  <param-value>.xhtml</param-value>
   </context-param>

   <context-param>
       <param-name>com.sun.faces.validateXml</param-name>
      =  <param-value>true</param-value>
       <description>
           Set this flag to true if you = want the JavaServer Faces
           Reference Implementation to = validate the XML in your
           faces-config.xml resources = against the DTD.  Default
           value is false.
       </description>
   </context-param>

   <context-param>
       <param-name>com.sun.faces.verifyObjects</param-name>       =  <param-value>true</param-value>
       <description>
           Set this flag to true if you = want the JavaServer Faces
           Reference Implementation to = verify that all of the application
           objects you have configured (components, converters,
           renderers, and validators) can = be successfully created.
           Default value is false.
       </description>
   </context-param>

 <!-- Acegi filters -->

<filter>
       <filter-name>Acegi Filter Chain Proxy</filter-name>
       <filter-class>net.sf.acegisecurity.util.FilterToBeanProxy<= /filter-class>
       <init-param>
           <param-name>targetClass</param-name>
           <param-value> = net.sf.acegisecurity.util.FilterChainProxy</param-value>
       </init-param>
</filter>

<filter>
       <filter-name>contextHolderAwareFilter</filter-name>
=        <filter-class> net.sf.acegisecurity.util.FilterToBeanProxy</filter-class>
       <init-param>
           <param-name>targetClass</param-name>
           <param-value>net.sf.acegisecurity.wrapper.ContextHolderAwareR= equestFilter </param-value>
       </init-param>
</filter>

<filter>
       <filter-name>anonymousProcessingFilter</filter-name>       =  <filter-class>net.sf.acegisecurity.util.FilterToBeanProxy </filter-class>
       <init-param>
           <param-name>targetClass</param-name>
           <param-value>net.sf.acegisecurity.util.FilterChainProxy</p= aram-value>
       </init-param>
</filter>

<filter>
       <filter-name>extensionsFilter</filter-name>
       <filter-class>org.apache.myfaces.component.html.util.Extensio= nsFilter</filter-class>
       <init-param>
           <param-name>uploadMaxFileSize</param-name>
          =  <param-value>100m</param-value>
           <description>Set the size = limit for uploaded files.
               Format: 10 - 10 = bytes
                    =    10k - 10 KB
                    =    10m - 10 MB
                    =    1g - 1 GB
           </description>
       </init-param>
       <init-param>
           <param-name>uploadThresholdSize</param-name>
           <param-value>100k</param-value>
           <description>Set the = threshold size - files
                  =  below this limit are stored in memory, files above
                  =  this limit are stored on disk.

               Format: 10 - 10 = bytes
                    =    10k - 10 KB
                    =    10m - 10 MB
                    =    1g - 1 GB
           </description>
       </init-param>
<!--        <init-param>
           <param-name>uploadRepositoryPath</param-name>
           <param-value>/temp</param-value>
           <description>Set the path = where the intermediary files will be stored.
           </description>
       </init-param>-->
   </filter>

<!-- JSF-Spring filters -->

<filter>
       <filter-name>RequestHandled</filter-name>
       <filter-class>de.mindmatters.faces.spring.support.RequestHand= ledFilter</filter-class>
</filter>

<filter-mapping>
 <filter-name>Acegi Filter Chain Proxy</filter-name> =
 <url-pattern>/*</url-pattern>
</filter-mapping>

<filter-mapping>
 <filter-name>contextHolderAwareFilter</filter-name>
=  <url-pattern>/*</url-pattern>
</filter-mapping>

<filter-mapping>
 <filter-name>anonymousProcessingFilter</filter-name>  <url-pattern>/*</url-pattern>
</filter-mapping>

<filter-mapping>
 <filter-name>RequestHandled</filter-name>
 <url-pattern>*.jsf</url-pattern>
</filter-mapping>

<filter-mapping>
 <filter-name>extensionsFilter</filter-name>
 <url-pattern>*.jsf</url-pattern>
</filter-mapping>
<filter-mapping>
 <filter-name>extensionsFilter</filter-name>
 <url-pattern>/faces/*</url-pattern>
</filter-mapping>

   <!--
   To use non XDoclet filter-mappings, create a = filter-mappings.xml file that
   contains the additional filter-mappings and place it in = your
   project's merge dir.
   -->

 <listener>
       <listener-class>org.springframework.web.context.ContextLoader= Listener</listener-class>
</listener>

<listener>
         <listener-class> org.apache.myfaces.webapp.StartupServletContextListener</listener-clas= s>
</listener>
<listener>
     <listener-class>de.mindmatters.faces.spring.support.ContextLo= aderListener</listener-class>
</listener>

<listener>
  <listener-class>net.sf.acegisecurity.ui.session.HttpSessionEventPub= lisher</listener-class>
</listener>

  <servlet>
   <servlet-name>Faces Servlet</servlet-name>
   <servlet-class>javax.faces.webapp.FacesServlet</servlet-cl= ass>
   <load-on-startup>1</load-on-startup>
 </servlet>
<!--    
 <servlet>
   <servlet-name>TilesServet</servlet-name>
   <servlet-class>org.apache.struts.tiles.TilesServlet</servl= et-class>
   <init-param>
    =  <param-name>definitions-config</param-name>
     <param-value>/WEB-INF/tiles- defs.xml</param-value>
   </init-param>
   <init-param>
    =  <param-name>definitions-parser-validate</param-name>
     <param-value>true</param-value>
   </init-param>
   <load-on-startup>2</load-on-startup>
 </servlet>

 -->

 <servlet-mapping>
  <servlet-name>Faces Servlet</servlet-name>
  <url-pattern>*.jsf</url-pattern>
</servlet-mapping>

  <!--
  To specify mime mappings, create a file named mime-mappings.xml, = put it in your project's mergedir.
  Organize mime-mappings.xml following this DTD slice:

  <!ELEMENT mime-mapping (extension, mime-type)>
  -->

    <welcome-file-list>
   <welcome-file>login.jsp</welcome-file>
 </welcome-file-list>

  <!--
  To specify error pages, create a file named error-pages.xml , put = it in your project's mergedir.
  Organize error-pages.xml following this DTD slice:

  <!ELEMENT error-page ((error-code | exception-type), = location)>
  -->

    <!-- Struts-EL Tag Library Descriptors -->

 <taglib>
  =  <taglib-uri>/WEB-INF/struts-html.tld</taglib-uri>
   <taglib-location>/WEB-INF/tld/struts-html.tld</taglib-loca= tion>
 </taglib>

 <taglib>
   <taglib-uri>
http://worldcorp.co.uk/jsf/component/tags</taglib= -uri>
   <taglib-location>/WEB-INF/tld/jsfapp.tld</taglib-location&= gt;
 </taglib>
<taglib>
 <taglib-uri>/WEB-INF/struts-tiles.tld</taglib-uri>
 <taglib-location>/WEB-INF/tld/struts-tiles.tld</taglib-loc= ation>
</taglib>

  <!--
  To set up security settings for your web app, create a file named web-security.xml, put it in your project's mergedir.
  Organize web-security.xml following this DTD slice:

  <!ELEMENT security-constraint (display-name?, web-resource-collection+, auth-constraint?, user-data-constraint?)> =
  <!ELEMENT web-resource-collection (web-resource-name, = description?, url-pattern*, http-method*)>
  <!ELEMENT web-resource-name (#PCDATA)>
  <!ELEMENT url-pattern (#PCDATA)>
  <!ELEMENT http-method (#PCDATA)>
  <!ELEMENT user-data-constraint (description?, transport-guarantee)>
  <!ELEMENT transport-guarantee (#PCDATA)>

  <!ELEMENT login-config (auth-method?, realm-name?, form-login-config?)>
  <!ELEMENT auth-method (#PCDATA)>
  <!ELEMENT realm-name (#PCDATA)>
  <!ELEMENT form-login-config (form-login-page, = form-error-page)>
  <!ELEMENT form-login-page (#PCDATA)>
  <!ELEMENT form-error-page (#PCDATA)>
  -->

 <security-role>
     <role-name>root</role-name>
  </security-role>

</web-app>


hope you can still help me out....

thanks and regards

marco







------=_NextPart_000_01E5_01C63700.4035C070--