Re: error # 302 on compilation
Hi, what compiler are you using? This sounds like a jdk1.4-related issue (I had these problems with JBuilder5). The class specs have changed from 1.3.1 to 1.4, and some compilers won't allow to compile against classes that were compiled to other versions of the class spec than the current target jdk. Cheers, Ben srinivas wrote: hello, i get this error when i compile my source file. What could be the reason? Should i get the source of struts and compile? Error #: 302 : cannot access class org.apache.struts.taglib.html.ErrorsTag; no source found; must be compiled, because java.lang.Object.getClass referenced by class org.apache.struts.taglib.html.ErrorsTag has changed thanks, srinivas. -- 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]
Re: How do I use Tiles w/ iFrame
See intermixed. Cedric Struts Newsgroup (@Basebeans.com) wrote: Subject: How do I use Tiles w/ iFrame From: Matt Raible [EMAIL PROTECTED] === Simple Scenario: - I want to define a template (layout.jsp) that contains an iframe. layout.jsp iframe src=tiles:getAsString name=page/ id=window frameborder=0/iframe /layout.jsp tile-config.xml definition name=login extends=/layout.jsp put name=title.key value=login.title/ put name=heading.key value=login.heading/ put name=page value=/pages/login.jsp/ /definition /tiles-config.xml Question: I haven't been able to do with without specifying the context as a prefix for the page URL - I have to put /context/pages/login.jsp for the page value. Is there a way to get around putting the context in there? There is no way to put dynamically the context path in a definition declared in the xml file. Solutions to this situations are : * hard code the context in the xml file. Not very nice, and will cause trouble when your context will change. * Add context when you retrieve the path in the jsp : iframe src=%=request.getContextPath()%/tiles:getAsStringname=page/ ... More Complicated Scenario: - Ideally, I'd like to use the model above, but have the page value reference a URL to another definition. put name=page value=another.def/ Where another.def extends a different layout. Question: Is this possible? When I tried value=another.def, it inserted the actual page HTML after iframe src= It is not clear to me what you are really trying to do ... Real Complicated Scenario: - No answer really needed on this one... What I'm trying to accomplish is that a user will login to the application, and at this point I will set a cookie based on their role. Their role determines which sub-application they are routed too. The sub-applications have different layouts. When a user returns to the site after logging in the first time, I want to skin the login page with the look/feel of the sub-application. Here is my login.jsp at this point (This file is referenced for form-based authentication) %@ taglib uri=/WEB-INF/tiles.tld prefix=tiles % tiles:insert definition=login flush=true / I plan to do some cookie checking to swich the definition from login to a sub-app login definition. Does this sound reasonable? Or should I just attempt to use CSS and positioning to change the look and feel? The problem I have is that one sub-app uses the layout with the iframe, so the user gets the feeling that they are never leaving the page. As an example, here is a prototype, where This is a simple HTML page is a separate page that will use a different layout. http://raibledesigns.com/onpoint/interface.html The outer layout with the image will probably only have a couple definitions - 1 for the login, and 1 for a JSP/Servlet that renders dynamic pages based on other information. Have you check new examples coming with Tiles, especially the dynamic skin layout ? http://localhost:8080/tiles-doc/examples/mySkinSettings.do I'm probably just blabbing cause I'm tired, but when you're a team of one, some times you just need to get this stuff in writing. Thanks, Matt -- 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]
Re: error # 302 on compilation
Hi, if you get these two working together, let me know ;-) I got so frustrated over this that I eventually skipped to neatbeans (which I like much better now). JBuilder looks at the class spec version of compiled classes, and complains if it does not match (which for me results in the message that it wants the sources of java.lang.Object to recompile it - obviously you have gotten a step further). It is now two months back that I tried to find a solution for that, but I haven't. You should be fine with the compiler as provided by the J2SDK. Cheers, Ben srinivas wrote: thanks ben, i am using jdk1.4.0 with jbuilder5. regards, srinivas. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Save/Update data to XML-File
Hi, in the struts-example the user data can be read with the help of a hashtable an a struts digester. But whats about updating the data in the xml-file after user changes? The digester can't do. Is there any possibility with struts to update the hastable data in the xml-file comfortable. Or is there a need to do this outside with e.g. jdom and xerces not so comfortable? Has somebody an advice or an code example? Thanks Susanne -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Newbie question about Tiles suitability.
Hi, I just got told I have to create a web site similar to myYahoo where the user can customize what they want to view on the screen. You know the type, where you can pick and choose from a number of categories and a page is custom created for you. Is this a job for the Tiles framework? Thanks for any help. Regards, Alex -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Struts/Tomcat problem
I get the following error when I'm trying to view a page in my application: [EMAIL PROTECTED]: Apache Tomcat/4.0.2 - HTTP Status 503 - Servlet ActionServlet is currently unavailable type Status report message Servlet ActionServlet is currently unavailable description The requested service (Servlet ActionServlet is currently unavailable) is not currently available Does anyone have any clues to why this happens? thanks ida -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Logical OR, AND etc....in Struts
Hi All, Can you please let me know how to write Logical OR, AND etc in the Jsp pages using struts Logic template. Thanks and Regds Tanmay -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: reg Forward action
Hi Mikael, Great. That worked ! Thank you very much. Ramana -Original Message- From: Mikael Eriksson [mailto:[EMAIL PROTECTED]] Sent: Saturday, March 23, 2002 2:26 PM To: Struts Users Mailing List Subject: Re: reg Forward action Hi Since the perform method should take an ActionForm as its form parameter and not an ReferralForm your perform is probably not called at all... change the declaration and cast the form to a ReferralForm inside. If you do get inteo the perform method, try to put in some more trace printouts to see that you are not returning null or something like that. Regards Mikael At 17:58 2002-03-22 -0500, you wrote: Hi I am trying to forward request from my Action class to a JSP (which is configured for forward aciton in struts-config.xml). When i submit the page i see the action is fired but it is not forwarding the request to specified JSP. since i could see no output on my browser . When i see my jsp_servlet folder the corresponding class file for the forwarded JSP is not found. public final class ReferralLoginCompleteAction extends Action { public ActionForward perform(ActionMapping mapping, ReferralForm form, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { -- 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]
Tiles and Cactus
I am trying to test my site using Cactus and HTTPUnit and am having problems. The site works fine when Tomcat is started and a human navigates the site. In other words the /test/do/home/home resolves and the template definition for tiles is rendered. But under Cactus I get 500 errors for any request I make. The action is being triggered for the mapping and seems to fail in forwarding to 'success' which is a template definition. The action mapping is below as is the template definition. The Cactus and HTTPUnit tests worked prior to migrating to Struts 1.1 b1 and Tiles and have not been modified. I was using Struts 1.0 and Components when the tests worked. I am using Tomcat 4.0.3 standalone on Win2k. Any advice would be welcome. Thanks 2002-03-25 07:07:23 StandardHost[localhost]: Mapping request URI '/test/do/home/home' 2002-03-25 07:07:23 StandardHost[localhost]: Mapped to context '/test' 2002-03-25 07:07:23 StandardWrapperValve[action]: Servlet.service() for servlet action threw exception java.lang.NullPointerException at org.apache.struts.action.RequestProcessor.getServletContext(RequestProcessor .java:1030) at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcesso r.java:114) at org.apache.struts.action.RequestProcessor.processActionForward(RequestProces sor.java:408) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:269) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1109) at com.holmansite.controller.MyActionServlet.process(MyActionServlet.java:65) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:452) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application FilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh ain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja va:243) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5 66) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja va:190) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5 66) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase .java:475) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5 64) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2343) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180 ) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5 66) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve. java:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5 64) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170 ) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5 64) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5 64) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java :174) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5 66) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java: 1012) at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1107 ) at java.lang.Thread.run(Thread.java:484) Action Mapping action path=/home/home type=com.holmansite.controller.WelcomeAction scope=request validate=false input=/pages/home/homePage.jsp forward name=success path=home.pagedef/ /action Template definition definition name=home.pagedef path=/template.jsp put name=title value=Holman Family Home Page /
Re: Multi Indexed Nested properties samples?
Annie MUTATOR You will need the mutator method obviously `public void setName( String )' PREFERS INTERFACES Instead of using java.util.Vector, prefer to using an Java Collection interface java.util.List. public List getSubscriptionList() { List list = new ArrayList(); // fill her up return list; } Pros; you change the type of ``List'' in the future. Suppose a better list appears tomorrow Cons: no problem DELEGATE if you have a business object or DAO consider delegation to access. Instead copying the accessor / mutators of the DAO to the ActionForm. Let the DAO be a delegate because Struts supports ``nested bean properties'' out of the box, public class CreditDetailDAO { public String getAuthority() { .. .} } public class Employee extends ActionForm { // Delegate it! private CreditDetail cred; public CreditDetailDAO getCreditDetail() { return cred; } public void setCreditDetail( CreditDetailDAO c ){ this.cred = c }; } Then JSP can be written like so bean:write name=obj property=creditDetail.authority / -- Peter Pilgrim ++44 (0)207-545-9923 Swamped under electronic mails Message History From: Annie Chang [EMAIL PROTECTED] on 24/03/2002 16:39 PST Please respond to Struts Users Mailing List [EMAIL PROTECTED] To:Struts Users Mailing List [EMAIL PROTECTED] cc:[EMAIL PROTECTED]; [EMAIL PROTECTED] Subject:Re: Multi Indexed Nested properties samples? Arron, I want to let the user modify all informations in one page like this way: * | User Information: | Name: Telephone:_ | Email:_Address:__ | | Subscriptions: | Host User Name PasswordType Autoconnect | ___ __ | ___ __ | ___ __ | ___ __ | | Interested Webs: | Catalog NameURL | ___ _____ | ___ _____ | ___ _____ | ___ _____ | | |Save *-- --CUT-- -- This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Application scope beans
John: The following snipet of code should handle what you need: Object someObject = (Object)servlet.getServletContext().getAttribute(nameOfObjectHandleInApplic ation); The reference to Object above would of course be replaced with the class name of the object you are trying to access. Also, the code above assumes you are calling the servlet from within an Action. Please let me know if this works for you. ** Juan Alvarado Internet Developer -- Manduca Management (786)552-0504 [EMAIL PROTECTED] AOL Instant Messenger: [EMAIL PROTECTED] -Original Message- From: John Jones [mailto:[EMAIL PROTECTED]] Sent: Saturday, March 23, 2002 11:00 AM To: Struts Users Mailing List Subject: Application scope beans Does anyone out there know how to access objects in application scope from a servlet? We want to have a startup servlet that puts a bunch of beans in application scope on application server startup. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Help with: Cannot find bean org.apache.struts.taglib.html.BEA N in scope null
Hi Scott, Part of the purpose of my action is to populate the form with some information from the database, then let the user fill in some more information and run a followup action to handle the user input. I am using the same action class in both cases, but with the parameter set differently to let me know what I need to do. If I remove the input form bean, won't that get rid of the data which I want to present to the user? (I'm not able to try it right now, so I'm just wondering.) Thanks for your response, I'll look at it tonight. Mike -Original Message- From: Barr, Scott [IBM GSA] [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 1:27 AM To: 'Struts Users Mailing List' Subject: RE: Help with: Cannot find bean org.apache.struts.taglib.html.BEA N in scope null Hi I have come across this problem before when the input FormBean is the same type as the output FormBean for an Action. Removing the input FormBean at the end of the Action (when you tidy up old objects) will remove the bean you are adding to the Requst or Session. Scott -Original Message- From: Annie Chang [SMTP:[EMAIL PROTECTED]] Sent: Monday, 25 March 2002 3:48 pm To: Struts Users Mailing List Subject: Re: Help with: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null Please make sure Struts lib(all the jar file) are in your application's classpath. Simply, you can copy all jar files of Struts to your application's \WEB-INF\lib . It should be OK. - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, March 24, 2002 8:35 PM Subject: Help with: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null I'm getting an error (Cannot find bean org.apache.struts.taglib.html.BEAN in scope null) when I attempt to use one of my ActionForm properties in the JSP file. I've looked the struts-config.xml over 100 times and I can't figure out what I'm doing wrong. Here are the pertinent portions of my struts-config.xml. If anyone sees my problem, I would appreciate some help. Form bean: form-bean name=pharmacyPeriodSelectForm type=com.omnicare.purchasing.araging.webapp.PharmacyPeriodSelectForm / Action path: !-- Enter the region name -- action path=/regionEntry name=pharmacyPeriodSelectForm type=com.omnicare.purchasing.araging.webapp.PharmacyPeriodSelectAction scope=request validate=false input=/pages/AR_pharmacy_period.jsp parameter=regionEntry forward name=success path=/pages/AR_pharmacy_period.jsp / /action The PharmacyPeriodSelectAction executes fine. When I return the success forward, I get the error. Thanks for your help, Mike Witt The full error message is: javax.servlet.ServletException: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextI mp l.java:459) at pages._0002fpages_0002fAR_0005fpharmacy_0005fperiod_0002ejspAR_0005fpharma cy _0005fperiod_jsp_29._jspService(_0002fpages_0002fAR_0005fpharmacy_0005fper io d_0002ejspAR_0005fpharmacy_0005fperiod_jsp_29.java:167) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet. ja va:130) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet. ja va:282) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatcher Im pl.java:222) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherIm pl .java:162) at org.apache.struts.action.ActionServlet.processActionForward(ActionServlet. ja va:1758) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1595) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:491) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java: 81 2) at
RE: Help with: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null
What does the jsp look like? dave -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 9:56 AM To: [EMAIL PROTECTED] Subject: RE: Help with: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null Annie, The struts.jar is already in \WEB-INF\lib. I have other actions which proceed this one that work just fine. I even have other html tags in this jsp which seem to work ok. For example, I have a html:form which is accepted. But as soon as I put in the html:text with the property attribute to refer to one of my form bean attributes, it gets the error. Thanks, Mike -Original Message- From: Annie Chang [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 12:18 AM To: Struts Users Mailing List Subject: Re: Help with: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null Please make sure Struts lib(all the jar file) are in your application's classpath. Simply, you can copy all jar files of Struts to your application's \WEB-INF\lib . It should be OK. - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, March 24, 2002 8:35 PM Subject: Help with: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null I'm getting an error (Cannot find bean org.apache.struts.taglib.html.BEAN in scope null) when I attempt to use one of my ActionForm properties in the JSP file. I've looked the struts-config.xml over 100 times and I can't figure out what I'm doing wrong. Here are the pertinent portions of my struts-config.xml. If anyone sees my problem, I would appreciate some help. Form bean: form-bean name=pharmacyPeriodSelectForm type=com.omnicare.purchasing.araging.webapp.PharmacyPeriodSelectForm / Action path: !-- Enter the region name -- action path=/regionEntry name=pharmacyPeriodSelectForm type=com.omnicare.purchasing.araging.webapp.PharmacyPeriodSelectAction scope=request validate=false input=/pages/AR_pharmacy_period.jsp parameter=regionEntry forward name=success path=/pages/AR_pharmacy_period.jsp / /action The PharmacyPeriodSelectAction executes fine. When I return the success forward, I get the error. Thanks for your help, Mike Witt The full error message is: javax.servlet.ServletException: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImp l.java:459) at pages._0002fpages_0002fAR_0005fpharmacy_0005fperiod_0002ejspAR_0005fpharmacy _0005fperiod_jsp_29._jspService(_0002fpages_0002fAR_0005fpharmacy_0005fperio d_0002ejspAR_0005fpharmacy_0005fperiod_jsp_29.java:167) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja va:130) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja va:282) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatcherIm pl.java:222) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl .java:162) at org.apache.struts.action.ActionServlet.processActionForward(ActionServlet.ja va:1758) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1595) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:491) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:81 2) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:758) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java:213) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501) at java.lang.Thread.run(Thread.java:484) Root cause: javax.servlet.jsp.JspException: Cannot find bean org.apache.struts.taglib.html.BEAN in scope null at org.apache.struts.util.RequestUtils.lookup(RequestUtils.java:493) at
when does STRUTS call reset() on form beans ?
Does it depend on scope of a session bean ? thanx in advance Maris Orbidans -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Tiles question: Is it possible to insert a ComponentDefinition into a Tile context dynamically?
Hello, If you are in a tile controller, you don't have to create a new ComponentDefinition, you can set the attributes of the current tiles (because you are in the controller). To add / overload an attribute in the context, do something like : String attribute = (String)context.getAttribute(attributeName); attribute = new value; context.setAttribute(attributeName, attribute); To add a list, create the list, add elements, and add the list to context. You can overload a previously defined list. Do not modify content of an existing list, because it is shared between inherited instances. : List list = new java.util.ArrayList(); list.add( a value ); list.add( another value); context.setAttribute(listAttributeName, list); Hope this help, Cedric P.S. : The DefinitionsUtil.setActionDefinition( aDefinition ); is to be used when you are inside a Struts action called by Struts mechanism. It has not effect when used inside a tile controller Chris Cool wrote: Hi, I have a tile that reads items from a PutList list and then inserts each item into the current page. struts_logic:iterate id=item name=itemList scope=page type=String tiles:insert name='%=item%' flush=true/ /struts_logic:iterate When the items in the list are tiles defined in my tileDefinitions.xml file, the tiles are inserted into my JSP correctly. However, I want to dynamically create a tile definition and insert it into the page context. I am generating the ComponentDefinition in my tile controller and accessing the itemList where I add the name of the dynamically generated definition: /* get the item list and insert new tile def into it */ ArrayList itemList = (ArrayList)context.getAttribute(itemList); if (itemList != null) { HashMap map = new HashMap(); map.put(name, newtarget); map.put(link, newtarget.do); ComponentDefinition newItem = new ComponentDefinition(new.item, /mytiles/simpleItem.jsp, map); DefinitionsUtil.setActionDefinition( request, breadCrumbItem ); itemList.add(new.item); } In my tile, the itemList contains the new.item entry, but it does not appear to find the ComponentDefinition I created. Thanks for you help. Chris -- 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]
Re: Newbie question about Tiles suitability.
Hello, Tiles can certainly help you in designing such site. It is one of the goals that I had in mind when I have developed Tiles. The Tiles new feature examples can be a starting point for such development. Check my Portal and my Menu. Cedric Alex Colic wrote: Hi, I just got told I have to create a web site similar to myYahoo where the user can customize what they want to view on the screen. You know the type, where you can pick and choose from a number of categories and a page is custom created for you. Is this a job for the Tiles framework? Thanks for any help. Regards, Alex -- 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]
Re: How to use role in struts - tiles
Hello, If memory serve, there is a bug when using the role attribute in the put tag defined in an xml file. In other words, it doesn't work ;-( . I increase the priority for this bug. Sorry for any inconvenient. Cedric Reynaldo Timonera wrote: Hi, We're using tiles in our proejct. It's great! We wanted to use the role attribute of the put tag, have anyone used this before? How do I set the user role to something and then have the put tag in tiles definition work. Thanks for your help, Reynaldo -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Extension issues
Hello, It is something that Struts have to improve. The new plugin capabilities is the first step, but doesn't solve everything yet. What you can do is to provide your own ActionServlet implementation combining features from the extensions you need. Extend one of the actionServlet (the more complicated one ;-) ), and add missing stuff from others. From Tiles and Struts1.0, you need to pick up the init method, and catch any call to RequestDispatcher.include() and RequestDispatcher.forward(). Check Tiles servlet implementation : processActionForward() and processValidate() are copies of original Struts implementation, except the call to include which is modify to a call to a new method processForward(). If you use Struts1.1, you need to provide a RequestProcessor. Here again, check code from the needed extensions. Tiles simply override methods doInclude() and doForward(). Hope this help, Cedric Antony wrote: Hi: I think Struts is coming up with several interesting extensions: -Tiles -Validator -Workflow The bad thing is that you have to use appropriate ActionServlet implementation for each extension. Therefore you cannot, theoratically, use tiles for multiple view reppresentation, validator for form calidation and control flow with workflow extension at the same time. Did I misunderstood anything? If not, is there a way to work around? Regards, Antony -- 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]
RE: getting validation errors on initial display of a form
In the struts-config.xml try setting validate=false for the initial action names and then set it to true for the submit action on the form of the names.jsp . This will disable the validate() call when the form is first initialized : action-mappings action path=/app/names type=com.starrcs.app.SANameAction name=nameForm scope=request validate=false input=/pages/app/Name.jsp forward name=continue path=/pages/app/Name.jsp/ /action -Original Message- From: Dick Starr [mailto:[EMAIL PROTECTED]] Sent: Monday, January 21, 2002 9:20 PM To: struts-user Subject: getting validation errors on initial display of a form I am new to Struts and am using Ted's sample logon app as my basis for learning. His part works fine. I added a new jsp page that contains two fields, created a form bean an action form with validation edits. My problem is that when I execute my form via http://localhost:8080/starrd/app/names.do I get validation errors appearing immediately (before I enter any data in the form). I can't believe thats normal: I must be doing something wrong. Thanks in advance for the help. Dick Starr Here's the pertinent parts of my struts-config: form-beans form-bean name=nameForm type=com.starrcs.app.SANameForm/ global-forwards forward name=names path=/app/names.do/ action-mappings action path=/app/names type=com.starrcs.app.SANameAction name=nameForm scope=request validate=true input=/pages/app/Name.jsp forward name=continue path=/pages/app/Name.jsp/ /action Here's my Name.jsp: !-- Name.jsp 2002/01/21 RJS -- %@ page language=java % %@ taglib uri=/tags/struts-bean prefix=bean % %@ taglib uri=/tags/struts-html prefix=html % htmlheadtitlebean:message key=app.name.title//title/head html:base/ body html:errors/ html:form action=/app/names focus=name table border=0 width=100% trth align=rightName:/thtd align=left html:text property=name//td /tr trth align=rightAddress line one:/thtd align=left html:text property=addr1//td tr td align=righthtml:submit property=submit value=Submit//td td align=lefthtml:reset//td /tr /table /html:form /body /html %-- Allow user to submit username and password to logon action. --% Here's the pertinent parts of SANameAction.java: public final class SANameAction extends Action { public ActionForward perform(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { // Obtain fields from web tier String name = ((SANameForm) form).getName(); String addr1 = ((SANameForm) form).getAddr1(); // Log this event, if appropriate if (servlet.getDebug() = SAConstants.DEBUG) { StringBuffer message = new StringBuffer(SANameAction: name = ); message.append(name); message.append(, addr1 = ); message.append(addr1); servlet.log(message.toString()); } // Forward control to the welcome URI // specified in the configuration. return (mapping.findForward(SAConstants.WELCOME)); } } // End SANameAction Here's the pertinent parts of SANameForm.java: public final class SANameForm extends ActionForm { // Instance Variables private String name = null; private String addr1 = null; // Properties public String getName() { return (this.name); } public void setName(String name) { this.name = name; } public String getAddr1() { return (this.addr1); } public void setAddr1(String addr1) { this.addr1 = addr1; } // Public Methods public void reset(ActionMapping mapping, HttpServletRequest request) { setName(null); setAddr1(null); } public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) { ActionErrors errors = new ActionErrors(); if ((name == null) || (name.length() 1)) errors.add(name, new ActionError(app.error.name.required)); if ((addr1 == null) || (addr1.length() 1)) errors.add(addr1, new ActionError(app.error.addr1.required)); return errors; } } // End SANameForm When I first execute the form via http://localhost:8080/starrd/app/names.do I immediately (before entering any data or executing the submit button) I get validation errors displayed for name and addr1 and get the following in my log file: 2002-01-21 20:19:19 action: Processing a GET for /app/names 2002-01-21 20:19:19 action: Looking for ActionForm bean under attribute 'nameForm' 2002-01-21 20:19:19 action: Creating new ActionForm instance of class 'com.starrcs.app.SANameForm' 2002-01-21 20:19:19 action: Storing instance under attribute 'nameForm' in scope 'request' 2002-01-21 20:19:19 action: Populating bean properties
Re: Struts 1.1 beta Sample DB app. = FREE T-Shirt - Struts Menu p roblem
Subject: Re: Struts 1.1 beta Sample DB app. = FREE T-Shirt - Struts Menu p roblem From: Vic Cekvenich [EMAIL PROTECTED] === I just wanted to clear up that my appp and menu demo works fine, it was Jon's another example he had questions. Again the sample demo app does 1.1, Curd, tiles, etc. from my training class. www.basebeans.com/downloads.jsp. Vic Jon.Ridgway wrote: Hi Vic, Many thanks for the response; I am using struts 1.1, hence the plugin stuff in struts-config mentioned below, but I still appear to get the error mentioned below. Any ideas? I noticed you had an extra plugin at the bottom of your struts-config, you mention a bug, could this be related or is it a tiles specific bug? Jon. -Original Message- From: Struts Newsgroup [mailto:[EMAIL PROTECTED]] Sent: 21 March 2002 14:55 To: [EMAIL PROTECTED] Subject: Re: Struts 1.1 beta Sample DB app. = FREE T-Shirt - Struts Menu p roblem Subject: Re: Struts 1.1 beta Sample DB app. = FREE T-Shirt - Struts Menu p roblem From: Vic Cekvenich [EMAIL PROTECTED] === Struts menu is on Source Forge (the new version of Struts - menu uses Struts 1.1 services, like Validator does). So you have to use it in Struts 1.1 that uses service plug ins. (For version 1.0 you hat to use the Struts-menu servlet). Look at my sample on how to make the Struts-menu a service (in Struts-config) or download the menu sample from Source Forge. Vic Jon.Ridgway wrote: Hi Vic, I noticed that you are using a version of the struts menu that uses the plug-in functionality. Couple of questions: 1) Where did you get this version, specifically the version I have doesn't have a com.fgm.web.menu.MenuPlugIn class. 2) Do you know why I might be getting the error: javax.servlet.ServletException: Failure initializing struts-menu: Error parsing resource file: /WEB-INF/menu-config.xml nested exception is: Stopping after fatal error: File null not found. at com.fgm.web.menu.MenuPlugIn.init(Unknown Source) etc, etc. On my web app. I have placed the version of struts-menu.jar in my WEB_INF/lib along with tld. I have added the plugin entry to struts-config which points to /WEB-INF/menu-config.xml. So I'm not clear which file entry is null. Any pointers much appreciated Jon. -Original Message- From: Struts Newsgroup [mailto:[EMAIL PROTECTED]] Sent: 21 March 2002 04:40 To: [EMAIL PROTECTED] Subject: Struts 1.1 beta Sample DB app. = FREE T-Shirt Subject: Struts 1.1 beta Sample DB app. = FREE T-Shirt From: Vic Cekvenich [EMAIL PROTECTED] === I just placed a new version of the WebPIM on the downloads page. (It uses the latest build of Struts 1.1 beta). First 10 people that deploy it, get a FREE shirt (in continental US). 1. You must send at least one line to this newsgroup or MVC newsgroup on how to deploy tip. (MVC is on news.basebeans.com in a newsreader) 2. Send me ([EMAIL PROTECTED]) a screen shot of the app running (and your mailing address). Thanks, Vic Major changes include factoring out DAO out of baseBeans/FormBeans Also, this applications demonstrates the following: * DB CRUD * How to fork the action so it dispatches to right execute * Use of factoring out DAO from FormBean so you can use any data source (even EJB) * Validation * Messages * Master/Detail * Drill Down * Iteration * Formatting # and date * Collections options drop downs * Use of menu navigation using Struts menu to factor out navigation * Use of Portal Tiles - Navigation -- 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] -- 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] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
(further ?) Re: When does STRUTS call reset() on form beans ?
Maris Orbidans asked: Does it depend on scope of a session bean ? On a related note, I have a simple form with two text fields, a regular ol' form bean, and an action. If the action doesn't validate, it goes back to the form, and the form values are gone. Did I miss something? I thought that the form values were supposed to remain persistent. I've temporarily put the form bean into the session, but of course that causes problems if they visit the same form twice for different reasons as the original data is still there. Just curious, Dave -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Tiles and Cactus
Cedric I started Tomcat and then the tests same results - when done I could no longer navigate the site manually - same error Cactus is generating. I restarted could get in and navigate, no problem, ran the tests and broke it. I think I have isolated the issue - I ran HTTPTest cases first and they worked!! I am using an extension to Cactus called StrutsTest and it is documented for Struts 1.0. That could be my issue. I will write a test using only cactus and see it I get the same result. The StrutsTest could be depending on something or changing something based on Struts 1.0 specs. http://strutstestcase.sourceforge.net/ Thanks for your time. Cal -Original Message- From: Cedric Dumoulin [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 11:41 To: Holman, Cal Subject: Re: Tiles and Cactus I continue this discution off the mailing list to avoid disturbing others people. Can you / have you try to : 1. start web server and web application without starting cactus 2. access manually some ot your pages 3. then start cactus Unfortunately, I don't know much about Cactus. But the message indicate that the servlet attribute is not set. Tiles is actually initialized after plugins. I will provide a plugin to initialize it. If you want, you can do it yourself very easily : just implement a plugin calling the tiles initialization method ( DefinitionsUtil.createDefinitionsFactory(getServletContext(), servlet.getServletConfig()); ). What is strange is that your trace indicate that TilesRequestProcessor is initialized. But this initialization use the servlet attribute. After that, a request can't find it ! Holman, Cal wrote: Cedric These are the messages from the startup of Tomcat initializing the application. I initialize Log4J and some init parameters in my init routine and then the validator plug in is being initialized. The tests are submitted after successful launch of Tomcat - I am using Ant 1.4 and a Cactus task to initiate. Looks like Tiles is initiated after plugins. But all the init stuff is over prior to the Cactus request. From Tomcat log: 2002-03-25 07:06:48 StandardWrapper[/test:default]: Loading container servlet default 2002-03-25 07:06:48 default: init 2002-03-25 07:06:48 action: init 2002-03-25 07:06:52 action: Tiles definition factory loaded 2002-03-25 07:06:52 StandardWrapper[/test:invoker]: Loading container servlet invoker 2002-03-25 07:07:02 ServletRedirector: init 2002-03-25 07:07:02 ServletRedirector: init 2002-03-25 07:07:03 ServletRedirector: Tiles definition factory loaded for processor 2002-03-25 07:07:03 StandardHost[localhost]: Mapping request URI '/test/ServletRedirector/' 2002-03-25 07:07:03 StandardHost[localhost]: Mapped to context '/test' Ant Console: [java] log4j: Adding appender named [XMLFile] to category [root]. [java] 2002-03-25 07:06:49,639 INFO [main] controller.MyActionServlet (MyActionServlet.java:120) - Log initialized [java] 2002-03-25 07:06:49,669 INFO [main] controller.MyActionServlet (MyActionServlet.java:149) - WhatsNew initialized C:\tomcat\webapps\test\WEB-INF\WhatsNewItems.xml [java] 2002-03-25 07:06:49,679 INFO [main] controller.MyActionServlet (MyActionServlet.java:167) - XML initialized C:\tomcat\webapps\test\WEB-INF\log4j_output.xml [java] 2002-03-25 07:06:50,880 INFO [main] impl.Log4JCategoryLog (Log4JCategoryLog.java:148) - Loading validation rules file from '/WEB-INF/validator-rules.xml' Cal -Original Message- From: Cedric Dumoulin [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 10:29 To: Struts Users Mailing List Subject: Re: Tiles and Cactus Checking the errors trace, it appear that struts.action.RequestProcessor has no or has loose its reference to the servlet. This reference is initialized by a call to init(...) which is done when servlet is initialized. Maybe cactus calls Struts before its complete initialization ? Cedric This can be due to Holman, Cal wrote: I am trying to test my site using Cactus and HTTPUnit and am having problems. The site works fine when Tomcat is started and a human navigates the site. In other words the /test/do/home/home resolves and the template definition for tiles is rendered. But under Cactus I get 500 errors for any request I make. The action is being triggered for the mapping and seems to fail in forwarding to 'success' which is a template definition. The action mapping is below as is the template definition. The Cactus and HTTPUnit tests worked prior to migrating to Struts 1.1 b1 and Tiles and have not been modified. I was using Struts 1.0 and Components when the tests worked. I am using Tomcat 4.0.3 standalone on Win2k. Any advice would be welcome. Thanks 2002-03-25 07:07:23 StandardHost[localhost]: Mapping request URI '/test/do/home/home' 2002-03-25 07:07:23 StandardHost[localhost]: Mapped to context
Re: Pass parameters between Action classes
Hi Enrigue. Enrique Rodriguez [EMAIL PROTECTED] writes: When can i get the paremeters from it??? Only When I'm in a JSP? I Attach my example. Please take a look. You seem to be confusing attributes with parameters. They're not the same thing. You're calling setAttribute in Action1 but then in Action2 you're trying to retrieve the attribute using getParameter. You must use getAttribute instead. All of the scope objects (page, application, session, request) provide an interface to allow you to get and set attributes. Only the request object has parameters in addition to attributes. These parameters are the ones submitted by the client's browser. Parameters are immutable -- you can get them but you can't set them -- so that you can always tell exactly what was posted from the client. Make sense? -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
why send receipt requests in mail list emails?
Okay, this is a bit off-topic, but as it involves core mail-list netiquette, I've found it necessary to post something, so here goes: There is absolutely NO reason to issue a receipt request when you send an email to mail lists, as it serves no function whatsoever except to annoy certain people (namely, me) who are trying to scan through the gazillion emails they get a day very quickly without little windows popping up. If someone understands your plight and wishes to respond, they will. If they don't, they won't, and even if they do issue a receipt response, it just means they saw your email and didn't have an answer for you, so you gain nothing. More to the point, I will definitely NOT respond to any email that has a receipt request, nor will some like-minded others I'm sure, so you're just shooting yourself in the foot if you issue one. Your choice, as always, and happy emailing to ya... regards, Joe Barefoot P.S. I realize that for those of us using other email clients (I use Outlook mostly), this is not an issue, so kindly ignore my barbed comments. :) -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Pass parameters between Action classes
Hi Jim, Thank you very much, you are completely true. The example now works I was thinking that getParameter and getAttribute was the same. I thought the diference between theirs was that getParameter get a String and getAttribute an Object. ;-) I hope this could help another newbies like me. Regards, Enrique. _ Enrique Rodriguez Lasterra De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]En nombre de Jim Crossley Hi Enrigue. Enrique Rodriguez [EMAIL PROTECTED] writes: When can i get the paremeters from it??? Only When I'm in a JSP? I Attach my example. Please take a look. You seem to be confusing attributes with parameters. They're not the same thing. You're calling setAttribute in Action1 but then in Action2 you're trying to retrieve the attribute using getParameter. You must use getAttribute instead. All of the scope objects (page, application, session, request) provide an interface to allow you to get and set attributes. Only the request object has parameters in addition to attributes. These parameters are the ones submitted by the client's browser. Parameters are immutable -- you can get them but you can't set them -- so that you can always tell exactly what was posted from the client. Make sense? -- 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]
[Fwd: [MVC-Programmers@basebeans.com] [Struts Tips] #2 - Use DispatchAction to organize related operations]
To get these articles 2 times a week, the only place you can get these articles is at www.basebeans.com/forums.jsp (and sign up at the bottom link) for the BaseBeans MVC mail list. (also daily Java News feed at www.strutsplus.com/news.jsp) hth, Vic Original Message Subject: [[EMAIL PROTECTED]] [Struts Tips] #2 - Use DispatchAction to organize related operations Date: Mon, 25 Mar 2002 09:11:07 -0500 From: Ted Husted [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] Newsgroups: MVC-Programmers References: [EMAIL PROTECTED] Any software application is defined by the things it can do for you. In a Struts Web application, the things an application does is usually defined by its action-mapping elements. An action-mapping is designed to be the target of an HTML form, and is often used with hyperlinks as well. Each action-mapping can specify a Struts Action class as its handler. In larger applications, developers can find themselves managing dozens or even hundreds of Action classes. In practice, many of these Action classes handle related operations, often evidenced by their name. A package might include separate RegCreate, RegSave, and RegDelete Actions, which just perform different operations on the same RegBean object. Since all of these operations are usually handled by the same JSP page, it would be handy to also have them handled by the same Struts Action. A very simple way to do this is to have the submit button modify a field in the form which indicates which operation to perform. SCRIPT function set(target) { document.forms[0].dispatch.value=target; } /SCRIPT html:hidden property=dispatch value=error/ html:submit onclick=set('save');SAVE/html:submit html:submit onclick=set('create');SAVE AS NEW/html:submitl html:submit onclick=set('delete);DELETE/html:submit Then, in the Action you can setup different methods to handle the different operations, and branch to one or the other depending on which value is passed in the dispatch field. String dispatch = myForm.getDispatch(); if (create.equals(dispatch)) { ... if (save.equals(dispatch)) { ... The Struts Dispatch Action is designed to do exactly the same thing, but without messy branching logic. The base perform method will check a dispatch field for you, and invoke the indicated method. The only catch is that the dispatch methods must use the same signature as perform. This is a very modest requirement, since in practice you usually end up doing that anyway. To convert an Action that was switching on a dispatch field to a DispatchAction, you simply need to create methods like this public ActionForward create(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { ... public ActionForward save(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { ... Cool. But do you have to use a property named dispatch? No, you don't. The other step is to specify the name of of the dispatch property as the parameter property of the action-mapping. So a mapping for our example might look like this: action path=/reg/dispatch type=app.reg.RegDispatch name=regForm scope=request validate=true parameter=dispatch/ // Which parameter to use If you wanted to use the property o instead, as in o=create, you would change the mapping to action path=/reg/dispatch type=app.reg.RegDispatch name=regForm scope=request validate=true parameter=o/ // Look for o=dispatchMethod Again, very cool. But why use a JavaScript button in the first place? Why not use several buttons named dispatch and use the values to specify the operation. You can, but the value of the button is also its label. This means if the page designers want to label the button something different, they have to coordinate with the Action programmer. Worse, localization becomes virtualy impossible. If you prefer not to use JavaScript buttons, you can use the DispatchLookup Action instead. This works much like the DispatchAction, but requires more setup. We'll explore the DispatchLookup Action in Tip #3. HTH, Ted. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: why send receipt requests in mail list emails?
Good point. There is no reason to ask for a receipt request when sending email to mail lists. Looks like I'm guilty of that last night. I completely understand your dilemma. All those extra windows can get tiresome. I feel the same way about people who post in formats other than plain text, those who post half baked questions along with their unwarranted entire stack traces. These types of messages are usually ignored by me as well. Still, thems the breaks. It'll probably only get worse. Anthony -Original Message- From: Joseph Barefoot [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 10:11 AM To: Struts Users Mailing List; Netbeans Users Subject: why send receipt requests in mail list emails? Okay, this is a bit off-topic, but as it involves core mail-list netiquette, I've found it necessary to post something, so here goes: There is absolutely NO reason to issue a receipt request when you send an email to mail lists, as it serves no function whatsoever except to annoy certain people (namely, me) who are trying to scan through the gazillion emails they get a day very quickly without little windows popping up. If someone understands your plight and wishes to respond, they will. If they don't, they won't, and even if they do issue a receipt response, it just means they saw your email and didn't have an answer for you, so you gain nothing. More to the point, I will definitely NOT respond to any email that has a receipt request, nor will some like-minded others I'm sure, so you're just shooting yourself in the foot if you issue one. Your choice, as always, and happy emailing to ya... regards, Joe Barefoot P.S. I realize that for those of us using other email clients (I use Outlook mostly), this is not an issue, so kindly ignore my barbed comments. :) -- 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]
RE: Object Mapping w/ Struts?
I, for one, would recommend an EJB solution w/ JBoss if you're going for a full object model of the database. There are a couple of ways of migrating to EJB, but any of them are going to involve some work and learning a little about EJB containers and JNDI. There is a learning curve, but I thought the EJB model to be relatively easy to learn myself. Going EJB can slow an application down, it's true, but it all depends on your situation. If you have a small application with a low number of users, the overhead of EJB may negatively impact performance versus a non-EJB solution. However, for large applications/large number of concurrent users, you can't beat JBoss for its thread-pooling, object caching, transaction management, and other wonderful capabilities. A large amount of the slow-down people report with EJB is due to heavy use of Entity beans (the components that form the object data model in EJB), particularly using many fine-grained Entity objects to model the data. This is bad, since retrieving even a small data-set requires the instantiation of many objects, which obviously slows down performance. Many people do not use Entity beans at all, preferring to employ Stateless Session beans (which have great performance) to execute SQL statements to grab data and return values, or populate serializable value objects with the data and return those instead. If you wanted a (relatively) quick solution, you could use Container Managed Persistence (CMP) Entity beans to model the data you already have in tables. Each Entity Class would have field names that correspond to the columns in your table, with corresponding setXXX() and getXXX() methods in the Entity Class. You could then configure the EJB and JBoss deployment descriptors to use your pre-existing database and table names, and JBoss would take care of loading/storing data between the Entity bean and the database. This approach would assume that you wish a 1-to-1 mapping between tables and object types in your system. Check out the JBoss mail list archives for postings by people who have attempted this, as I'm sure there are some gotchas involved. Since you already appear to have some value objects created, you could go with the Bean Managed Persistence (BMP) route, which means your Session beans would execute SQL statements against your database, and use the results to populate value objects, which are returned to the front-end parts of your application. The Session beans could also have methods that accept these value objects as parameters, for adding new rows or updating all data for a row in your table. You can, of course, have single-value setXXX() and getXXX() methods too, backed by SQL statements. This approach involves more custom coding than CMP, but you can manage the data model however you like and directly control when and how objects are instantiated. happy coding, Joe Barefoot -Original Message- From: James A. Hillyerd [mailto:[EMAIL PROTECTED]] Sent: Saturday, March 23, 2002 2:15 AM To: Struts Users Mailing List Subject: Object Mapping w/ Struts? I am looking for an object-mapping (to sql relational DB) solution for Struts. I have a medium sized database application which I've developed in struts. (around 25 tables in PostgreSQL) I've been using a home-brew lightweight data-access bean system -- using perl scripts to generate beans that interact with the database. The java source these scripts generate need a lot of manual editing, so making changes to the object model can be a nightmare. I tried downloading Torque 2.1, but had problems, so then I tried Torque 3.0b1. It seems like Torque isn't going to integrate well with my already existing tables. I use some postgres types such as TEXT and BOOLEAN, which I would expect to map to LONGVARCHAR and BIT respectively, but in the SQL that torque spit out they were bytea and . I can't find mention of bytea in postgres docs, and obviously isn't going to do much for me. =) After reading the Torque docs, I really like what it offers but I'm not sure that it will work for me. Are there any other solutions that people can recommend? Or should I try modifying torque to fit my needs? I don't have any EJB experience but I've heard good things about JBoss. I've also heard the going EJB can really slow an application down. I've also noticed some talk of Expresso on this list, would this be worth trying? Thanks for any advice! -james -- [] James A. Hillyerd [EMAIL PROTECTED] - Java Developer [] PGP 1024D/D31BC40D F87B 7906 C0DA 32E8 B8F6 DE23 FBF6 4712 D31B C40D -- 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]
error executing the struts example with Tomcat 3.3a
Hello All I tried to use JRUN to running my struts application and I didn't get success, so i have desisted. Now I have installed Tomcat 3.3a and started running the Struts-Example (.war file). Ok, tomcat seems that executing normally (servlets and jsp tomcat examples running ok!), but when i try to execute the url struts example below: http://localhost:8080/struts-example/index.jsp I get the following error: Location: /struts-example/index.jsp Internal Servlet Error: java.lang.NoSuchMethodError at org.apache.jasper.compiler.TagLibraryInfoImpl.createAttribute(Unknown Source) at org.apache.jasper.compiler.TagLibraryInfoImpl.createTagInfo(Unknown Source) at org.apache.jasper.compiler.TagLibraryInfoImpl.parseTLD(Unknown Source) at org.apache.jasper.compiler.TagLibraryInfoImpl.(Unknown Source) at org.apache.jasper.compiler.JspParseEventListener.handleDirective(Unknown Source) Any idea ? Thanks in advance. Gilson -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: why send receipt requests in mail list emails?
LOL. Sure, Anthony, you're right, and I'm certainly not pointing fingers or condemning someone for accidently sending a receipt request in an email! However, I have noticed that some people have this as their default setting, as all their emails contain these requests. This, quite frankly, bugs me, since I see no logical reason for it (if there is one, please let me know). To all those who have this as their default setting: It doesn't mean that I have anything against you, it just means I won't reply to the email. :) 'Nuff said. Joe -Original Message- From: Anthony Martin [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 10:36 AM To: 'Struts Users Mailing List' Subject: RE: why send receipt requests in mail list emails? Good point. There is no reason to ask for a receipt request when sending email to mail lists. Looks like I'm guilty of that last night. I completely understand your dilemma. All those extra windows can get tiresome. I feel the same way about people who post in formats other than plain text, those who post half baked questions along with their unwarranted entire stack traces. These types of messages are usually ignored by me as well. Still, thems the breaks. It'll probably only get worse. Anthony -Original Message- From: Joseph Barefoot [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 10:11 AM To: Struts Users Mailing List; Netbeans Users Subject: why send receipt requests in mail list emails? Okay, this is a bit off-topic, but as it involves core mail-list netiquette, I've found it necessary to post something, so here goes: There is absolutely NO reason to issue a receipt request when you send an email to mail lists, as it serves no function whatsoever except to annoy certain people (namely, me) who are trying to scan through the gazillion emails they get a day very quickly without little windows popping up. If someone understands your plight and wishes to respond, they will. If they don't, they won't, and even if they do issue a receipt response, it just means they saw your email and didn't have an answer for you, so you gain nothing. More to the point, I will definitely NOT respond to any email that has a receipt request, nor will some like-minded others I'm sure, so you're just shooting yourself in the foot if you issue one. Your choice, as always, and happy emailing to ya... regards, Joe Barefoot P.S. I realize that for those of us using other email clients (I use Outlook mostly), this is not an issue, so kindly ignore my barbed comments. :) -- 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] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: why send receipt requests in mail list emails?
Oh-oh, here's my valid reason. You are asking why anyone would turn on return receipts as their default setting. Me, I rarely post to lists compared to the internal office email I send. People in the office rarely reply to my highly detailed boring emails, so I have the receipt turned on so I know they at least opened the email. Furthermore, if they just delete it before reading it, I get a message saying so. Unfortunately, if the actually do read it in the preview pain, then delete it, I get the same deleted before reading message too. Not very accurate. Anthony -Original Message- From: Joseph Barefoot [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 12:09 PM To: Struts Users Mailing List Subject: RE: why send receipt requests in mail list emails? LOL. Sure, Anthony, you're right, and I'm certainly not pointing fingers or condemning someone for accidently sending a receipt request in an email! However, I have noticed that some people have this as their default setting, as all their emails contain these requests. This, quite frankly, bugs me, since I see no logical reason for it (if there is one, please let me know). To all those who have this as their default setting: It doesn't mean that I have anything against you, it just means I won't reply to the email. :) 'Nuff said. Joe -Original Message- From: Anthony Martin [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 10:36 AM To: 'Struts Users Mailing List' Subject: RE: why send receipt requests in mail list emails? Good point. There is no reason to ask for a receipt request when sending email to mail lists. Looks like I'm guilty of that last night. I completely understand your dilemma. All those extra windows can get tiresome. I feel the same way about people who post in formats other than plain text, those who post half baked questions along with their unwarranted entire stack traces. These types of messages are usually ignored by me as well. Still, thems the breaks. It'll probably only get worse. Anthony -Original Message- From: Joseph Barefoot [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 10:11 AM To: Struts Users Mailing List; Netbeans Users Subject: why send receipt requests in mail list emails? Okay, this is a bit off-topic, but as it involves core mail-list netiquette, I've found it necessary to post something, so here goes: There is absolutely NO reason to issue a receipt request when you send an email to mail lists, as it serves no function whatsoever except to annoy certain people (namely, me) who are trying to scan through the gazillion emails they get a day very quickly without little windows popping up. If someone understands your plight and wishes to respond, they will. If they don't, they won't, and even if they do issue a receipt response, it just means they saw your email and didn't have an answer for you, so you gain nothing. More to the point, I will definitely NOT respond to any email that has a receipt request, nor will some like-minded others I'm sure, so you're just shooting yourself in the foot if you issue one. Your choice, as always, and happy emailing to ya... regards, Joe Barefoot P.S. I realize that for those of us using other email clients (I use Outlook mostly), this is not an issue, so kindly ignore my barbed comments. :) -- 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] -- 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]
Which action to go back?
Let's say I have application that let's me go5 pages deep from some starting point (every 1 has own menu pointing to subpages). And most of these pages have link Back. Everything would be very easy if Back on some page Deep ALWAYS points topage SomeCaller. The problem is that page Deep may be called from more than 1 place, and I want to return to the caller. Always. What is the best way to do it? It should probably always point to some action, that would know to which forward-mapping redirect to. But how does it know where to go? Remember that is is multilevel hierarchy ... Darek -- Okrel Swoje potrzeby - my znajdziemy ofert za Ciebie! [ http://oferty.onet.pl ] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
what is .war file
what is a .war file what is its use. How can we create a .war file __ Do You Yahoo!? Yahoo! Movies - coverage of the 74th Academy Awards® http://movies.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Multi Indexed Nested properties samples?
Thank you very much Peter. I have solved the issue. Your suggestion is another choice. I'm trying to find a approach to access database. I'm interested in DAO you mentioned. What's DAO and can you give me a example? Thanks in advance. Annie -Original Message- From: Peter Pilgrim Sent: Mon 3/25/2002 6:41 AM To: Struts Users Mailing List Cc: Subject: Re: Multi Indexed Nested properties samples? Annie MUTATOR You will need the mutator method obviously `public void setName( String )' PREFERS INTERFACES Instead of using java.util.Vector, prefer to using an Java Collection interface java.util.List. public List getSubscriptionList() { List list = new ArrayList(); // fill her up return list; } Pros; you change the type of ``List'' in the future. Suppose a better list appears tomorrow Cons: no problem DELEGATE if you have a business object or DAO consider delegation to access. Instead copying the accessor / mutators of the DAO to the ActionForm. Let the DAO be a delegate because Struts supports ``nested bean properties'' out of the box, public class CreditDetailDAO { public String getAuthority() { .. .} } public class Employee extends ActionForm { // Delegate it! private CreditDetail cred; public CreditDetailDAO getCreditDetail() { return cred; } public void setCreditDetail( CreditDetailDAO c ){ this.cred = c }; } Then JSP can be written like so bean:write name=obj property=creditDetail.authority / -- Peter Pilgrim ++44 (0)207-545-9923 Swamped under electronic mails Message History From: Annie Chang [EMAIL PROTECTED] on 24/03/2002 16:39 PST Please respond to Struts Users Mailing List [EMAIL PROTECTED] To:Struts Users Mailing List [EMAIL PROTECTED] cc:[EMAIL PROTECTED]; [EMAIL PROTECTED] Subject:Re: Multi Indexed Nested properties samples? Arron, I want to let the user modify all informations in one page like this way: * | User Information: | Name: Telephone:_ | Email:_Address:__ | | Subscriptions: | Host User Name PasswordType Autoconnect | ___ __ | ___ __ | ___ __ | ___ __ | | Interested Webs: | Catalog NameURL | ___ _____ | ___ _____ | ___ _____ | ___ _____ | | |Save *-- --CUT-- -- This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] winmail.dat Description: application/ms-tnef -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Struts/Tomcat problem
message Servlet ActionServlet is currently unavailable description The requested service (Servlet ActionServlet is currently unavailable) is not currently available Does anyone have any clues to why this happens? Most often for me this is because there was a problem during the initialization of struts. Check the console log for errors. Usually a struts-config.xml problem (or occasionally a missing class file). Frank Lawlor Athens Group, Inc. (512) 345-0600 x151 Athens Group, an employee-owned consulting firm integrating technology strategy and software solutions. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
What the best approach to access RDB within struts (no EJB) ?
I'm searching for the best approach to access relational database within struts. Could you give me some suggestion? Thanks in adv. I do not want to use EJB. Any free framework, tools, whatever can help me? What about DAO and/or JDO? What's DAO? Where can I get a comprehensive example? Thanks
RE: getting validation errors on initial display of a form
Don't go to the action page (the .do), go to the .jsp page! The action is just the target of the form, not the page you start from. (At least that's what I've figured out?!) Dick Starr said: My problem is that when I execute my form via http://localhost:8080/starrd/app/names.do I get validation errors appearing immediately (before I enter any data in the form). I can't believe thats normal: I must be doing something wrong. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: What the best approach to access RDB within struts (no EJB) ?
I have not used it personally, but this looks interesting. Anyone used it? http://dbforms.org/ One big negative for me is it only supports one database per web application, otherwise it looks pretty cool. -Pat -Original Message- From: Annie Chang [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 4:11 PM To: [EMAIL PROTECTED] Subject: What the best approach to access RDB within struts (no EJB) ? I'm searching for the best approach to access relational database within struts. Could you give me some suggestion? Thanks in adv. I do not want to use EJB. Any free framework, tools, whatever can help me? What about DAO and/or JDO? What's DAO? Where can I get a comprehensive example? Thanks -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
email format
Hi, I am sending my own opinion on the new attachment format on the emails. I hope I am not asking for something that no other people likes. I liked the old format where all the posted messages are listed in the preview of the email, so I can see all the posted messages with titles at a glance, and easier to keep track which posting I read and which not yet. Now the message itself is empty, I have to check the attachment list to read individual posting, not very convenient. Wonder if we can go back to the old email format. Thanks very much, Yanhui -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: What the best approach to access RDB within struts (no EJB) ?
Here are some O/R tools I've seen mentioned on the mailing list and other places. I don't know which ones are the best. *Apache:Torque http://jakarta.apache.org/turbine/torque/index.html *ChiMu:FreeForm http://www.chimu.com/projects/form/ *Exolab.org:Castor http://castor.exolab.org/ *JCorporate:Expresso http://www.opensourcedirectory.org/projects/expresso/ *Persistence Layer http://artyomr.narod.ru/ *SourceForge:DataBind http://databind.sf.net/ *SourceForge:jRelationalFramework http://jrf.sourceforge.net/ *SourceForge:ObjectRelationalBridge http://objectbridge.sourceforge.net/ *sql2java http://www.bitmechanic.com/projects/s2j/ *Sun Entity JavaBeans *Sun:JDO ChiMu:Form Objectwave:Jgrinder http://www.objectwave.com/html/Main.html Thought Inc:CoCoBase http://www.sun.com/forte/ffj/resources/articles/thought.html Webgain:Toplink http://www.webgain.com/products/toplink/ *=free -Original Message- From: Patrick Schilling [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 2:16 PM To: Struts Users Mailing List Subject: RE: What the best approach to access RDB within struts (no EJB) ? I have not used it personally, but this looks interesting. Anyone used it? http://dbforms.org/ One big negative for me is it only supports one database per web application, otherwise it looks pretty cool. -Pat -Original Message- From: Annie Chang [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 4:11 PM To: [EMAIL PROTECTED] Subject: What the best approach to access RDB within struts (no EJB) ? I'm searching for the best approach to access relational database within struts. Could you give me some suggestion? Thanks in adv. I do not want to use EJB. Any free framework, tools, whatever can help me? What about DAO and/or JDO? What's DAO? Where can I get a comprehensive example? Thanks -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Struts and Client Side JavaScript Design Question
Greetings. We are in the early planning stages of a rather large Java/jsp application that if I have my way will use struts. There will be a requirement for some convenience features that will need to be in javascript. I understand the pros's and con's of javascript and this will for the most part be for internal users. Where possible, I look forward to using the validator and I like the way that it 'manages' the validation library. There will be many other functions such as auto population of controls from other events and some simple column math and so on. In the past I read several articles on managing javascript from the server side. Other than storing all of it in a bunch of *.js files, can anyone share any experience they have had where they have been forced to maintain a large amount of javascript in a Struts application. Thanks everyone -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: What the best approach to access RDB within struts (no EJB) ?
DAO = Data Access Object http://java.sun.com/blueprints/patterns/j2ee_patterns/data_access_object/ Leo -Original Message- From: Dan Cancro [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 5:26 PM To: 'Struts Users Mailing List' Subject: RE: What the best approach to access RDB within struts (no EJB) ? Here are some O/R tools I've seen mentioned on the mailing list and other places. I don't know which ones are the best. *Apache:Torque http://jakarta.apache.org/turbine/torque/index.html *ChiMu:FreeForm http://www.chimu.com/projects/form/ *Exolab.org:Castor http://castor.exolab.org/ *JCorporate:Expresso http://www.opensourcedirectory.org/projects/expresso/ *Persistence Layer http://artyomr.narod.ru/ *SourceForge:DataBind http://databind.sf.net/ *SourceForge:jRelationalFramework http://jrf.sourceforge.net/ *SourceForge:ObjectRelationalBridge http://objectbridge.sourceforge.net/ *sql2java http://www.bitmechanic.com/projects/s2j/ *Sun Entity JavaBeans *Sun:JDO ChiMu:Form Objectwave:Jgrinder http://www.objectwave.com/html/Main.html Thought Inc:CoCoBase http://www.sun.com/forte/ffj/resources/articles/thought.html Webgain:Toplink http://www.webgain.com/products/toplink/ *=free -Original Message- From: Patrick Schilling [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 2:16 PM To: Struts Users Mailing List Subject: RE: What the best approach to access RDB within struts (no EJB) ? I have not used it personally, but this looks interesting. Anyone used it? http://dbforms.org/ One big negative for me is it only supports one database per web application, otherwise it looks pretty cool. -Pat -Original Message- From: Annie Chang [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 4:11 PM To: [EMAIL PROTECTED] Subject: What the best approach to access RDB within struts (no EJB) ? I'm searching for the best approach to access relational database within struts. Could you give me some suggestion? Thanks in adv. I do not want to use EJB. Any free framework, tools, whatever can help me? What about DAO and/or JDO? What's DAO? Where can I get a comprehensive example? Thanks -- 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]
dynamic select box
Hi, I'm new to struts and was wondering if anybody knew how create a select box with struts. I have a bean which is returning an ArrayList. I want to use this ArrayList as the options in the select tag. What code do I need in my jsp to create this select box? Can somebody please help me? Jose Casas E-Commerce Applications (501) 277-3112 [EMAIL PROTECTED] ** This email and any files transmitted with it are confidential and intended solely for the individual or entity to whom they are addressed. If you have received this email in error destroy it immediately. ** -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: What the best approach to access RDB within struts (no EJB) ?
Subject: Re: What the best approach to access RDB within struts (no EJB) 1 2 3 4 5 6 7 8 9 From: Vic Cekvenich [EMAIL PROTECTED] === www.strutsplus.com/downloads.jsp has a sample db access w/Struts. DB forms looks limited. Patrick Schilling wrote: I have not used it personally, but this looks interesting. Anyone used it? http://dbforms.org/ One big negative for me is it only supports one database per web application, otherwise it looks pretty cool. -Pat -Original Message- From: Annie Chang [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 4:11 PM To: [EMAIL PROTECTED] Subject: What the best approach to access RDB within struts (no EJB) ? I'm searching for the best approach to access relational database within struts. Could you give me some suggestion? Thanks in adv. I do not want to use EJB. Any free framework, tools, whatever can help me? What about DAO and/or JDO? What's DAO? Where can I get a comprehensive example? Thanks -- 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]
RE: what is .war file
http://java.sun.com/webservices/docs/ea2/tutorial/doc/WebApp3.html I recommend ant (http://jakarta.apache.org/ant) for creating one. Tim. -Original Message- From: divyakant verma [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 2:22 PM To: [EMAIL PROTECTED] Subject: what is .war file what is a .war file what is its use. How can we create a .war file __ Do You Yahoo!? Yahoo! Movies - coverage of the 74th Academy Awards. http://movies.yahoo.com/ -- 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]
RE: dynamic select box
This is how we do it: html:select name=yourActionForm property=fieldToHoldSelectedValue html:options collection=yourArrayList property=optionValue labelProperty=optionLabel/ /html:select The ArrayList (in yourActionForm bean) should contain a list of Objects (call it a KeyValuePair bean or something) which contain getOptionValue and getOptionLabel methods (method names match the values in the JSP tag). Struts will look for these methods to retrieve the proper values from each Object in the ArrayList and populate the html tags with them. The fieldToHoldSelectedValue field in yourActionForm will be set to the value the user picks when the HTML form is submitted. -Original Message- From: Jose Casas [mailto:[EMAIL PROTECTED]] Sent: Monday, March 25, 2002 2:35 PM To: 'Struts Users Mailing List' Subject: dynamic select box Hi, I'm new to struts and was wondering if anybody knew how create a select box with struts. I have a bean which is returning an ArrayList. I want to use this ArrayList as the options in the select tag. What code do I need in my jsp to create this select box? Can somebody please help me? Jose Casas E-Commerce Applications (501) 277-3112 [EMAIL PROTECTED] ** This email and any files transmitted with it are confidential and intended solely for the individual or entity to whom they are addressed. If you have received this email in error destroy it immediately. ** -- 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]
Re: Single Servlet Controller Model
I believe the new release (1.1 beta 1) addresses this? --- K J [EMAIL PROTECTED] wrote: One of the things I don't like about Struts is its single servlet gateway model. Would it be possible to extend the ActionServlet? Has anyone done this? In general, do you think the single servlet model could be a performance issues for a very active web application? And if so, how would you address that? Thanks! __ Do You Yahoo!? Yahoo! Movies - coverage of the 74th Academy Awards® http://movies.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] __ Do You Yahoo!? Yahoo! Movies - coverage of the 74th Academy Awards® http://movies.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: dynamic select box
From the sample DB app: in JSP: html:select property=contactType html:optionsCollection property=contactTypeOptions/ /html:select In Options helper: /** * Return an unsynchronized collection of options. */ public Collection getContactTypeOptions() { ArrayList v = new ArrayList(); // no need to synchronize try { // Retrieve rowset; Move before first setSQLCommand(SQL_COMMAND); getCR().setTableName(TABLE_NAME); getCR().setString(1,ID); dbConnect(); exec(); dbDisconnect(); getCR().beforeFirst(); // Create collection of beans from result while(getCR().next()) { v.add( new Option(getCR().getString(VALUE), getCR().getString(LABEL)) ); } // end while } // end try catch (Exception e) { System.out.println(e + BBug.OPTION_TYPES); e.printStackTrace(); BBug.log(e, BBug.OPTION_TYPES); } return v; } // end getContactTypeOptions Jose Casas [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... Hi, I'm new to struts and was wondering if anybody knew how create a select box with struts. I have a bean which is returning an ArrayList. I want to use this ArrayList as the options in the select tag. What code do I need in my jsp to create this select box? Can somebody please help me? Jose Casas E-Commerce Applications (501) 277-3112 [EMAIL PROTECTED] ** This email and any files transmitted with it are confidential and intended solely for the individual or entity to whom they are addressed. If you have received this email in error destroy it immediately. ** -- 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]
Hi - Ryan Norman
Hi, I am Ryan Norman. I am new to this Struts mailing list. Thanks Ryan Norman
Communication between JSPs
Hi, I'm new to struts and have this silly question: My code does not use struts currently. From JSP1, I call another JSP2 using the action and I also pass parameters. Now, I want to incorporate struts in my code. So, do I have to replace the reference to jsp2 by action class? If so, how do i pass parameters from jsp1 to jsp2 thru action1? Thanks, Bhaskar -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Cannot preload ActionServlet in JRun3.1using Struts1.1-b1
This may be a problem in JRun's web app class loading implementation or in the commons-logging implementation. The exception occurs if you try to preload the ActionServlet. But if the ActionServlet is initialized from a request it is loaded just fine. It looks like the org.apache.commons.logging.LogFactory.findClassLoader() maybe returning the wrong ClassLoader when called when an ActionServlet is being preloaded...all the struts and commons-*.jar files are in the usual web-inf/lib folder. This is a show stopper for those who are extending ActionServlet to do some extra initialization which needs to be initialized before anything else. Its forcing me to go back to a struts nightly build that does not have the commons-logging implementation. If this a bug in org.apache.commons.logging.LogFactory.findClassLoader(), then would the fix cause changes in struts or would i simply have to get the latest commons-logging.jar if and when this is addressed? Thanks. -ronel 03/25 14:44:34 error (JRun) Could not pre-load servlet: action [javax.servlet.ServletException: Could not instantiate org.apache.struts.action.ActionServlet] [1]org.apache.commons.logging.LogConfigurationException: java.lang.ClassNotFoundException: org.apache.commons.logging.impl.LogFactoryImpl at org.apache.commons.logging.LogFactory.newFactory(LogFactory.java:497) at org.apache.commons.logging.LogFactory.getFactory(LogFactory.java:350) at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:381) at org.apache.struts.action.ActionServlet.init(ActionServlet.java:331) at java.lang.Class.newInstance0(Native Method) at java.lang.Class.newInstance(Unknown Source) at allaire.jrun.servlet.JRunServletLoader.loadServletInstance(../servlet/JRunSe rvletLoader.java:197) at allaire.jrun.servlet.JRunServletLoader.loadServletInstance(../servlet/JRunSe rvletLoader.java:161) at allaire.jrun.servlet.JRunServletLoader.loadServlet(../servlet/JRunServletLoa der.java:149) at allaire.jrun.servlet.JRunSE.getServletReference(../servlet/JRunSE.java:1705) at allaire.jrun.servlet.JRunSE.preloadServlets(../servlet/JRunSE.java:1371) at allaire.jrun.servlet.JRunSE.init(../servlet/JRunSE.java:236) at allaire.jrun.ServletService.init(../ServletService.java:66) at allaire.jrun.ServletService.init(../ServletService.java:31) at allaire.jrun.servlet.JRunServletLoader.loadServletInstance(../servlet/JRunSe rvletLoader.java:203) at allaire.jrun.servlet.JRunSE.initService(../servlet/JRunSE.java:891) at allaire.jrun.servlet.JRunSE.initServices(../servlet/JRunSE.java:858) at allaire.jrun.servlet.JvmContext.initServices(../servlet/JvmContext.java:130) at allaire.jrun.servlet.JRunSE.init(../servlet/JRunSE.java:222) at allaire.jrun.servlet.JvmContext.init(../servlet/JvmContext.java:69) at allaire.jrun.ServletService.init(../ServletService.java:66) at allaire.jrun.ServletService.init(../ServletService.java:31) at JRun.main(../../../JRun.java:172) [0]javax.servlet.ServletException: Could not instantiate org.apache.struts.action.ActionServlet at allaire.jrun.servlet.JRunServletLoader.loadServletInstance(../servlet/JRunSe rvletLoader.java:209) at allaire.jrun.servlet.JRunServletLoader.loadServletInstance(../servlet/JRunSe rvletLoader.java:161) at allaire.jrun.servlet.JRunServletLoader.loadServlet(../servlet/JRunServletLoa der.java:149) at allaire.jrun.servlet.JRunSE.getServletReference(../servlet/JRunSE.java:1705) at allaire.jrun.servlet.JRunSE.preloadServlets(../servlet/JRunSE.java:1371) at allaire.jrun.servlet.JRunSE.init(../servlet/JRunSE.java:236) at allaire.jrun.ServletService.init(../ServletService.java:66) at allaire.jrun.ServletService.init(../ServletService.java:31) at allaire.jrun.servlet.JRunServletLoader.loadServletInstance(../servlet/JRunSe rvletLoader.java:203) at allaire.jrun.servlet.JRunSE.initService(../servlet/JRunSE.java:891) at allaire.jrun.servlet.JRunSE.initServices(../servlet/JRunSE.java:858) at allaire.jrun.servlet.JvmContext.initServices(../servlet/JvmContext.java:130) at allaire.jrun.servlet.JRunSE.init(../servlet/JRunSE.java:222) at allaire.jrun.servlet.JvmContext.init(../servlet/JvmContext.java:69) at allaire.jrun.ServletService.init(../ServletService.java:66) at allaire.jrun.ServletService.init(../ServletService.java:31) at JRun.main(../../../JRun.java:172) -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Tomcat Console Messages - Ryan Norman
Hi, I am new to struts. I installed struts 1.0.2. I copied the struts-example.war under the webapps directory and restarted tomcat. When I restarted tomcat as a service, I did not notice anything. When I started tomcat as a console application, I saw lot of messages. Can somebody explain me what these messages are? I am pasting the messages at the end of this email. Thanks in advance Ryan Norman == Starting service Tomcat-Standalone Apache Tomcat/4.0.1 New org.apache.struts.webapp.example.User Set org.apache.struts.webapp.example.User properties New org.apache.struts.webapp.example.Subscription Set org.apache.struts.webapp.example.Subscription properties Call org.apache.struts.webapp.example.Subscription.setUser(User[username=user, f ullName=John Q. User]) Pop org.apache.struts.webapp.example.Subscription New org.apache.struts.webapp.example.Subscription Set org.apache.struts.webapp.example.Subscription properties Call org.apache.struts.webapp.example.Subscription.setUser(User[username=user, f ullName=John Q. User]) Pop org.apache.struts.webapp.example.Subscription Call org.apache.struts.webapp.example.DatabaseServlet.addUser(User[username=user , fullName=John Q. User]) Pop org.apache.struts.webapp.example.User register('-//Apache Software Foundation//DTD Struts Configuration 1.0//EN', 'jar :file:/C:/Java/Tomcat40/webapps/struts-example/WEB-INF/lib/struts.jar!/org/apach e/struts/resources/struts-config_1_0.dtd' register('-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN', 'jar:file:/C: /Java/Tomcat40/webapps/struts-example/WEB-INF/lib/struts.jar!/org/apache/struts/ resources/web-app_2_2.dtd' register('-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN', 'jar:file:/C: /Java/Tomcat40/webapps/struts-example/WEB-INF/lib/struts.jar!/org/apache/struts/ resources/web-app_2_3.dtd' resolveEntity('-//Apache Software Foundation//DTD Struts Configuration 1.0//EN', 'http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd') Resolving to alternate DTD 'jar:file:/C:/Java/Tomcat40/webapps/struts-example/W EB-INF/lib/struts.jar!/org/apache/struts/resources/struts-config_1_0.dtd' New org.apache.struts.action.ActionFormBean Set org.apache.struts.action.ActionFormBean properties Call org.apache.struts.action.ActionServlet.addFormBean(ActionFormBean[logonForm ]) Pop org.apache.struts.action.ActionFormBean New org.apache.struts.action.ActionFormBean Set org.apache.struts.action.ActionFormBean properties Call org.apache.struts.action.ActionServlet.addFormBean(ActionFormBean[registrat ionForm]) Pop org.apache.struts.action.ActionFormBean New org.apache.struts.action.ActionFormBean Set org.apache.struts.action.ActionFormBean properties Call org.apache.struts.action.ActionServlet.addFormBean(ActionFormBean[subscript ionForm]) Pop org.apache.struts.action.ActionFormBean New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionServlet.addForward(ActionForward[logoff]) Pop org.apache.struts.action.ActionForward New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionServlet.addForward(ActionForward[logon]) Pop org.apache.struts.action.ActionForward New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionServlet.addForward(ActionForward[success]) Pop org.apache.struts.action.ActionForward New org.apache.struts.action.ActionMapping Set org.apache.struts.action.ActionMapping properties New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionMapping.addForward(ActionForward[success]) Pop org.apache.struts.action.ActionForward Call org.apache.struts.action.ActionServlet.addMapping(ActionMapping[path=/editR egistration, type=org.apache.struts.webapp.example.EditRegistrationAction]) Pop org.apache.struts.action.ActionMapping New org.apache.struts.action.ActionMapping Set org.apache.struts.action.ActionMapping properties New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionMapping.addForward(ActionForward[failure]) Pop org.apache.struts.action.ActionForward New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionMapping.addForward(ActionForward[success]) Pop org.apache.struts.action.ActionForward Call org.apache.struts.action.ActionServlet.addMapping(ActionMapping[path=/editS ubscription, type=org.apache.struts.webapp.example.EditSubscriptionAction]) Pop org.apache.struts.action.ActionMapping New org.apache.struts.action.ActionMapping Set org.apache.struts.action.ActionMapping properties New org.apache.struts.action.ActionForward Set
Re: Communication between JSPs
One way: public ActionForward execute( ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) { NameZoomBean frm = (NameZoomBean) form; if (frm == null) frm = new NameZoomBean(); String pk = request.getParameter(PK_KEY); // get message and do something. long pkl = 1; if (pk != null) pkl = BUtil.strngLong(pk); BBug.log(pks +pk+pkl); frm.populate(pkl); return (mapping.findForward(FORWARD)); Another way: public ActionForward execute( ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) { SrchBean msg = new SrchBean(); msg = (SrchBean) request.getAttribute(SRCH_KEY); String fn= msg.getFstName(); String ln= msg.getLastName(); // 2nd bean to get the message NameLstBean nl = new NameLstBean(); nl.setMsgFstName(fn); nl.setMsgLastName(ln); request.setAttribute(NAME_LST_KEY,nl); return (mapping.findForward(FORWARD)); You can have a full working code example from StrutsPlus.com/downloads.jsp hth, Vic Bhaskar Gopalan [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... Hi, I'm new to struts and have this silly question: My code does not use struts currently. From JSP1, I call another JSP2 using the action and I also pass parameters. Now, I want to incorporate struts in my code. So, do I have to replace the reference to jsp2 by action class? If so, how do i pass parameters from jsp1 to jsp2 thru action1? Thanks, Bhaskar -- 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]
Re: Tomcat Console Messages - Ryan Norman
That is a TomCat question (you can ask at news.basebeans.com / Tomcat.) The messages are sent in both cases, as a service they go to events logs in Windows. They are debug tracking messages that you can turn of. They were nice during development. (In case you take anything to production, you should have very few messages( Vic (You might want to spend some time learning Servlets, JSP, JDBC and an application server, plenty of books on this. Also, it is customary to search the mail-archives before asking a question. Also, bad form to post a hello world message) Ryan Norman [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... Hi, I am new to struts. I installed struts 1.0.2. I copied the struts-example.war under the webapps directory and restarted tomcat. When I restarted tomcat as a service, I did not notice anything. When I started tomcat as a console application, I saw lot of messages. Can somebody explain me what these messages are? I am pasting the messages at the end of this email. Thanks in advance Ryan Norman == Starting service Tomcat-Standalone Apache Tomcat/4.0.1 New org.apache.struts.webapp.example.User Set org.apache.struts.webapp.example.User properties New org.apache.struts.webapp.example.Subscription Set org.apache.struts.webapp.example.Subscription properties Call org.apache.struts.webapp.example.Subscription.setUser(User[username=user, f ullName=John Q. User]) Pop org.apache.struts.webapp.example.Subscription New org.apache.struts.webapp.example.Subscription Set org.apache.struts.webapp.example.Subscription properties Call org.apache.struts.webapp.example.Subscription.setUser(User[username=user, f ullName=John Q. User]) Pop org.apache.struts.webapp.example.Subscription Call org.apache.struts.webapp.example.DatabaseServlet.addUser(User[username=user , fullName=John Q. User]) Pop org.apache.struts.webapp.example.User register('-//Apache Software Foundation//DTD Struts Configuration 1.0//EN', 'jar :file:/C:/Java/Tomcat40/webapps/struts-example/WEB-INF/lib/struts.jar!/org/apach e/struts/resources/struts-config_1_0.dtd' register('-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN', 'jar:file:/C: /Java/Tomcat40/webapps/struts-example/WEB-INF/lib/struts.jar!/org/apache/struts/ resources/web-app_2_2.dtd' register('-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN', 'jar:file:/C: /Java/Tomcat40/webapps/struts-example/WEB-INF/lib/struts.jar!/org/apache/struts/ resources/web-app_2_3.dtd' resolveEntity('-//Apache Software Foundation//DTD Struts Configuration 1.0//EN', 'http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd') Resolving to alternate DTD 'jar:file:/C:/Java/Tomcat40/webapps/struts-example/W EB-INF/lib/struts.jar!/org/apache/struts/resources/struts-config_1_0.dtd' New org.apache.struts.action.ActionFormBean Set org.apache.struts.action.ActionFormBean properties Call org.apache.struts.action.ActionServlet.addFormBean(ActionFormBean[logonForm ]) Pop org.apache.struts.action.ActionFormBean New org.apache.struts.action.ActionFormBean Set org.apache.struts.action.ActionFormBean properties Call org.apache.struts.action.ActionServlet.addFormBean(ActionFormBean[registrat ionForm]) Pop org.apache.struts.action.ActionFormBean New org.apache.struts.action.ActionFormBean Set org.apache.struts.action.ActionFormBean properties Call org.apache.struts.action.ActionServlet.addFormBean(ActionFormBean[subscript ionForm]) Pop org.apache.struts.action.ActionFormBean New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionServlet.addForward(ActionForward[logoff]) Pop org.apache.struts.action.ActionForward New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionServlet.addForward(ActionForward[logon]) Pop org.apache.struts.action.ActionForward New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionServlet.addForward(ActionForward[success]) Pop org.apache.struts.action.ActionForward New org.apache.struts.action.ActionMapping Set org.apache.struts.action.ActionMapping properties New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call org.apache.struts.action.ActionMapping.addForward(ActionForward[success]) Pop org.apache.struts.action.ActionForward Call org.apache.struts.action.ActionServlet.addMapping(ActionMapping[path=/editR egistration, type=org.apache.struts.webapp.example.EditRegistrationAction]) Pop org.apache.struts.action.ActionMapping New org.apache.struts.action.ActionMapping Set org.apache.struts.action.ActionMapping properties New org.apache.struts.action.ActionForward Set org.apache.struts.action.ActionForward properties Call
html:options Iterator Creation error -
Hi, I am trying to implement the html:options tag in one of our applications, I have a form bean with the following attributes, private Collection securityOptions = null; private String security = Default; In my action class, I populate the collection with PersonalForm perform = (PersonalForm) form; Collection list = (Collection) new ArrayList(); for(int i = 0; i10; i++) { list.add(new LabelValueBean(Default,Value)); } perform.setSecurityOptions(list); and finally in my jsp, I try to display the collection using html:options tag as follows html:select property=security multiple=false bean:define id=myCollection name=personalForm property=securityOptions/ html:options collection=myCollection property=value labelProperty=label/ /html:select I get the following error when I try to view the page javax.servlet.ServletException: Cannot create iterator for at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContex tImpl.java:463) at org.apache.jsp.personal$jsp._jspService(personal$jsp.java:1031) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServle t.java:202) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:382) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:474) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatc her.java:683) - Root Cause - javax.servlet.jsp.JspException: Cannot create iterator for at org.apache.struts.taglib.html.OptionsTag.getIterator(OptionsTag.java:420 ) at org.apache.struts.taglib.html.OptionsTag.doEndTag(OptionsTag.java:222) at org.apache.jsp.personal$jsp._jspService(personal$jsp.java:785) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) Any comments,suggestions? Appreciate your help. Thanks, Sunder -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Single Servlet Controller Model
Vic is right. In a multi-threaded environment there is no performance benefit to having multiple servlets that do the same thing. The threads are lighter than loading another servlet, and make the best use of the available resources. It is important to remember that the requests are *not* queued through the servlet single-file. A single servlet is *not* a bottleneck. Each request gets its own thread, and they are processed in tandem. -- Ted Husted, Husted dot Com, Fairport NY US -- Developing Java Web Applications with Struts -- Tel: +1 585 737-3463 -- Web: http://husted.com/about/services Struts Newsgroup (@Basebeans.com) wrote: Subject: Re: Single Servlet Controller Model From: Vic Cekvenich [EMAIL PROTECTED] === There are no or very little performance limitations to Struts. Most of the time it is DB access (especially if you use JDO or O/R or EJB, native SQL is fast). Do not worry about performance of Struts or the single servelt. (Single servlet is sometimes faster) hth, Vic K J wrote: Is there anyway around it with the current release? Thaks. --- Sandeep Takhar [EMAIL PROTECTED] wrote: I believe the new release (1.1 beta 1) addresses this? --- K J [EMAIL PROTECTED] wrote: One of the things I don't like about Struts is its single servlet gateway model. Would it be possible to extend the ActionServlet? Has anyone done this? In general, do you think the single servlet model could be a performance issues for a very active web application? And if so, how would you address that? Thanks! __ Do You Yahoo!? Yahoo! Movies - coverage of the 74th Academy Awards® http://movies.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] __ Do You Yahoo!? Yahoo! Movies - coverage of the 74th Academy Awards® http://movies.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] __ Do You Yahoo!? Yahoo! Movies - coverage of the 74th Academy Awards® http://movies.yahoo.com/ -- 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] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: when does STRUTS call reset() on form beans ?
In 1.0, reset is called just before the servlet autopopulates the bean from the request. In 1.1 beta, it is also called when an html:form tag instantiates the bean (not finding one in the request). If an Action forwards to another action-mapping, reset is called again since the controller will autopopulate the Action form for the next action. (It doesn't actually know that the request was forwarded.) If that's a problem, you can use a mutable property on your form-bean to tell the mutators not to accept new data. -- Ted Husted, Husted dot Com, Fairport NY US -- Developing Java Web Applications with Struts -- Tel: +1 585 737-3463 -- Web: http://husted.com/about/services Maris Orbidans wrote: Does it depend on scope of a session bean ? thanx in advance Maris Orbidans -- 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]
OptionsTag bug using nested property?
I seem to have run into a bug with the struts OptionsTag custom tag when using a nested property. I am including the problem and my workaround, but if someone here has any advice or help, I'd love to have a cleaner solution than my workaround, so if someone here could help me out, it would be appreciated. By the way, I tried to use the nested tag library, and slammed into a brick wall... so if someone can show me code to make this work with nested taglib, also much appreciated. Here is my situation: I want to show a drop-down list of provinces in my JSP pages via the html:select and html:options tags. I have a class called ProvinceLookup, which caches a java.util.List. This list contains Province objects which expose a getProvinceCode and a getProvinceName method. The Evil Bug?: cannot reference nested properties in 'OptionsTag' using the 'collection' attribute. ProvinceLookup has a method called getLookupData which returns a List. At the top of my JSP page, I create a ProvinceLookup object which contains the lookupData in cached form: jsp:useBean id=provinceLookup scope=page class=ca.tcpl.ris.web.ProvinceLookup/ Further down, I try to reference the lookupData nested in my provinceLookup object: html:select property=province html:options collection=provinceLookup.lookupData labelProperty=provinceCode property=provinceName / /html:select This generates the exception trace (shown at the bottom of this email). My workaround is to use the bean:define custom tag to expose the lookupData directly in the page scope. Then my select JSP looks like the following (and works): html:select property=province html:options collection=lookupData labelProperty=provinceCode property=provinceName / /html:select type Exception report message Internal Server Error description The server encountered an internal error (Internal Server Error) that prevented it from fulfilling this request. exception javax.servlet.ServletException: Cannot find bean under name provinceLookup.lookupData at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:457) at org.apache.jsp.WellSearch$jsp._jspService(WellSearch$jsp.java:1321) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet$JspServletWrapper.service(IDEJspServlet.java:172) at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet.serviceJspFile(IDEJspServlet.java:234) at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet.service(IDEJspServlet.java:326) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566) at org.netbeans.modules.web.monitor.catalina.MonitorValve.invoke(MonitorValve.java:144) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2344) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:462) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at
Re: OptionsTag bug using nested property?
Your work-around is that much of a work-around, as it was the only solution up until a couple of weeks ago. If you're running 1.1beta or something near it, you'll have the optionsCollection tag. It's a more natural fit to the system. Use the name attribute, to select the bean, the property attribute to get to the collection, label attribute which is the bean property of the item in the collection that is the label, and the value attribue the bean property of the item in the collection that is the value. If you're running this struts you could use... html:select property=province html:options name=beanName property=provinceLookup.lookupData label=provinceCode value=provinceName / /html:select And the nested version, naturally works against the same bean as all the other tags, the property attribute relative to the others etc etc etc. But your workaround is the standard solution for most people. Arron. Vladimir Levin wrote: I seem to have run into a bug with the struts OptionsTag custom tag when using a nested property. I am including the problem and my workaround, but if someone here has any advice or help, I'd love to have a cleaner solution than my workaround, so if someone here could help me out, it would be appreciated. By the way, I tried to use the nested tag library, and slammed into a brick wall... so if someone can show me code to make this work with nested taglib, also much appreciated. Here is my situation: I want to show a drop-down list of provinces in my JSP pages via the html:select and html:options tags. I have a class called ProvinceLookup, which caches a java.util.List. This list contains Province objects which expose a getProvinceCode and a getProvinceName method. The Evil Bug?: cannot reference nested properties in 'OptionsTag' using the 'collection' attribute. ProvinceLookup has a method called getLookupData which returns a List. At the top of my JSP page, I create a ProvinceLookup object which contains the lookupData in cached form: jsp:useBean id=provinceLookup scope=page class=ca.tcpl.ris.web.ProvinceLookup/ Further down, I try to reference the lookupData nested in my provinceLookup object: html:select property=province html:options collection=provinceLookup.lookupData labelProperty=provinceCode property=provinceName / /html:select This generates the exception trace (shown at the bottom of this email). My workaround is to use the bean:define custom tag to expose the lookupData directly in the page scope. Then my select JSP looks like the following (and works): html:select property=province html:options collection=lookupData labelProperty=provinceCode property=provinceName / /html:select type Exception report message Internal Server Error description The server encountered an internal error (Internal Server Error) that prevented it from fulfilling this request. exception javax.servlet.ServletException: Cannot find bean under name provinceLookup.lookupData at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:457) at org.apache.jsp.WellSearch$jsp._jspService(WellSearch$jsp.java:1321) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet$JspServletWrapper.service(IDEJspServlet.java:172) at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet.serviceJspFile(IDEJspServlet.java:234) at org.netbeans.modules.tomcat.tomcat40.runtime.IDEJspServlet.service(IDEJspServlet.java:326) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566) at org.netbeans.modules.web.monitor.catalina.MonitorValve.invoke(MonitorValve.java:144) at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472) at
Cannot find message resources under key org.apache.struts.action.MESSAGE
Hi, I want to use chechboxes in an iterate as the follows, but there is an error, what's the matter? logic:iterate id=order name=OrdersForm property=orderList tr td html:checkbox name=order property=_selected_/ /td Error: ApplicationDispatcher[]: Servlet.service() for servlet debugjsp threw exception javax.servlet.ServletException: Cannot find message resources under key org.apache.struts.action.MESSAGE at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:480) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatc her.java:679)
Re: Nested tag tutorial
Subject: Re: Nested tag tutorial From: Doug [EMAIL PROTECTED] === I think you'll need struts/index.html, otherwise you'll get a 403. doug P. G. [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... The tutorial may be found at: www.keyboardmonkey.com/struts I also had problems very similar to yours except that I was using an ArrayList instead of a vector. I did the nested tags tutorial, and it has been smooth sailing ever since. Cheers, Ubiqueman From: Perpetua Cysne [EMAIL PROTECTED] Reply-To: Perpetua Cysne [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: Nested tag tutorial Date: Sat, 23 Mar 2002 00:13:16 -0500 Hello, How do I get this tutorial? Cheers, Perpetua - Original Message - From: [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Tuesday, March 19, 2002 5:52 PM Subject: Nested tag tutorial The nested tag tutorial created by Arron Bates simply rocks!I was kind of intimidated by nested tags until I took a few hours out of my day to go thru parts 1 and 2 of the tutorial. Thanks to the way it was well laid out AND interesting, nested tags are no longer intimidating.Thanks to Arron on this one for a job well done.Can't recommend it enough. Is his tutorial easy to follow? I'm a total idiot/moron and his tutorial made it easy to learn nested tags. Thanks Arron. -- 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] Ubiqueman's Iron Maiden and Heavy Metal Bootlegs http://www.geocities.com/ubiqueman _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- 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]
Re: Cannot find message resources under key org.apache.struts.action.MESSAGE
It means that u should have your application resource ( MESSAGE file ) under the package org.apache.struts.action and the fully qualified class name should be mapped in to the web.xml file the sample code of web.xml is as : web-app display-nameCocoon2 Demo/display-name descriptionDemo application for Cocoon2/description + servlet servlet-nameCocoon2/servlet-name display-nameCocoon2/display-name descriptionThe main Cocoon2 servlet/description - !-- In cases you're facing class loader problems you can alternatively use the following servlet-class instead of the normal one servlet-classorg.apache.cocoon.servlet.ParanoidCocoonServlet/servlet-class -- servlet-classorg.apache.cocoon.servlet.CocoonServlet/servlet-class - !-- This parameter points to the main configuration file for Cocoon. Note that the path is specified in absolute notation but it will be resolved relative to the servlets webapp context path -- - init-param param-nameconfigurations/param-name param-value/cocoon.xconf/param-value /init-param - !-- This parameter tells cocoon to load all the required libraries into it's own classloader instead of trusting the Servlet Vendor's classloader. If you experience strange classloader issues, try setting this parameter to true. -- - init-param param-nameinit-classloader/param-name param-valuefalse/param-value /init-param - !-- This parameter indicates the configuration file of the LogKit management -- - init-param param-namelogkit-config/param-name param-value/WEB-INF/logkit.xconf/param-value /init-param - !-- This parameter indicates the category id of the logger from the LogKit configuration used by the CocoonServlet. -- - init-param param-nameservlet-logger/param-name param-valueaccess/param-value /init-param - !-- This parameter indicates the category id of the logger from the LogKit management configuration for the Cocoon engine. This logger is used for all components described in the cocoon.xconf and sitemap.xmap file not having specified a logger with the logger=... attribute in the component configuration file. -- - init-param param-namecocoon-logger/param-name param-valuecore/param-value /init-param - !-- This parameter indicates the log level to use throughout startup of the system. As soon as the logkit.xconf the setting of the logkit.xconf configuration is used instead! Only for startup and if the logkit.xconf is not readable/available this log level is of importance. Available levels are: DEBUG:prints all level of log messages. INFO: prints all level of log messages except DEBUG ones. WARN: prints all level of log messages except DEBUG and INFO ones. ERROR:prints all level of log messages except DEBUG, INFO and WARN ones. FATAL-ERROR: prints only log messages of this level -- - init-param param-namelog-level/param-name param-valueDEBUG/param-value /init-param - !-- Allow reinstantiating (reloading) of the cocoon instance. If this is set to yes or true, a new cocoon instance can be created using the request parameter cocoon-reload. -- - init-param param-nameallow-reload/param-name param-valueyes/param-value /init-param - !-- This parameter is used to list classes that should be loaded at initialization time of the servlet. Usually this classes are JDBC Drivers used -- - init-param param-nameload-class/param-name - param-value - !-- For IBM WebSphere: com.ibm.servlet.classloader.Handler -- - !-- For Database Driver: -- org.hsqldb.jdbcDriver - !-- For parent ComponentManager sample: org.apache.cocoon.samples.parentcm.Configurator -- /param-value /init-param - !-- This parameter allows to specify where Cocoon should put files which are uploaded by the upload.xsp sample. The path specified is always relative to the context path of the servlet. The default directory is upload-dir in the work-directory init-param param-nameupload-directory/param-name param-value/WEB-INF/work/upload-dir/param-value /init-param -- - !-- This parameter allows to specify where Cocoon should put files which are cached by the storing class. The path specified is always relative to the context path of the servlet. The default directory is cache-dir in the work-directory init-param param-namecache-directory/param-name param-value/WEB-INF/work/cache-dir/param-value /init-param -- - !-- This parameter allows to specify where Cocoon should put it's working files. The path specified is always relative to the
RE: Cannot find message resources under key org.apache.struts.action.MESSAGE
Hi, Thanks, The error only occurs when I use html:checkbox OR html:text. But bean:write is OK, when delete the tag html:checkbox , everything is OK. So what's matter, do you know? Thank in adv. logic:iterate id=order name=OrdersForm property=orderList tr td html:checkbox name=order property=_selected_ indexed=true value=true/ /td tddiv align=leftfont face=Verdana, Arial, Geneva, sans-serif size=-2 bean:write name=order property=orderNumber filter=true/ /font/div /td ApplicationDispatcher[]: Servlet.service() for servlet debugjsp threw exception javax.servlet.ServletException: Cannot find message resources under key org.apache.struts.action.MESSAGE at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:480) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatc her.java:679) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDisp atcher.java:431) -Original Message- From: [EMAIL PROTECTED] Sent: Mon 3/25/2002 8:55 PM To: [EMAIL PROTECTED] Cc: Subject: Re: Cannot find message resources under key org.apache.struts.action.MESSAGE It means that u should have your application resource ( MESSAGE file ) under the package org.apache.struts.action and the fully qualified class name should be mapped in to the web.xml file the sample code of web.xml is as : web-app display-nameCocoon2 Demo/display-name descriptionDemo application for Cocoon2/description + servlet servlet-nameCocoon2/servlet-name display-nameCocoon2/display-name descriptionThe main Cocoon2 servlet/description - !-- In cases you're facing class loader problems you can alternatively use the following servlet-class instead of the normal one servlet-classorg.apache.cocoon.servlet.ParanoidCocoonServlet/servlet- class -- servlet-classorg.apache.cocoon.servlet.CocoonServlet/servlet-class - !-- This parameter points to the main configuration file for Cocoon. Note that the path is specified in absolute notation but it will be resolved relative to the servlets webapp context path -- - init-param param-nameconfigurations/param-name param-value/cocoon.xconf/param-value /init-param - !-- This parameter tells cocoon to load all the required libraries into it's own classloader instead of trusting the Servlet Vendor's classloader. If you experience strange classloader issues, try setting this parameter to true. -- - init-param param-nameinit-classloader/param-name param-valuefalse/param-value /init-param - !-- This parameter indicates the configuration file of the LogKit management -- - init-param param-namelogkit-config/param-name param-value/WEB-INF/logkit.xconf/param-value /init-param - !-- This parameter indicates the category id of the logger from the LogKit configuration used by the CocoonServlet. -- - init-param param-nameservlet-logger/param-name param-valueaccess/param-value /init-param - !-- This parameter indicates the category id of the logger from the LogKit management configuration for the Cocoon engine. This logger is used for all components described in the cocoon.xconf and sitemap.xmap file not having specified a logger with the logger=... attribute in the component configuration file. -- - init-param param-namecocoon-logger/param-name param-valuecore/param-value /init-param - !-- This parameter indicates the log level to use throughout startup of the system. As soon as the logkit.xconf the setting of the logkit.xconf configuration is used instead! Only for startup and if the logkit.xconf is not readable/available this log level is of importance. Available levels are: DEBUG:prints all level of log messages. INFO: prints all level of log messages except DEBUG ones. WARN:
Re: Kanji localization
Hi Nav, 2002/03/20 Wed AM 04:10 Struts Newsgroup (@Basebeans.com) [EMAIL PROTECTED] worote: How do I get Kanji characters work under localization? I made a new Japaneese 'application.resource' file. Even though I made this file, i keep getting 'missing key blah'. Any ideas? Am I missing anything? Which format do I save the file in? UTP8? When you use Japanese Kanji, for example, you save a resource file as application_ja.resource. The format is not normal UTF8 nor Shift_JIS(eusJP and so on). You have to use native2acii command for that file to convert Shift_JIS to ASCII letters wrriten in UTF8. Resource files are general topics for Java programming. You could find a lot of usefull documnets in Web. Thank you, John 2002/03/26 Tue PM 03:41 -- John Daigo Moriwaki [EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Struts plugin for Dreamweaver 4.0
Hello We are implementing Struts on a project, and would like to use the Struts plugin for Dreamweaver 4.0. I could not locate this on macromedia.com Please let me know where I can download this. Andi S. Giri Softsquare winmail.dat Description: application/ms-tnef -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
ActionServlet - thread safe instance variables
Hi As a newbie to Struts (coming from a Turbine background) I was hoping someone would clarify the design issues with having instance variables in the controller servlet. Does this not pose thread safety issues? If so, how does one deal with them? Turbine took the easy way out and declared only local (method) variables, thus ensuring a thread safe controller servlet. Is the reason why ActionServlet uses instance variables because in theory one could have two ActionServlet instances with different url patterns in the same webapp? Is this a common practice or is it not recommended? I have not had any luck finding answers to this question in the mailing list archives. Could someone point me to a resource where I could find the information I need or even give me a brief explanation. Thanks in advance Karim -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]