Thanks Chris.
I think it moved one step further..

now my web.xml looks like
--------------------------------------------

<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_9" version="2.4"
xmlns="http://java.sun.com/xml/ns/j2ee";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd";>

    <display-name>Mortgage Application</display-name>

    <filter>
        <filter-name>mortgage</filter-name>

<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
    </filter>

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

    <servlet>
        <servlet-name>tiles</servlet-name>

<servlet-class>org.apache.tiles.servlet.TilesServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <context-param>
        <param-name>tiles-definitions</param-name>
        <param-value>/WEB-INF/tiles-config.xml</param-value>
    </context-param>
    <listener>

<listener-class>org.apache.struts2.tiles.StrutsTilesListener</listener-class>
    </listener>
</web-app>


tiles-config.xml
------------------------------

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE tiles-definitions PUBLIC "-//Apache Software Foundation//DTD
Tiles Configuration 2.0//EN"
        "http://tiles.apache.org/dtds/tiles-config_2_0.dtd";>

 <tiles-definitions>
    <definition  name="selectProd" path="/pages/selectproduct.jsp"/>
</tiles-definitions>


and struts.xml
---------------------------

    <result-types>
      <result-type name="tiles"
class="org.apache.struts2.views.tiles.TilesResult"/>
    </result-types>

    <action name="selectProduct">
        <result type="tiles">selectProd</result>
    </action>


when i try to try to load the page the following error occurs

08:57:36,479 INFO  [BasicTilesContainer] Initializing Tiles2 container. . .
08:57:36,479 WARN  [BasicTilesContainer] Unable to find configured
definition '/
WEB-INF/tiles.xml'
08:57:36,479 INFO  [BasicTilesContainer] Tiles2 container initialization
complet
e.
08:57:36,479 INFO  [TilesAccess] Publishing TilesContext for context:
org.apache
.tiles.servlet.ServletContextAdapter
08:57:39,932 WARN  [BasicTilesContainer] Unable to find the definition
'selectPr
od'
08:57:39,932 ERROR [[default]] Servlet.service() for servlet default threw
excep
tion
org.apache.tiles.definition.NoSuchDefinitionException: selectProd
        at
org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.
java:398)
        at
org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.
java:374)
        at
org.apache.struts2.views.tiles.TilesResult.doExecute(TilesResult.java


I am not able to understand why is it try to look for tiles.xml in WEB-INF
directory and thus not finding the definition.
I tries renaming the file to tiles.xml but that also did not help(then the
NullPointer error re-appered)


Any help will be much appreciated.

Manoj.








                                                                           
             "Chris Pratt"                                                 
             <[EMAIL PROTECTED]                                             
             ail.com>                                                   To 
                                       "Struts Users Mailing List"         
             02/07/2007 19:35          <user@struts.apache.org>            
                                                                        cc 
                                                                           
             Please respond to                                     Subject 
               "Struts Users           Re: Configuring Tiles in S2         
               Mailing List"                                               
             <[EMAIL PROTECTED]                                             
                  he.org>                                                  
                                                                           
                                                                           
                                                                           




You may need to include the context-param to define your
tiles-config.xmlfile for the listener.

  <context-param>
    <param-name>tiles-definitions</param-name>
    <param-value>/WEB-INF/tiles-config.xml</param-value>
  </context-param>


  (*Chris*)

On 7/2/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> i have done the following configuration ----
>
> struts.xml
> ----------------------
> <result-types>
>       <result-type name="tiles"
> class="org.apache.struts2.views.tiles.TilesResult"/>
>     </result-types>
>
>
>     <action name="selectProduct">
>         <result type="tiles">selectProduct</result>
>     </action>
>
> web.xml
> --------------------
> <servlet>
>      <servlet-name>tiles</servlet-name>
>      <servlet-class>org.apache.tiles.servlet.TilesServlet</servlet-class>
>      <init-param>
>          <param-name>definitions-config</param-name>
>          <param-value>/WEB-INF/tiles-config.xml</param-value>
>      </init-param>
>      <load-on-startup>1</load-on-startup>
> </servlet>
> <listener>
>
> <listener-class>org.apache.struts2.tiles.StrutsTilesListener
> </listener-class>
>     </listener>
>
> tiles-config.xml
> -------------------------------
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE tiles-definitions PUBLIC "-//Apache Software Foundation//DTD
> Tiles Configuration 2.0//EN"
>         "http://tiles.apache.org/dtds/tiles-config_2_0.dtd";>
>
> <tiles-definitions>
>     <definition name="selectProduct" path="/pages/selectproduct.jsp">
>         <put-attribute name="selectProductContent"
> value="/pages/selectproduct.jsp" />
>     </definition>
> </tiles-definitions>
>
>
> when i try to  try to go to
> http://localhost:8080/mortgage/selectProduct.action  url it comes up with
> the following error
>
>
> 16:46:07,702 INFO  [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8009
> 16:46:07,718 INFO  [JkMain] Jk running ID=0 time=0/47  config=null
> 16:46:07,733 INFO  [Server] JBoss (MX MicroKernel) [4.0.5.GA (build:
> CVSTag=Bran
> ch_4_0 date=200610162339)] Started in 31s:500ms
> 16:46:16,796 INFO  [ActionValidatorManagerFactory] Detected
> AnnotationActionVali
> datorManager, initializing it...
> 16:46:17,171 ERROR [BasicTilesContainer] Error rendering tile
> java.lang.NullPointerException
>         at
> org.apache.tiles.context.servlet.ServletTilesRequestContext.forward(S
> ervletTilesRequestContext.java:196)
>         at
> org.apache.tiles.context.servlet.ServletTilesRequestContext.dispatch(
> ServletTilesRequestContext.java:183)
>         at
> org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.
> java:423)
>         at
> org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.
> java:374)
>         at
> org.apache.struts2.views.tiles.TilesResult.doExecute(TilesResult.java
> :104)
>
>
>
>
>
>
>              Dave Newton
>              <[EMAIL PROTECTED]
>              o.com>
To
>                                        Struts Users Mailing List
>              02/07/2007 17:15          <user@struts.apache.org>
>
cc
>
>              Please respond to
Subject
>                "Struts Users           Re: Configuring Tiles in S2
>                Mailing List"
>              <[EMAIL PROTECTED]
>                   he.org>
>
>
>
>
>
>
>
> --- [EMAIL PROTECTED] wrote:
> > 16:46:17,171 ERROR [BasicTilesContainer] Error
> > rendering tile
> >
> > can anyone advise of what we're doing wrong?
>
> That's... perhaps not enough information to go on.
>
> d.
>
>
>
>
>
>
____________________________________________________________________________________

>
> Get your own web address.
> Have a HUGE year through Yahoo! Small Business.
> http://smallbusiness.yahoo.com/domains/?p=BESTDEAL
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
> This message has been checked for viruses and spam by the Virgin Money
> email scanning system powered by Messagelabs.
>
>
>
>
>
>
> This e-mail is intended to be confidential to the recipient. If you
> receive a copy in error, please inform the sender and then delete this
> message. Virgin Money do not accept responsibility for changes made to
any
> e-mail after sending. Virgin Money have swept, and believe this e-mail to
be
> free of viruses and profanity but make no guarantees to this effect.
>
> Virgin Money Personal Financial Service Ltd is authorised and regulated
by
> the Financial Services Authority. Registered in England no. 3072766.
Entered
> on the Financial Services Authority's Register
> http://www.fsa.gov.uk/register/. Register Number 179271. The Virgin
> Deposit Account is a personal bank account with The Royal Bank of
Scotland.
>
> Virgin Money Unit Trust Managers Ltd is authorised and regulated by the
> Financial Services Authority. Registered in England no. 3000482. Entered
on
> the Financial Services Authority's Register. Register Number 171748.
>
> Virgin Money Ltd. Registered in England no. 4232392. Introducer appointed
> representative only of Virgin Money Personal Financial Service Ltd.
>
> Virgin Money Management Services Ltd. Registered in England no.3072772.
>
> Virgin Money Group Ltd. Registered in England no.3087587.
>
> All the above companies have their Registered office at Discovery House,
> Whiting Road, Norwich NR4 6EJ.
>
> All products are open only to residents of the United Kingdom.
>
> This message has been checked for viruses and spam by the Virgin Money
> email scanning system powered by Messagelabs.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


This message has been checked for viruses and spam by the Virgin Money
email scanning system powered by Messagelabs.





This e-mail is intended to be confidential to the recipient. If you receive a 
copy in error, please inform the sender and then delete this message. Virgin 
Money do not accept responsibility for changes made to any e-mail after 
sending. Virgin Money have swept, and believe this e-mail to be free of viruses 
and profanity but make no guarantees to this effect.

Virgin Money Personal Financial Service Ltd is authorised and regulated by the 
Financial Services Authority. Registered in England no. 3072766. Entered on the 
Financial Services Authority's Register http://www.fsa.gov.uk/register/. 
Register Number 179271. The Virgin Deposit Account is a personal bank account 
with The Royal Bank of Scotland.

Virgin Money Unit Trust Managers Ltd is authorised and regulated by the 
Financial Services Authority. Registered in England no. 3000482. Entered on the 
Financial Services Authority's Register. Register Number 171748.

Virgin Money Ltd. Registered in England no. 4232392. Introducer appointed 
representative only of Virgin Money Personal Financial Service Ltd.

Virgin Money Management Services Ltd. Registered in England no.3072772.

Virgin Money Group Ltd. Registered in England no.3087587.

All the above companies have their Registered office at Discovery House, 
Whiting Road, Norwich NR4 6EJ. 

All products are open only to residents of the United Kingdom.

This message has been checked for viruses and spam by the Virgin Money email 
scanning system powered by Messagelabs.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to