Re: Struts welcome-file-list problem
I'd try something like this: index.jsp: %@ page language=java % %@ taglib uri=/tags/struts-logic prefix=logic % logic:forward name=welcome/ web.xml ... welcome-file-list welcome-fileindex.jsp/welcome-file /welcome-file-list ... struts-config.xml ... global-forwards forward name=welcome path=/controllers/welcome/ ... /global-forwards action-mappings action path=/welcome forward=/WEB-INF/welcome.jsp/ ... /action-mappings ... So, I think /FedDebtWeb, /FedDebtWeb/index.jsp, or /FedDebtWeb/controllers/welcome would all get you to your welcome page. [EMAIL PROTECTED] wrote: We have all of our jsp's under Web-Inf. Therefore, you must call the action class to get to a web page. This all works great except for our welcome page called welcome.jsp that was built with Struts Tiles. If we go to the browser and just type http://localhost:8080/FedDebtWeb/controllers/welcome; we can get to the welcome page. If we type only http://localhost:8080/FedDebtWeb; it does not find the welcome.jsp page. Any suggestions on how to make this work? Thanks, Pete Gabriel Here are the code snippets for the different files: web.xml !-- Action Servlet Mapping -- servlet-mapping servlet-nameaction/servlet-name url-pattern/controllers/*/url-pattern /servlet-mapping !-- The Welcome File List -- welcome-file-list welcome-file/welcome/welcome-file /welcome-file-list struts.config.xml !-- == Global Forward Definitions == -- global-forwards forward name=/welcomepath=/controllers/welcome / /global-forwards !-- == Action Mapping Definitions == -- action-mappings action path=/welcome type= gov.treas.fms.feddebt.web.action.WelcomeAction scope=request validate=false forward name=page path=views.welcome/ /action /action-mappings tiles.def.xml definition name=standardLayout path= /WEB-INF/views/layout/standardLayout.jsp put name=title value=FedDebt/ put name=menu value=menu/ put name=header value=header/ put name=footer value=footer/ /definition !-- === -- !-- Welcome page definition -- !-- === -- definition name=views.welcome extends=standardLayout put name=body value=/WEB-INF/views/body/welcome.jsp/ /definition -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- Kris Schneider mailto:[EMAIL PROTECTED] D.O.Tech http://www.dotech.com/ smime.p7s Description: S/MIME Cryptographic Signature
Struts welcome-file-list problem
We have all of our jsp's under Web-Inf. Therefore, you must call the action class to get to a web page. This all works great except for our welcome page called welcome.jsp that was built with Struts Tiles. If we go to the browser and just type http://localhost:8080/FedDebtWeb/controllers/welcome; we can get to the welcome page. If we type only http://localhost:8080/FedDebtWeb; it does not find the welcome.jsp page. Any suggestions on how to make this work? Thanks, Pete Gabriel Here are the code snippets for the different files: web.xml !-- Action Servlet Mapping -- servlet-mapping servlet-nameaction/servlet-name url-pattern/controllers/*/url-pattern /servlet-mapping !-- The Welcome File List -- welcome-file-list welcome-file/welcome/welcome-file /welcome-file-list struts.config.xml !-- == Global Forward Definitions == -- global-forwards forward name=/welcomepath=/controllers/welcome / /global-forwards !-- == Action Mapping Definitions == -- action-mappings action path=/welcome type= gov.treas.fms.feddebt.web.action.WelcomeAction scope=request validate=false forward name=page path=views.welcome/ /action /action-mappings tiles.def.xml definition name=standardLayout path= /WEB-INF/views/layout/standardLayout.jsp put name=title value=FedDebt/ put name=menu value=menu/ put name=header value=header/ put name=footer value=footer/ /definition !-- === -- !-- Welcome page definition -- !-- === -- definition name=views.welcome extends=standardLayout put name=body value=/WEB-INF/views/body/welcome.jsp/ /definition -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Struts welcome-file-list problem
Not sure if you saw this in an earlier post: One approach is to use the refresh META tag. This is supported by most browsers. Specifically: welcome-file-list welcome-fileindex.html/welcome-file /welcome-file-list Then, in index.html: html head titleRedirect to our home page/title META http-equiv=refresh content=0;URL=/index.doPlease click here to if you are not automatically redirected to our home page/a /head body bgcolor=#ff centerPlease a href=/index.doclick here/a if you are not automatically redirected to our home page /center /body For most all browsers this should automatically redirect them to the home page. Good luck, Kevin [EMAIL PROTECTED] on 06/26/2002 06:54:35 PM Please respond to Struts Users Mailing List [EMAIL PROTECTED] To: [EMAIL PROTECTED] cc: [EMAIL PROTECTED], [EMAIL PROTECTED] (bcc: Kevin Bedell/Systems/USHO/SunLife) Subject: Struts welcome-file-list problem We have all of our jsp's under Web-Inf. Therefore, you must call the action class to get to a web page. This all works great except for our welcome page called welcome.jsp that was built with Struts Tiles. If we go to the browser and just type http://localhost:8080/FedDebtWeb/controllers/welcome; we can get to the welcome page. If we type only http://localhost:8080/FedDebtWeb; it does not find the welcome.jsp page. Any suggestions on how to make this work? Thanks, Pete Gabriel Here are the code snippets for the different files: web.xml !-- Action Servlet Mapping -- servlet-mapping servlet-nameaction/servlet-name url-pattern/controllers/*/url-pattern /servlet-mapping !-- The Welcome File List -- welcome-file-list welcome-file/welcome/welcome-file /welcome-file-list struts.config.xml !-- == Global Forward Definitions == -- global-forwards forward name=/welcomepath=/controllers/welcome / /global-forwards !-- == Action Mapping Definitions == -- action-mappings action path=/welcome type= gov.treas.fms.feddebt.web.action.WelcomeAction scope=request validate=false forward name=page path=views.welcome/ /action /action-mappings tiles.def.xml definition name=standardLayout path= /WEB-INF/views/layout/standardLayout.jsp put name=title value=FedDebt/ put name=menu value=menu/ put name=header value=header/ put name=footer value=footer/ /definition !-- === -- !-- Welcome page definition -- !-- === -- definition name=views.welcome extends=standardLayout put name=body value=/WEB-INF/views/body/welcome.jsp/ /definition -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]