Tomcat performance - Was Clever trick required
Hi First of all: Please direct these types of questions to the proper maillisting for Tomcat. Tomcat is as I stated, first and foremost a Servlet engine (Reference implementation), and is as such tuned for that. My guess is that if you are having performance problems, that these are due to hardware insuficies. Most likely to little avavailable memory, or that your application is badly written. By badly written I mean for instance that there is a lot of garbage collection occurring. Hermod -Opprinnelig melding- Fra: Martin Gainty [mailto:[EMAIL PROTECTED] Sendt: 18. oktober 2005 15:14 Til: Struts Users Mailing List Emne: Re: Clever trick required Hermod- Currently I am currently running tomcat 5.5.7 and not using any HTTP server for front end If I have no legacy CGI / Perl scripts or static content to server up would I need to front end Tomcat with an HTTP Server? What are the performance considerations for Tomcat standalone vs FrontEnded with an HTTP Server? Takk Martin- - Original Message - From: [EMAIL PROTECTED] To: user@struts.apache.org Sent: Tuesday, October 18, 2005 4:20 AM Subject: SV: Clever trick required Hi Your running Tomcat as an HTTP Server? Why? Tomcat is a Servlet engine and is not optimized for serving static content. You should put Apache Http server in front of it, serving static content. I have Tomcat running on servers, and have seen more that 1200 concurrent sessions on it without any problem at all. Hermod -Opprinnelig melding- Fra: Neil Meyer [mailto:[EMAIL PROTECTED] Sendt: 18. oktober 2005 10:12 Til: Struts Users Mailing List Emne: RE: Clever trick required Hi, I know this is probably of topic but I have huge problems with my webserver. We are running struts on this server under Tomcat 5.1. It seems like the tomcat server can't handle load. Any comment or recommendations will really be appreciated. I'm looking at Sun web server now. Regards Neil Meyer - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This email with attachments is solely for the use of the individual or entity to whom it is addressed. Please also be aware that the DnB NOR Group cannot accept any payment orders or other legally binding correspondence with customers as a part of an email. This email message has been virus checked by the virus programs used in the DnB NOR Group. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: form.submit() issue with html:button
Have you put *submit()* correctly? It works: html:button onclick=document.forms[0].submit(); / 2005/10/19, Carl Smith [EMAIL PROTECTED]: I seem to have a issue using html:button's onclick. My value of onclick is a javascript performing form.submit(), but I found out this is not working. However if I chang my button to html:submit then the javascript is working. Why this is the case? Thanks. - Yahoo! Music Unlimited - Access over 1 million songs. Try it free.
RE: Can't Undeploy Struts Applications
I found the solution in a post to another thread from [EMAIL PROTECTED] Are you using Windows? Than this it no tomcat specific problem. yout struts.jar is not deleted because windows locks this file. i had the same problem. the solution is to add the directory META-INF to your project. put a file named context.xml into it with the following lines: Context reloadable=true antiResourceLocking=true /Context when the attribute antiResourceLocking is set to true tomcat does not use this one but works with an internal copy of it so that windows does not lock it. then everything works fine... Peter -Original Message- From: Prashant Reddy [mailto:[EMAIL PROTECTED] Sent: Friday, May 20, 2005 12:47 PM To: user@struts.apache.org Subject: RE: Can't Undeploy Struts Applications +1. Same here, For me struts-applications dont get re-deployed because the jar - commons-digester.jar is still locked. Donot think its a tomcat problem, coz I am using a different Servlet engine. -Prashant -Original Message- From: Harry Hartley [mailto:[EMAIL PROTECTED] Sent: Friday, May 20, 2005 10:24 AM To: user@struts.apache.org; tomcat-user@jakarta.apache.org Subject: Can't Undeploy Struts Applications Is this a bug? So, I deploy the struts-blank webapp to my webapps directory under tomcat. Everything works fine. Then I try to undeploy it under the manager, and it responds the a message, context undeployed. But when I do a list under the tomcat manager it is still there. If I look under the webapps directory, my struts-blank directory is still there. I look under the application directory under webapps, and I find that the commons-digester.jar, commons-validator.jar, and struts.jar are still there. If I try to delete them, I cannot. My operating complains that these files are still in use by another application. I shut down tomcat, and presto, the application is really undeployed. I actually found this problem working on my own application, and found that the build script failed to (re) deploy even though I undeployed an application. Thus I have two questions: 1) If an application is not fully undeployed, shouldn't the tomcat manager complain about it with a message or warning, rather than just ok? 2) Is there a known issue/bug with tomcat not releasing .jar resources (specifically the ones mentioned above) of applications being undeployed? I have searched under bugzilla, and there seems to be a undeploy bug identified and fixed, but I am not sure if it applies to what I have identified here or not. Versions: Struts 1.2.4 Tomcat: 5.5 J2SE: 5.0 Any Help?!?!? Warm Regards, Harry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What's wrong with DTOs?
[EMAIL PROTECTED] wrote: Hi Bob, I'll try to give my 1 cent to the topic and also to answer you more concrete because I believe you want some concrete answers, not theoretical conversations. Background: I just started a Struts project with Hibernate. I have chosen to use the Data Access Object with (Abstract Factory) design pattern because my client uses Oracle and I use Postgresql database. I am working with other teams remotely and they decided to use DTO. Why do you mention DTO and DAO here together? I think that they are known solutions for very different problems ... (at least my opinion is that DTO doesn't have anything to do with DAO) Btw, Hibernate abstracts already your access to the database (i.e. doesn't matter if it's Oracle or Postgres unless you use some special features from these RDBMS). Just change the driver settings in the hibernate.cfg.xml and it will work transparently with chosen RDBMS. Problem: A few months ago, I recall a message thread on this list with a subject header of: 'DTOs are evil'. Since I am new to this, I am having problems understanding why. I thought that DTO are for data storage and data transfer between Business and Value Objects. Questions: I have the following questions: 1. Why I shouldn't choose it? You will use them even if you don't want - ActionForms are DTOs. They just save you the work to translate the request parameters in more convenient form. You can consider also HttpServletRequest as DTO. ActionForms also have some validation functionality, but I almost never use it (except for the most simple cases). 2. Should I be using the Apache Commons BeanUtils in my action? It has a method like BeanUtils.copyProperties(...). Personally, I use BeanUtils all the time, because it saves me a lot of writing. If your forms change very often i.e. you add/change/delete fields to/from them, then I recommend you mapped forms - a form with a map and all BO properties are copied from BO to this form map and vice versa. The difference is also how do you use the map in jsp tags - instead of writing something like this html:text property=city/ you have to write it html:text property=mapvalues(city)/ When I use mapped forms I can change very fast the whole content of a form because the changes are only in 2 places (where they should be) - in the BO and in the jsp. If you use normal ActionForms any change will force you to touch other 2 files: the struts-config.xml and derived ActionForm class. 3. If not BeanUtils, then what do you recommend? Thanks, Bob The best way is just to try 2-3 different approaches and see what are the advantages and disadvantages of every one. Then you can decide how and when you can use them all or only one. Or say it in other way - first find and define unambiguously what are you problems and then search the appropriate solution. Regards Borislav - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What's wrong with DTOs?
On 10/19/05, Martin Gainty [EMAIL PROTECTED] wrote: George Could you explain on how MVC patterns are fractal? Thanks, Martin- I think there are no fractal patterns, but fractal architectures, which follows same pattern in different levels. Example: a typical 3-tier can be considered MVC the presentation layer in the 3-tier could itself be an MVC too (jsp the view, action the controller, bean the model)... Therefore fractal, using same pattern in part of the pattern again. :-) Leon - Original Message - From: [EMAIL PROTECTED] To: user@struts.apache.org Sent: Tuesday, October 18, 2005 4:49 PM Subject: RE: What's wrong with DTOs? From: Leon Rosenberg P.S. Have you ever considered, that the View itself can be an MVC as well? Yes, patterns are fractal. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Shale] JspTilesViewHandlerImpl and Shale
Hi Has anybody successfully made org.apache.myfaces.application.jsp.JspTilesViewHandlerImpl work with Shale? Meaning that Tiles definitions can successfully be accessed as pages. I.e somepage.jsf will be mapped to somepage.tiles (a tiles definintion) Hermod * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This email with attachments is solely for the use of the individual or entity to whom it is addressed. Please also be aware that DnB NOR cannot accept any payment orders or other legally binding correspondence with customers as a part of an email. This email message has been virus checked by the virus programs used in the DnB NOR Group. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Default values for Multiple Select
Paul, I am dealing with a multiple select tag... Ie html:select property=userroles multiple =true html:optionsCollection property=userroles / /html:select Natalie -Original Message- From: Paul Benedict [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 18, 2005 7:11 PM To: Struts Users Mailing List Subject: Re: Default values for Multiple Select Natalie, Your question isn't clear If you're dealing with multiple checkboxes, the property backing them should be a String[] so you can capture all the values selected. If you're dealing with multiple options of a radio group, only one option will ever be selected. Paul __ Yahoo! Music Unlimited Access over 1 million songs. Try it free. http://music.yahoo.com/unlimited/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: form.submit() issue with html:button
Good Morning Carl excerpted from Craig: The challenge with doing this is that the JSP tags run on the server (as the page is being generated), while the JavaScript runs on the client side. To integrate the two, you need your tags (and other JSP code) to dynamically generate the JavaScript functions themselves -- sort of having a program write a program -- so that the JavaScript is customized to your particular need on this particular page. A very trivial example is the way that the html:form tag deals with the focus attribute. If you specify it, a dynamically generated bit of JavaScript is created to set the input focus, which includes the name of the field you want initial focus assigned to. html:submit (submit button class) is derived from same parent as html:form (javax.servlet.jsp.tagext.TagSupport) so the characteristic of a server side Tag class(dynamically) generating JavaScript holds true Does this answer your question? Martin- - Original Message - From: Carl Smith [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, October 18, 2005 10:13 PM Subject: form.submit() issue with html:button I seem to have a issue using html:button's onclick. My value of onclick is a javascript performing form.submit(), but I found out this is not working. However if I chang my button to html:submit then the javascript is working. Why this is the case? Thanks. - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What's wrong with DTOs?
On 10/19/05, Leon Rosenberg [EMAIL PROTECTED] wrote: I think there are no fractal patterns, but fractal architectures, which follows same pattern in different levels. Example: a typical 3-tier can be considered MVC the presentation layer in the 3-tier could itself be an MVC too (jsp the view, action the controller, bean the model)... Therefore fractal, using same pattern in part of the pattern again. And, as it stands, I believe we tend to leave too much of the work to the presentation layer framework. In most the MVC diagrams, the business layer is a little box marked There lie POJOs. Readers are left with the implication that the only place where we can have standardization, the only place where we can share utility between projects, is the presentation layer. I believe that many tasks we now leave to presentation layer frameworks -- like Struts, Spring MVC, WebWork, et al. -- can just as easily be handled by a business layer framework. Chores like data conversion, formatting, validation, and localization do not need to be done by every presentation layer. Many tasks can just as easily be done by a business layer framework and then shared between presentation layers. After all, it's not presentation layer that cares whether we use commas or dots. It's the *business* people who care. To the presentation, it's all arbitrary text that needs to injected into the markup stream. The presentation layer is not about text or data, it's about markup. If we consider unit tests to be a presentation layer, then *every* application should be designed to work with multiple presentation layers. The testing layer and the shipping layer. If we start thinking along these lines, then DTOs become more useful again. DTOs are how an application layered with fractal fameworks communicates. Of course, not all DTOs need to be dirt stupid. The original HTTP request carries only values. But, the Java HttpRequest includes many helper methods. Ditto for an ActionForm. Likewise, we can pass a DTO from an Action to a business layer framework using a DTO that not only carries data, but includes helper methods to adapt the data to Struts (or any given presentation layer). -Ted. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Shale] JspTilesViewHandlerImpl and Shale
Hi Hermon, I use tiles with Shale, but Shale uses the stand-alone tiles, so I'm not sure which view handler is used. But it works ok. On 19/10/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Hi Has anybody successfully made org.apache.myfaces.application.jsp.JspTilesViewHandlerImpl work with Shale? Meaning that Tiles definitions can successfully be accessed as pages. I.e somepage.jsf will be mapped to somepage.tiles (a tiles definintion) Hermod * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This email with attachments is solely for the use of the individual or entity to whom it is addressed. Please also be aware that DnB NOR cannot accept any payment orders or other legally binding correspondence with customers as a part of an email. This email message has been virus checked by the virus programs used in the DnB NOR Group. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SV: [Shale] JspTilesViewHandlerImpl and Shale
Shale has it's own tiles viewhandler that uses tiles stand-alone. And it does allow accessing tiles as pages. On 19/10/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote on 10/19/2005 09:24:01 AM: Hi Ronald Can you access pages as tiles-definitions? I mean not just using jsp pages with tiles:insert? Hermod ..Jumping in.. Ronald, I can access my pages as tiles defintions. What kind of problem are you running into? Geeta - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SV: SV: [Shale] JspTilesViewHandlerImpl and Shale
Hi Are you using the TilesViewHandler from shale-tiles or JspTilesViewHandlerImpl from Tomahawk ? -Opprinnelig melding- Fra: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sendt: 19. oktober 2005 15:29 Til: Struts Users Mailing List Emne: Re: SV: [Shale] JspTilesViewHandlerImpl and Shale [EMAIL PROTECTED] wrote on 10/19/2005 09:24:01 AM: Hi Ronald Can you access pages as tiles-definitions? I mean not just using jsp pages with tiles:insert? Hermod ..Jumping in.. Ronald, I can access my pages as tiles defintions. What kind of problem are you running into? Geeta * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This email with attachments is solely for the use of the individual or entity to whom it is addressed. Please also be aware that DnB NOR cannot accept any payment orders or other legally binding correspondence with customers as a part of an email. This email message has been virus checked by the virus programs used in the DnB NOR Group. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SV: SV: SV: [Shale] JspTilesViewHandlerImpl and Shale
Hi Weird. I just took one of my working MyFaces/Tiles projects, and introduced Shale/Clay/Spring configuration to it along with the approprate .jar files. After that the tiles definitions stopped working. I'll try to make myself a simple sample based on the shale usecases and see if I can get that working. Hermod -Opprinnelig melding- Fra: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sendt: 19. oktober 2005 15:49 Til: Struts Users Mailing List Emne: Re: SV: SV: [Shale] JspTilesViewHandlerImpl and Shale [EMAIL PROTECTED] wrote on 10/19/2005 09:45:17 AM: Hi Are you using the TilesViewHandler from shale-tiles or JspTilesViewHandlerImpl from Tomahawk ? I am using Shale's org.apache.shale.tiles.TilesViewHandler. But I am also using tomahawk and am (so far!) having no trouble.. Geeta * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This email with attachments is solely for the use of the individual or entity to whom it is addressed. Please also be aware that DnB NOR cannot accept any payment orders or other legally binding correspondence with customers as a part of an email. This email message has been virus checked by the virus programs used in the DnB NOR Group. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SV: SV: SV: [Shale] JspTilesViewHandlerImpl and Shale
[EMAIL PROTECTED] wrote on 10/19/2005 09:53:55 AM: Hi Weird. I just took one of my working MyFaces/Tiles projects, and introduced Shale/Clay/Spring configuration to it along with the approprate .jar files. After that the tiles definitions stopped working. I'll try to make myself a simple sample based on the shale usecases and see if I can get that working. Hermod Hermod, when i first started working with tiles and shale I got a simple sample working. You can download it here: http://www.sightsoftware.com/shale/ This was one of my very first attempts to get *anything* working with shale, so use at your own risk..:) Geeta
Re: What's wrong with DTOs?
Let it never be said that the myriad OT discussions on the Struts mailing list aren't worth something :) -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 8:50 am, [EMAIL PROTECTED] said: Thanks to all who responded. I am so much wiser now..:) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Shale] JspTilesViewHandlerImpl and Shale
From: [EMAIL PROTECTED] Weird. I just took one of my working MyFaces/Tiles projects, and introduced Shale/Clay/Spring configuration to it along with the approprate .jar files. After that the tiles definitions stopped working. What .jar files did you introduce? If you're missing tiles-core-SNAPSHOT.jar that might be the problem. There are two versions of Tiles. MyFaces uses Struts Tiles; you'll find struts.jar in their tiles example webapp. Shale's Tiles integration is with Stand-alone Tiles, which is currently in the sandbox. As the name suggests, it doesn't depend on Struts. There is a snapshot of Stand-alone Tiles available here: http://cvs.apache.org/repository/tiles/jars/ . HTH, Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SV: Struts and Compression Filter...
Thanks for link! Tried it but same problem. I'm starting to think that it might have something to do with forwards or the container... :( Anyone else out there using response-manipulating-filters with struts? TIA Ulf -Ursprungligt meddelande- Från: Frank W. Zammetti [mailto:[EMAIL PROTECTED] Skickat: den 19 oktober 2005 15:58 Till: Struts Users Mailing List Kopia: Struts Users Mailing List Ämne: Re: Struts and Compression Filter... I *vaguely* remember solving that problem for the CompressionFilter in Java Web Parts (http://javawebparts.sourceforge.net). IIRC, it had something to do with... well, never mind, I don't remember! :) The point is though that the problem affected output from servlets but not directly-accessed resources, which sounds eerily familiar. Maybe you could try the JWP version of the filter and see if it works? If it does I can check the revision history and see what I changed to fix it (I'm sure I noted the change in the history at least, so I know what version the fix appeared in). -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 8:13 am, Nilsson Ulf /Konsult said: Hi! I'm trying to add a compression filter, http://archive.moreservlets.com/Filter-Code/filters/WEB-INF/classes/more servlets/filters/CompressionFilter.java To my web-app. I want the filter to compress everything that the action servlet returns (forwards). (mapping = *.do) However I can't get this to work. Pages just return empty. (the filter works for *.jsp etc) I'm using Struts 1.2.4 and a servlet 2.3 container (Sybase EAServer). Has anyone out there successfully used compression filters with struts? TIA, Ulf Nilsson - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Conditional validation for mask, date, integer etc
Hi All, I'm wondering if there is a way to define conditional validation for mask, date, integer etc in validation.xml. I know there is a validwhen, but it only checks for the condition as defined by the test variable. What I want is to perform the mask, date validation only some conditions are met. I wonder if there is a way to do that? Any points are welcome. thanks, Saul - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SV: Struts and Compression Filter...
That's weird... I just threw it in a Struts app and it worked (mapped it to every request by the way), so I wonder what your app is doing that breaks both filters... could very well be a flaw in both filter implementations, that's not at all out of the question. -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 10:35 am, Nilsson Ulf /Konsult said: Thanks for link! Tried it but same problem. I'm starting to think that it might have something to do with forwards or the container... :( Anyone else out there using response-manipulating-filters with struts? TIA Ulf -Ursprungligt meddelande- Från: Frank W. Zammetti [mailto:[EMAIL PROTECTED] Skickat: den 19 oktober 2005 15:58 Till: Struts Users Mailing List Kopia: Struts Users Mailing List Ämne: Re: Struts and Compression Filter... I *vaguely* remember solving that problem for the CompressionFilter in Java Web Parts (http://javawebparts.sourceforge.net). IIRC, it had something to do with... well, never mind, I don't remember! :) The point is though that the problem affected output from servlets but not directly-accessed resources, which sounds eerily familiar. Maybe you could try the JWP version of the filter and see if it works? If it does I can check the revision history and see what I changed to fix it (I'm sure I noted the change in the history at least, so I know what version the fix appeared in). -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 8:13 am, Nilsson Ulf /Konsult said: Hi! I'm trying to add a compression filter, http://archive.moreservlets.com/Filter-Code/filters/WEB-INF/classes/more servlets/filters/CompressionFilter.java To my web-app. I want the filter to compress everything that the action servlet returns (forwards). (mapping = *.do) However I can't get this to work. Pages just return empty. (the filter works for *.jsp etc) I'm using Struts 1.2.4 and a servlet 2.3 container (Sybase EAServer). Has anyone out there successfully used compression filters with struts? TIA, Ulf Nilsson - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Moving from Struts 1.0.2 to 1.2.7. Encountering problems
Hello, We are in process of moving to different IDE and at same time have decided to upgrade to Struts 1.2.7. Started out with a just two pages from an app that is running fine in our current environment. It consists of a login page and a viewPrices.jsp page. Upon valid login the user is supposed to see the viewPrices.jsp page. Using the debugger to step thru the execute method of my LoginAction class I can see that it's finding my action mapping and pointing to the right jsp page. However, after it exits the execute method of my LoginAction class I get the following error: Cannot get request dispatcher for path viewPrices.jsp If I try open the viewPrices.jsp file directly in the browser it comes up fine. Thanks in advance for any help. David. Not sure what to include to help you help me so if you need anything else please let me know. I've downloaded and placed the following files in my WEB-INF\lib folder: - struts.jar - antlr.jar - commons-beanutils.jar - commons-digester.jar - commons-fileupload.jar - commons-logging.jar - commons-validator.jar - jakarta-oro.jar I have also downloaded the following tlds and placed them in my WEB-INF folder - struts-bean.tld - struts-html.tld - struts-logic.tld Here is the content of my web.xml file: ?xml version=1.0 encoding=UTF-8? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameWEB APP/display-name descriptionWEB APP description/description servlet servlet-nameaction/servlet-name servlet-classorg.apache.struts.action.ActionServlet /servlet-class init-param param-nameconfig/param-name param-value/WEB-INF/struts-config.xml/param-value /init-param init-param param-namedebug/param-name param-value2/param-value /init-param init-param param-namedetail/param-name param-value2/param-value /init-param load-on-startup2/load-on-startup /servlet servlet servlet-namelogin.jsp/servlet-name jsp-file/login.jsp/jsp-file /servlet servlet servlet-nameviewPrices.jsp/servlet-name jsp-file/viewPrices.jsp/jsp-file /servlet servlet-mapping servlet-nameaction/servlet-name url-pattern/forms/*/url-pattern /servlet-mapping /web-app Here is the content of my struts-config.sml file: ?xml version=1.0 encoding=UTF-8 ? !DOCTYPE struts-config PUBLIC -//Apache Software Foundation//DTD Struts Configuration 1.0//EN http://fe-dev/jds/struts-config_1_1.dtd; struts-config form-beans form-bean name=rtpForm type=com.firstenergycorp.hep.RTPForm/ /form-beans action-mappings action path=/viewPrices type=com.firstenergycorp.hep.ViewPricesAction name=rtpForm scope=session input=viewPrices.jsp forward name=viewPrices path=viewPrices.jsp/ /action action path=/login type=com.firstenergycorp.hep.LoginAction name=rtpForm scope=session input=login.jsp forward name=viewPrices path=viewPrices.jsp/ /action /action-mappings /struts-config - The information contained in this message is intended only for the personal and confidential use of the recipient(s) named above. If the reader of this message is not the intended recipient or an agent responsible for delivering it to the intended recipient, you are hereby notified that you have received this document in error and that any review, dissemination, distribution, or copying of this message is strictly prohibited. If you have received this communication in error, please notify us immediately, and delete the original message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SV: Struts and Compression Filter...
Nilsson Ulf /Konsult wrote: Anyone else out there using response-manipulating-filters with struts? I've used the filter from... um... _Core Servlets and JSP_ w/ zero problems, but IIRC we mapped it to everything. Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat performance - Was Clever trick required
I have noted your comments Thank You for responding Good Luck, Martin- - Original Message - From: [EMAIL PROTECTED] To: user@struts.apache.org Sent: Wednesday, October 19, 2005 2:00 AM Subject: Tomcat performance - Was Clever trick required Hi First of all: Please direct these types of questions to the proper maillisting for Tomcat. Tomcat is as I stated, first and foremost a Servlet engine (Reference implementation), and is as such tuned for that. My guess is that if you are having performance problems, that these are due to hardware insuficies. Most likely to little avavailable memory, or that your application is badly written. By badly written I mean for instance that there is a lot of garbage collection occurring. Hermod -Opprinnelig melding- Fra: Martin Gainty [mailto:[EMAIL PROTECTED] Sendt: 18. oktober 2005 15:14 Til: Struts Users Mailing List Emne: Re: Clever trick required Hermod- Currently I am currently running tomcat 5.5.7 and not using any HTTP server for front end If I have no legacy CGI / Perl scripts or static content to server up would I need to front end Tomcat with an HTTP Server? What are the performance considerations for Tomcat standalone vs FrontEnded with an HTTP Server? Takk Martin- - Original Message - From: [EMAIL PROTECTED] To: user@struts.apache.org Sent: Tuesday, October 18, 2005 4:20 AM Subject: SV: Clever trick required Hi Your running Tomcat as an HTTP Server? Why? Tomcat is a Servlet engine and is not optimized for serving static content. You should put Apache Http server in front of it, serving static content. I have Tomcat running on servers, and have seen more that 1200 concurrent sessions on it without any problem at all. Hermod -Opprinnelig melding- Fra: Neil Meyer [mailto:[EMAIL PROTECTED] Sendt: 18. oktober 2005 10:12 Til: Struts Users Mailing List Emne: RE: Clever trick required Hi, I know this is probably of topic but I have huge problems with my webserver. We are running struts on this server under Tomcat 5.1. It seems like the tomcat server can't handle load. Any comment or recommendations will really be appreciated. I'm looking at Sun web server now. Regards Neil Meyer - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This email with attachments is solely for the use of the individual or entity to whom it is addressed. Please also be aware that the DnB NOR Group cannot accept any payment orders or other legally binding correspondence with customers as a part of an email. This email message has been virus checked by the virus programs used in the DnB NOR Group. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Conditional validation for mask, date, integer etc
On my current project I've written a validation method that dynamically invokes other validation rules depending on the String returned by bean.getDepends() It's used with indexed properties where the fields for the form to fill in are configurable and come from a database. Is that what you're after? Stew On 19/10/05, Saul Qunming Yuan [EMAIL PROTECTED] wrote: Hi All, I'm wondering if there is a way to define conditional validation for mask, date, integer etc in validation.xml. I know there is a validwhen, but it only checks for the condition as defined by the test variable. What I want is to perform the mask, date validation only some conditions are met. I wonder if there is a way to do that? Any points are welcome. thanks, Saul - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
changing the documentroot prefix, or relative paths
Hello, I didn't find this in the archives, so I'll ask. I have a tomcat app deployed via proxypass from apache (2 in fact, a double-proxy through 2 servers). It needs to use relative paths in its links to ensure that the composed path is correct. Unfortunately struts doesn't seem to want to use relative links. So, 1. Is there a way to make it use a relative link instead of an absolute one? 2. Is there a way to force a prefix on the link? Basically, the tomcat app is deployed as application me. Instead of links like /me I want /foo/bar/me Is this possible? Thanks, Mike -- Michael P. Soulier [EMAIL PROTECTED], 613-592-2122 x2522 Linux applications development ...the word HACK is used as a verb to indicate a massive amount of nerd-like effort. -Harley Hahn, A Student's Guide to Unix smime.p7s Description: S/MIME Cryptographic Signature
Re: Conditional validation for mask, date, integer etc
That's simlar to what I need, except that it's not an indexd property. Can some of your code or send it to me offline. thanks, Saul On my current project I've written a validation method that dynamically invokes other validation rules depending on the String returned by bean.getDepends() It's used with indexed properties where the fields for the form to fill in are configurable and come from a database. Is that what you're after? Stew On 19/10/05, Saul Qunming Yuan [EMAIL PROTECTED] wrote: Hi All, I'm wondering if there is a way to define conditional validation for mask, date, integer etc in validation.xml. I know there is a validwhen, but it only checks for the condition as defined by the test variable. What I want is to perform the mask, date validation only some conditions are met. I wonder if there is a way to do that? Any points are welcome. thanks, Saul - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: changing the documentroot prefix, or relative paths
On 10/19/05, Michael P. Soulier [EMAIL PROTECTED] wrote: Hello, I didn't find this in the archives, so I'll ask. I have a tomcat app deployed via proxypass from apache (2 in fact, a double-proxy through 2 servers). It needs to use relative paths in its links to ensure that the composed path is correct. Unfortunately struts doesn't seem to want to use relative links. So, 1. Is there a way to make it use a relative link instead of an absolute one? I wonder why Struts doesn't handle the relative links (ie Relative to the current servlet) at all. In the RequestProcessor's processForwardConfig, there is in fact a comment saying paths not starting with / should be passed through without any processing (ie. they're absolute) [or relative to the current servlet] And it calls the doForward to do the forward which just gets the RequestDispatcher from the ServletContext. The J2EE API says that the RequestDispatcher acquired from the ServletContext expects a path starting with /. I think if the path doesn't start with a / then the doForward should be getting the RequestDispatcher from the Request which accepts links relative to the current servlet. Is this a bug or am I missing something? Anyway for you current task, I guess you can override the RequestProcessor's doForward to handle the links relative to the current servlet using the RequestDispatcher from the request. 2. Is there a way to force a prefix on the link? I think you can do the following way, but I don't know if it's recommended. Basically you would create a prefix or a module like /foo/bar/me. (Just loading the config file with a contextParam config/foo/bar/me for the struts-config.xml). Struts will make the module or the path prefix as part of the links and you have to also make the contextPath to be / instead of me to the Struts App. One way would be to have a Filter which just wraps the request with HttpRequestWrapper and overriding the getContextPath to return /. But for the outside world and the proxies the contextPath would still be me and everything should work as normal for those. Basically, the tomcat app is deployed as application me. Instead of links like /me I want /foo/bar/me Is this possible? Thanks, Mike -- Michael P. Soulier [EMAIL PROTECTED], 613-592-2122 x2522 Linux applications development ...the word HACK is used as a verb to indicate a massive amount of nerd-like effort. -Harley Hahn, A Student's Guide to Unix
validator error highlighting
html:form... .. ... td html:text name=Form1 property=name size=40 errorStyleClass=errormessage/ /td /html:form Css is working except for this. When I hit the submit button it just forwards to the different jsp. it doesn't validate the field which I set to be required. I did make it null. Is there anything else that needs to be done in jsp? Thanks. _ FREE pop-up blocking with the new MSN Toolbar get it now! http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[ot] Need Design help for Axis ComplextTypes to ActionForms please...anyone?
I have a WSDL that is managed and generated by a different group than mine. This wsdl has many complex types within complex types for each service. Thus I get composite objects being generated, and we use a flattened version of these objects in our Struts UI. But Currently, we create an ActionForm and an interface that Mirrors the ComplextType that was generated, but has additional fields for the fields. Like I have a micrType that is an RTN and BankAccount, and my Action form just has RTN and BankAccount instead of micrType. I want to use the BeanUtils.copyProperties() but my names need to match. Thus when the names in the WSDL change, I am unable to get notified of that change directly, I just don't get those properties copied, and now I have a bug. So, if I can't have the WSDL define Parent Abstract Classes for these types, What am I suppose to do to keep some type of interface between my ActionForms and my ComplextTypes? Besides going through by hand each time there is an update and making changes by hand, then having to verify by hand that the changes get reflected in my ActionForms? Thank You Mick Knutson Sr. Java/J2EE Consultant BASE logic, inc. (415) 648-1804 (S.F., CA) http://www.BASELogic.com HP Consulting Services (Walnut Creek, CA) MMS safeway.com made the following annotations. -- Warning: All e-mail sent to this address will be received by the Safeway corporate e-mail system, and is subject to archival and review by someone other than the recipient. This e-mail may contain information proprietary to Safeway and is intended only for the use of the intended recipient(s). If the reader of this message is not the intended recipient(s), you are notified that you have received this message in error and that any review, dissemination, distribution or copying of this message is strictly prohibited. If you have received this message in error, please notify the sender immediately. == - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [ot] Need Design help for Axis ComplextTypes to ActionForms please...anyone?
Good Morning Mick Stupid question but I'll ask anyway ..I'm assuming you have already used Axis wsdl2java to automate the generation of the Java Class? http://ws.apache.org/axis/java/user-guide.html#WSDL2JavaBuildingStubsSkeletonsAndDataTypesFromWSDL Martin- - Original Message - From: Mick Knutson [EMAIL PROTECTED] To: user@struts.apache.org Sent: Wednesday, October 19, 2005 2:36 PM Subject: [ot] Need Design help for Axis ComplextTypes to ActionForms please...anyone? I have a WSDL that is managed and generated by a different group than mine. This wsdl has many complex types within complex types for each service. Thus I get composite objects being generated, and we use a flattened version of these objects in our Struts UI. But Currently, we create an ActionForm and an interface that Mirrors the ComplextType that was generated, but has additional fields for the fields. Like I have a micrType that is an RTN and BankAccount, and my Action form just has RTN and BankAccount instead of micrType. I want to use the BeanUtils.copyProperties() but my names need to match. Thus when the names in the WSDL change, I am unable to get notified of that change directly, I just don't get those properties copied, and now I have a bug. So, if I can't have the WSDL define Parent Abstract Classes for these types, What am I suppose to do to keep some type of interface between my ActionForms and my ComplextTypes? Besides going through by hand each time there is an update and making changes by hand, then having to verify by hand that the changes get reflected in my ActionForms? Thank You Mick Knutson Sr. Java/J2EE Consultant BASE logic, inc. (415) 648-1804 (S.F., CA) http://www.BASELogic.com HP Consulting Services (Walnut Creek, CA) MMS safeway.com made the following annotations. -- Warning: All e-mail sent to this address will be received by the Safeway corporate e-mail system, and is subject to archival and review by someone other than the recipient. This e-mail may contain information proprietary to Safeway and is intended only for the use of the intended recipient(s). If the reader of this message is not the intended recipient(s), you are notified that you have received this message in error and that any review, dissemination, distribution or copying of this message is strictly prohibited. If you have received this message in error, please notify the sender immediately. == - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Adding images to option items in a select drop down list
Hi, I am creating a drop down list using the HTML select and option tags. The items in the list will be color names (ex. red, green, blue, etc..). I would like a small square image to be next to each color name text in the list. How would I go about this in my jsp file with my struts tags? -Faisal -- http://www.quidprocode.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [ot] Need Design help for Axis ComplextTypes to ActionForms please...anyone?
Martin Gainty wrote: I'm assuming you have already used Axis wsdl2java to automate the generation of the Java Class? http://ws.apache.org/axis/java/user-guide.html#WSDL2JavaBuildingStubsSkeletonsAndDataTypesFromWSDL Or if that doesn't do what you need, just write a simple script in Perl/Python/Jython/Ruby/Lisp to parse the WSDL and write out the classes for you; I use this strategy in one way or another quite often (usually in Ruby now, used to use Jython). Code generation good, hand-rolling bad. Dave Newton Technical Lead, Project MonkeyLips Omnigalgomon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Adding images to option items in a select drop down list
Faisal Mahmoud wrote: I am creating a drop down list using the HTML select and option tags. The items in the list will be color names (ex. red, green, blue, etc..). I would like a small square image to be next to each color name text in the list. How would I go about this in my jsp file with my struts tags? By rewriting the browser. I've never seen a browser support anything other than text inside a select box w/o using a plugin of some sort (flash, applet, etc.) Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
issue with logic:present on JDK 1.4.2
Hi, I'm doing an upgrade from JDK 1.3.1 to JDK 1.4.2 for my Struts 1.1 applications. I have an issue with the logic:present tags. These don't seem to work with JDK 1.4.2 version. I'm using OC4J 9.0.4 as my application server. For the JSP code snippet shown below , I get an error message: quote: JspServlet: unable to dispatch to requested page: oracle.jsp.provider.JspCompileException: H3Errors compiling:[jsp src:line #:133]br cannot resolve symbol: variable userRequest unquote: ### logic:present name=userRequest scope=session bean:define id=userRequest name=userRequest scope=session type=dsap.business.UserRequest/ bean:define id=employee name=userRequest property=employee type=dsap.business.Employee / bean:define id=userModuleList name=userRequest property=userModuleList / /logic:present ### This used to work well with JDK 1.3.1. Could somebody suggest a solution or a workaround ? I would not want to use JSTL. Any help will be greatly appreciated. Thanks, Shyam __ Yahoo! Music Unlimited Access over 1 million songs. Try it free. http://music.yahoo.com/unlimited/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Adding images to option items in a select drop down list
This isn's something that is possible in straight HTML. There could be a way to do it via CSS, but nothing obvious presents itself to me... I tried setting a background-image, but that didn't work. Can you find an example of it being done? Unless there's some non-obvious CSS trick, or perhaps some non-standard browser extension, I'd bet this isn't possible. -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 3:01 pm, Faisal Mahmoud said: Hi, I am creating a drop down list using the HTML select and option tags. The items in the list will be color names (ex. red, green, blue, etc..). I would like a small square image to be next to each color name text in the list. How would I go about this in my jsp file with my struts tags? -Faisal -- http://www.quidprocode.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Adding images to option items in a select drop down list
Just thought of this... one thing you could do is set the text color of each option. That *does* work. Might serve your purpose alright. You can actually set the color style attribute or background-color, both work. -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 3:10 pm, Dave Newton said: Faisal Mahmoud wrote: I am creating a drop down list using the HTML select and option tags. The items in the list will be color names (ex. red, green, blue, etc..). I would like a small square image to be next to each color name text in the list. How would I go about this in my jsp file with my struts tags? By rewriting the browser. I've never seen a browser support anything other than text inside a select box w/o using a plugin of some sort (flash, applet, etc.) Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: issue with logic:present on JDK 1.4.2
Shyam Anand wrote: These don't seem to work with JDK 1.4.2 version. I'm running 1.4.2 w/o any JSTL issues. (Tomcat, WinXP, 1.4.2_08) Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Adding images to option items in a select drop down list
Frank W. Zammetti wrote: Just thought of this... one thing you could do is set the text color of each option. That *does* work. Might serve your purpose alright. You can actually set the color style attribute or background-color, both work. Looks funny when you roll over it. Still and all, kinda handy for something, I'm sure. Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Adding images to option items in a select drop down list
On Wed, October 19, 2005 3:20 pm, Dave Newton said: Looks funny when you roll over it. Still and all, kinda handy for something, I'm sure. Yeah, I thought so too... might be some CSS tricks you could play to keep the color the same when hovered over... I just tried some obvious things, none worked. Maybe someone smarter than me (I don't set the bar very high, do I?!?)... Dave Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Adding images to option items in a select drop down list
And insert a #149; in front of the text in a larger font size (But same line height). This will give you a circle, but not a square. -Original Message- From: Frank W. Zammetti [mailto:[EMAIL PROTECTED] Sent: 19 October 2005 20:13 To: Struts Users Mailing List Cc: Struts Users Mailing List Subject: Re: Adding images to option items in a select drop down list Just thought of this... one thing you could do is set the text color of each option. That *does* work. Might serve your purpose alright. You can actually set the color style attribute or background-color, both work. -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 3:10 pm, Dave Newton said: Faisal Mahmoud wrote: I am creating a drop down list using the HTML select and option tags. The items in the list will be color names (ex. red, green, blue, etc..). I would like a small square image to be next to each color name text in the list. How would I go about this in my jsp file with my struts tags? By rewriting the browser. I've never seen a browser support anything other than text inside a select box w/o using a plugin of some sort (flash, applet, etc.) Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Moving from Struts 1.0.2 to 1.2.7. Encountering problems
action path=/login type=com.firstenergycorp.hep.LoginAction name=rtpForm scope=session input=login.jsp forward name=viewPrices path=viewPrices.jsp/ /action In the above configuration try for the forward's path as /viewPrices.jsp instead of viewPrices.jsp
Re: form.submit() issue with html:button
What I really want to know is how to use html:button and still using onclick to call javascript to submit the form. Martin Gainty [EMAIL PROTECTED] wrote:Good Morning Carl excerpted from Craig: The challenge with doing this is that the JSP tags run on the server (as the page is being generated), while the JavaScript runs on the client side. To integrate the two, you need your tags (and other JSP code) to dynamically generate the JavaScript functions themselves -- sort of having a program write a program -- so that the JavaScript is customized to your particular need on this particular page. A very trivial example is the way that the tag deals with the focus attribute. If you specify it, a dynamically generated bit of JavaScript is created to set the input focus, which includes the name of the field you want initial focus assigned to. html:submit (submit button class) is derived from same parent as html:form (javax.servlet.jsp.tagext.TagSupport) so the characteristic of a server side Tag class(dynamically) generating JavaScript holds true Does this answer your question? Martin- - Original Message - From: Carl Smith To: Struts Users Mailing List Sent: Tuesday, October 18, 2005 10:13 PM Subject: form.submit() issue with I seem to have a issue using 's onclick. My value of onclick is a javascript performing form.submit(), but I found out this is not working. However if I chang my button to then the javascript is working. Why this is the case? Thanks. - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Music Unlimited - Access over 1 million songs. Try it free.
Re: Adding images to option items in a select drop down list
At 3:11 PM -0400 10/19/05, Frank W. Zammetti wrote: This isn's something that is possible in straight HTML. There could be a way to do it via CSS, but nothing obvious presents itself to me... I tried setting a background-image, but that didn't work. Can you find an example of it being done? Unless there's some non-obvious CSS trick, or perhaps some non-standard browser extension, I'd bet this isn't possible. Here's an example of something a user might not distinguish from what is described, although it wouldn't be using select http://script.aculo.us/demos/ajax/autocompleter_customized By using DHTML like this and having an event cause a hidden form field value to be set, you could achieve the goal. Note that Scriptaculous builds upon the Prototype library, which breaks commons-validator client side javascript validation. Joe -- Joe Germuska [EMAIL PROTECTED] http://blog.germuska.com Narrow minds are weapons made for mass destruction -The Ex - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: I am getting frustrated with LookupDispatchAction
Hey everyone. Thanks for the input on my problems with my LookupDispatchAction. I was able to get the wizard steps working using the example on page 201 of the book: Jakarta Struts Cookbook. Now I am off to do the business logic. Again, thanks for all the help. --Brad -Original Message- From: Simonin, Bradley K. (Brad) Sent: Mon 10/17/2005 4:18 PM To: user@struts.apache.org Subject: I am getting frustrated with LookupDispatchAction Hi. I am using struts 1.2.7. My struts-config-xml file has the following: action path=/mywizard1 name=wizardForm scope=session type=edu.nmsu.psl.userwizard.AddPSLUserWizardAction input=/step1.jsp validate=false parameter=method forward name=next path=/step2.jsp/ /action my jsp has the following: html:submit property=methodbean:message key=button.next//html:submit But I get the following error in tomcat: javax.servlet.ServletException: Request[/mywizard1] does not contain handler parameter named 'method'. Can someone save me from insanity? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [ot] Need Design help for Axis ComplextTypes to ActionForms please...anyone?
I am forced to use the Websphere Axis libraries, and yes generate classes just fine. But I can't get them to adhere to MY interface, or MAKE these Types extend an Abstract Class of my own. At least that I can see. I also have about 1,000 different types being generated in our project. So, is there a way to make these java files extend my own Abstract Class? What about making them extend my interface as well? This way my interface for my ActionForms and the ComplexTypes are the same and always in Sync. -Original Message- From: Dave Newton [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 19, 2005 12:03 PM To: Struts Users Mailing List Subject: Re: [ot] Need Design help for Axis ComplextTypes to ActionForms please...anyone? Martin Gainty wrote: I'm assuming you have already used Axis wsdl2java to automate the generation of the Java Class? http://ws.apache.org/axis/java/user-guide.html#WSDL2JavaBuildingStubsS keletonsAndDataTypesFromWSDL Or if that doesn't do what you need, just write a simple script in Perl/Python/Jython/Ruby/Lisp to parse the WSDL and write out the classes for you; I use this strategy in one way or another quite often (usually in Ruby now, used to use Jython). Code generation good, hand-rolling bad. Dave Newton Technical Lead, Project MonkeyLips Omnigalgomon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] MMS safeway.com made the following annotations. -- Warning: All e-mail sent to this address will be received by the Safeway corporate e-mail system, and is subject to archival and review by someone other than the recipient. This e-mail may contain information proprietary to Safeway and is intended only for the use of the intended recipient(s). If the reader of this message is not the intended recipient(s), you are notified that you have received this message in error and that any review, dissemination, distribution or copying of this message is strictly prohibited. If you have received this message in error, please notify the sender immediately. == - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Adding images to option items in a select drop down list
I was thinking you could build an actual custom control to do this, and that's a good start... add a down arrow to the right of it to show the dropdown portion and lock the textbox from editing and you'd have a good start. Thanks Joe! -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 3:51 pm, Joe Germuska said: At 3:11 PM -0400 10/19/05, Frank W. Zammetti wrote: This isn's something that is possible in straight HTML. There could be a way to do it via CSS, but nothing obvious presents itself to me... I tried setting a background-image, but that didn't work. Can you find an example of it being done? Unless there's some non-obvious CSS trick, or perhaps some non-standard browser extension, I'd bet this isn't possible. Here's an example of something a user might not distinguish from what is described, although it wouldn't be using select http://script.aculo.us/demos/ajax/autocompleter_customized By using DHTML like this and having an event cause a hidden form field value to be set, you could achieve the goal. Note that Scriptaculous builds upon the Prototype library, which breaks commons-validator client side javascript validation. Joe -- Joe Germuska [EMAIL PROTECTED] http://blog.germuska.com Narrow minds are weapons made for mass destruction -The Ex - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Adding images to option items in a select drop down list
Okay, somewhere in my head I can remember seeing an example of this, but I can't recall where it was. Sounds like the solution (if one exists) is non-trivial. Appreciate the ideas and if I do come across or develop some sort of solution I will post back to this thread. On 10/19/05, Frank W. Zammetti [EMAIL PROTECTED] wrote: I was thinking you could build an actual custom control to do this, and that's a good start... add a down arrow to the right of it to show the dropdown portion and lock the textbox from editing and you'd have a good start. Thanks Joe! -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 3:51 pm, Joe Germuska said: At 3:11 PM -0400 10/19/05, Frank W. Zammetti wrote: This isn's something that is possible in straight HTML. There could be a way to do it via CSS, but nothing obvious presents itself to me... I tried setting a background-image, but that didn't work. Can you find an example of it being done? Unless there's some non-obvious CSS trick, or perhaps some non-standard browser extension, I'd bet this isn't possible. Here's an example of something a user might not distinguish from what is described, although it wouldn't be using select http://script.aculo.us/demos/ajax/autocompleter_customized By using DHTML like this and having an event cause a hidden form field value to be set, you could achieve the goal. Note that Scriptaculous builds upon the Prototype library, which breaks commons-validator client side javascript validation. Joe -- Joe Germuska [EMAIL PROTECTED] http://blog.germuska.com Narrow minds are weapons made for mass destruction -The Ex - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- http://www.quidprocode.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Adding images to option items in a select drop down list
Actually, based on Joe's suggestion, I just threw it together just now. This is literally hacked together off the top of my head, and only tested in IE 6... I can see some things I'd want to fix already, but that's what you get from 5 minutes of hacking! Might make a good candidate for inclusion in the UIWidgets taglib of Java Web Parts, but feel free to roll a custom tag with it yourself (and contribute it back if you wish!), otherwise I'll add it to my own to-do list... html head titletest/title script function dropdown() { obj = document.getElementById(ddspan); if (obj.style.visibility == visible) { obj.style.visibility = hidden; } else { obj.style.visibility = visible; } } function setVal(inVal) { document.getElementById(tb).value = inVal; dropdown(); } function mOver(inObj) { inObj.style.backgroundColor = #ff; } function mOut(inObj) { inObj.style.backgroundColor = ; } /script /head body input name=tb type=text size=20 readonly style=border:1 solid #0;font-size:12pt;height:28px;span onClick=dropdown(); style=position:relative;top:-2;left:-1;font-size:12pt;height:28px;border:1 solid #00;nabla;/span br span id=ddSpan style=width:168px;padding:4;border:1 solid #00;visibility:hidden;position:relative;top:-3; table border=0 cellpadding=0 cellspacing=0 style=font-size:12pt; tr onClick=setVal('Lightning'); onMouseOver=mOver(this); onMouseOut=mOut(this); tdimg src=http://www.omnytex.com/images/si_resume_0.gif;/td td width=100%nbsp;Lightning/td /tr tr onClick=setVal('House'); onMouseOver=mOver(this); onMouseOut=mOut(this); tdimg src=http://www.omnytex.com/images/si_home_0.gif;/td tdnbsp;House/td /tr tr onClick=setVal('Envelope'); onMouseOver=mOver(this); onMouseOut=mOut(this); tdimg src=http://www.omnytex.com/images/si_contact_0.gif;/td tdnbsp;Envelope/td /tr /table /span /body /html -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 4:30 pm, Faisal Mahmoud said: Okay, somewhere in my head I can remember seeing an example of this, but I can't recall where it was. Sounds like the solution (if one exists) is non-trivial. Appreciate the ideas and if I do come across or develop some sort of solution I will post back to this thread. On 10/19/05, Frank W. Zammetti [EMAIL PROTECTED] wrote: I was thinking you could build an actual custom control to do this, and that's a good start... add a down arrow to the right of it to show the dropdown portion and lock the textbox from editing and you'd have a good start. Thanks Joe! -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM: fzammetti Yahoo: fzammetti MSN: [EMAIL PROTECTED] On Wed, October 19, 2005 3:51 pm, Joe Germuska said: At 3:11 PM -0400 10/19/05, Frank W. Zammetti wrote: This isn's something that is possible in straight HTML. There could be a way to do it via CSS, but nothing obvious presents itself to me... I tried setting a background-image, but that didn't work. Can you find an example of it being done? Unless there's some non-obvious CSS trick, or perhaps some non-standard browser extension, I'd bet this isn't possible. Here's an example of something a user might not distinguish from what is described, although it wouldn't be using select http://script.aculo.us/demos/ajax/autocompleter_customized By using DHTML like this and having an event cause a hidden form field value to be set, you could achieve the goal. Note that Scriptaculous builds upon the Prototype library, which breaks commons-validator client side javascript validation. Joe -- Joe Germuska [EMAIL PROTECTED] http://blog.germuska.com Narrow minds are weapons made for mass destruction -The Ex - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- http://www.quidprocode.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: issue with logic:present on JDK 1.4.2
I have issues with struts-logic tags...I'm not using JSTL. Shyam --- Dave Newton [EMAIL PROTECTED] wrote: Shyam Anand wrote: These don't seem to work with JDK 1.4.2 version. I'm running 1.4.2 w/o any JSTL issues. (Tomcat, WinXP, 1.4.2_08) Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Start your day with Yahoo! - Make it your home page! http://www.yahoo.com/r/hs - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: I am getting frustrated with LookupDispatchAction
Michael Jouravlev on 19/10/05 00:44, wrote: On 10/18/05, Adam Hardy [EMAIL PROTECTED] wrote: Secondly, getKeyMethodMap() looks really clunky - is there no way this can be pushed into the struts-config.xml? It can be done, but if this to be defined inside existing structures like action, then I would have to change Struts code. Another way is to define it somewhere else like component instead of action or just action-events, in this case you would need to include custom ruleset object into web.xml. The latter would be easier because Struts code would not be changed. I will think about moving map to config file, but frankly I do not consider it a priority. Why you don't like it in the class file? Because it's just a strings that go in a map. It's more easily readable in a config file and it keeps them all in one place instead of having to open each action. Obviously that only counts when you are looking at a big project, but it does make an impact. However I just thought of a better idea. Impose a rule that the name of the Action method should be prefixed by the prefix and that should be used as the name of each submit button. If the map is initialised at construction by reflection, it would make it all more intuitive and easier to code, with the added advantage that you would have one less place where the programmer would make a mistake. Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: issue with logic:present on JDK 1.4.2
Shyam Anand wrote: I have issues with struts-logic tags...I'm not using JSTL. Whoops. I'm running 1.4.2 w/o any struts tag issues (including 'logic'). (Tomcat, WinXP, 1.4.2_08) Why not switch to JSTL anyway, though? Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: form.submit() issue with html:button
Referencing http://struts.apache.org/api/org/apache/struts/taglib/html/BaseHandlerTag.html#triedJstlSuccess To quote the doc org.apache.struts.taglib.html.BaseHandlerTag Base class for tags that render form elements capable of including JavaScript event handlers and/or CSS Style attributes. This class does not implement the doStartTag() or doEndTag() methods. Subclasses should provide appropriate implementations of these. the underlying base class class of SubmitButton is in fact org.apache.struts.taglib.html.BaseHandlerTag which has an onClick event you can use then again why would your javascript function be calling JavaScriptFunction() { form.submit(); } when your submit logic is already processing the onClick event ? M- - Original Message - From: Carl Smith [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Cc: Struts Users Mailing List user@struts.apache.org Sent: Wednesday, October 19, 2005 3:45 PM Subject: Re: form.submit() issue with html:button What I really want to know is how to use html:button and still using onclick to call javascript to submit the form. Martin Gainty [EMAIL PROTECTED] wrote:Good Morning Carl excerpted from Craig: The challenge with doing this is that the JSP tags run on the server (as the page is being generated), while the JavaScript runs on the client side. To integrate the two, you need your tags (and other JSP code) to dynamically generate the JavaScript functions themselves -- sort of having a program write a program -- so that the JavaScript is customized to your particular need on this particular page. A very trivial example is the way that the tag deals with the focus attribute. If you specify it, a dynamically generated bit of JavaScript is created to set the input focus, which includes the name of the field you want initial focus assigned to. html:submit (submit button class) is derived from same parent as html:form (javax.servlet.jsp.tagext.TagSupport) so the characteristic of a server side Tag class(dynamically) generating JavaScript holds true Does this answer your question? Martin- - Original Message - From: Carl Smith To: Struts Users Mailing List Sent: Tuesday, October 18, 2005 10:13 PM Subject: form.submit() issue with I seem to have a issue using 's onclick. My value of onclick is a javascript performing form.submit(), but I found out this is not working. However if I chang my button to then the javascript is working. Why this is the case? Thanks. - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
struts bean utils-problems with properties
Hi all, i am new to this forum.this is my first post.i hope this mailing list helps me. in the first page in my struts web app, i need to enter the details of 5 persons. they have proprties name,sex,rollnumber and age for that i created a bean with these 4 properties which have getter and setter methods in it. then i instantiated the bean 5 times for the properties of 5 persons the bean name is person in my action form i instatiated like this: Person person1=new Person(); Person person2=new Person(); Person person3=new Person(); and so on in my jsp i used the property names as person1.name,person1.sex like that. so far its ok but i need to populate the model objects from this form. for that i used apache commons beanutils as below: PersonModel is exactly the same bean as my Person bean with exactly the same properties and same getter and setter methods. but the datatypes of properties in PersonModel are diffrent from Person bean(all the properties are Strings in Person but 2 are Strings,1Long,1int in PersonModel) PersonModel person1Model=new PersonModel (); BeanUtils.copyProperties(person1Model,personForm.getPerson1()); but this is failing to copy the properties and throwing illegalargumentexception. can anyone help how can i achieve this(copying properties) it seems to be nested property problem.i am new to struts. your suggestion are very much appreciated. regards and thanks in advance - Yahoo! Music Unlimited - Access over 1 million songs. Try it free.
Re: form.submit() issue with html:button
Thank you Martin on this information. This issue was resolved. Basically there was another error in my jsp that cause this issue. Now it is working fine. Simply put html:button does support form.submit() when correctly code in onclick. I will however have another issue with sturts validator when using form.submit(), which I will initiate another topic. Thanks. Martin Gainty [EMAIL PROTECTED] wrote: Referencing http://struts.apache.org/api/org/apache/struts/taglib/html/BaseHandlerTag.html#triedJstlSuccess To quote the doc org.apache.struts.taglib.html.BaseHandlerTag Base class for tags that render form elements capable of including JavaScript event handlers and/or CSS Style attributes. This class does not implement the doStartTag() or doEndTag() methods. Subclasses should provide appropriate implementations of these. the underlying base class class of SubmitButton is in fact org.apache.struts.taglib.html.BaseHandlerTag which has an onClick event you can use then again why would your javascript function be calling JavaScriptFunction() { form.submit(); } when your submit logic is already processing the onClick event ? M- - Original Message - From: Carl Smith To: Struts Users Mailing List Cc: Struts Users Mailing List Sent: Wednesday, October 19, 2005 3:45 PM Subject: Re: form.submit() issue with What I really want to know is how to use and still using onclick to call javascript to submit the form. Martin Gainty wrote:Good Morning Carl excerpted from Craig: The challenge with doing this is that the JSP tags run on the server (as the page is being generated), while the JavaScript runs on the client side. To integrate the two, you need your tags (and other JSP code) to dynamically generate the JavaScript functions themselves -- sort of having a program write a program -- so that the JavaScript is customized to your particular need on this particular page. A very trivial example is the way that the tag deals with the focus attribute. If you specify it, a dynamically generated bit of JavaScript is created to set the input focus, which includes the name of the field you want initial focus assigned to. html:submit (submit button class) is derived from same parent as html:form (javax.servlet.jsp.tagext.TagSupport) so the characteristic of a server side Tag class(dynamically) generating JavaScript holds true Does this answer your question? Martin- - Original Message - From: Carl Smith To: Struts Users Mailing List Sent: Tuesday, October 18, 2005 10:13 PM Subject: form.submit() issue with I seem to have a issue using 's onclick. My value of onclick is a javascript performing form.submit(), but I found out this is not working. However if I chang my button to then the javascript is working. Why this is the case? Thanks. - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Music Unlimited - Access over 1 million songs. Try it free.
RE: issue with logic:present on JDK 1.4.2
Use JSTL. __ Senior Programmer Analyst, Tax Distributed Systems Development Tax Compliance Development, ADP IT Phone: (909) 592-6411 Ext. 3863 e-mail: [EMAIL PROTECTED] -Original Message- From: Shyam Anand [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 19, 2005 12:59 PM To: Struts Users Mailing List Subject: Re: issue with logic:present on JDK 1.4.2 I have issues with struts-logic tags...I'm not using JSTL. Shyam --- Dave Newton [EMAIL PROTECTED] wrote: Shyam Anand wrote: These don't seem to work with JDK 1.4.2 version. I'm running 1.4.2 w/o any JSTL issues. (Tomcat, WinXP, 1.4.2_08) Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Start your day with Yahoo! - Make it your home page! http://www.yahoo.com/r/hs - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - This message and any attachments are intended only for the use of the addressee and may contain information that is privileged and confidential. If the reader of the message is not the intended recipient or an authorized representative of the intended recipient, you are hereby notified that any dissemination of this communication is strictly prohibited. If you have received this communication in error, notify the sender immediately by return email and delete the message and any attachments from your system. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Strange Struts tld problem
Hi, Assume I have 2 jsp(s), header.jsp and content.jsp In header.jsp, I have: %@ taglib uri=/WEB-INF/tld/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/tld/struts-html.tld prefix=html % %@ taglib uri=/WEB-INF/tld/struts-logic.tld prefix=logic % %@ taglib uri=/WEB-INF/tld/element.tld prefix=element % In content.jsp, I include header.jsp like the following: %@ include file=../common/Header.jsp % The problem is, when I surf to content.jsp, all HTML tags can't be rendered, they just don't show up. Every HTML tag which using Struts-HTML havn't show up but if I put those %@ taglib uri=XXX statement in content.jsp, everything work fine. In web.xml, I already declare all tag lib and the URI are all correct I also try using JSP include and toogle between absolute and relative path, no luck at all Any help would be appreciated thanks
Re: Strange Struts tld problem
From: Koon Yue Lam [EMAIL PROTECTED] Assume I have 2 jsp(s), header.jsp and content.jsp In content.jsp, I include header.jsp like the following: %@ include file=../common/Header.jsp % The include isn't working. Possibly because your file is named 'header.jsp' and you're including 'Header.jsp', (watch the case!) or possibly because it isn't where you think it is relative to content.jsp. In addition, unless you're on Servlet 2.2, you don't need to put the tlds under WEB-INF and map them in web.xml. Just use the URIs such as %@ taglib uri=http://struts.apache.org/tags-html; prefix=html % and the tld file that's in struts.jar will be used. -- Wendy Smoak - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: form.submit() issue with html:button
Hi Carl, Mind telling us the cause of your problem? On 10/20/05, Carl Smith [EMAIL PROTECTED] wrote: Thank you Martin on this information. This issue was resolved. Basically there was another error in my jsp that cause this issue. Now it is working fine. Simply put html:button does support form.submit() when correctly code in onclick. I will however have another issue with sturts validator when using form.submit(), which I will initiate another topic. Thanks. Martin Gainty [EMAIL PROTECTED] wrote: Referencing http://struts.apache.org/api/org/apache/struts/taglib/html/BaseHandlerTag.html#triedJstlSuccess To quote the doc org.apache.struts.taglib.html.BaseHandlerTag Base class for tags that render form elements capable of including JavaScript event handlers and/or CSS Style attributes. This class does not implement the doStartTag() or doEndTag() methods. Subclasses should provide appropriate implementations of these. the underlying base class class of SubmitButton is in fact org.apache.struts.taglib.html.BaseHandlerTag which has an onClick event you can use then again why would your javascript function be calling JavaScriptFunction() { form.submit(); } when your submit logic is already processing the onClick event ? M- - Original Message - From: Carl Smith To: Struts Users Mailing List Cc: Struts Users Mailing List Sent: Wednesday, October 19, 2005 3:45 PM Subject: Re: form.submit() issue with What I really want to know is how to use and still using onclick to call javascript to submit the form. Martin Gainty wrote:Good Morning Carl excerpted from Craig: The challenge with doing this is that the JSP tags run on the server (as the page is being generated), while the JavaScript runs on the client side. To integrate the two, you need your tags (and other JSP code) to dynamically generate the JavaScript functions themselves -- sort of having a program write a program -- so that the JavaScript is customized to your particular need on this particular page. A very trivial example is the way that the tag deals with the focus attribute. If you specify it, a dynamically generated bit of JavaScript is created to set the input focus, which includes the name of the field you want initial focus assigned to. html:submit (submit button class) is derived from same parent as html:form (javax.servlet.jsp.tagext.TagSupport) so the characteristic of a server side Tag class(dynamically) generating JavaScript holds true Does this answer your question? Martin- - Original Message - From: Carl Smith To: Struts Users Mailing List Sent: Tuesday, October 18, 2005 10:13 PM Subject: form.submit() issue with I seem to have a issue using 's onclick. My value of onclick is a javascript performing form.submit(), but I found out this is not working. However if I chang my button to then the javascript is working. Why this is the case? Thanks. - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Music Unlimited - Access over 1 million songs. Try it free. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Strange Struts tld problem
sorry, the include in my first mail was wrong, it should be: %@ include file=../common/header.jsp % and it still can't locate those tld On 10/20/05, Wendy Smoak [EMAIL PROTECTED] wrote: From: Koon Yue Lam [EMAIL PROTECTED] Assume I have 2 jsp(s), header.jsp and content.jsp In content.jsp, I include header.jsp like the following: %@ include file=../common/Header.jsp % The include isn't working. Possibly because your file is named 'header.jsp ' and you're including 'Header.jsp', (watch the case!) or possibly because it isn't where you think it is relative to content.jsp. In addition, unless you're on Servlet 2.2, you don't need to put the tlds under WEB-INF and map them in web.xml. Just use the URIs such as %@ taglib uri=http://struts.apache.org/tags-html; prefix=html % and the tld file that's in struts.jar will be used. -- Wendy Smoak - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
struts1.2.7 and tiles definitions
All, I have used tiles and struts1.2.7 without definitions. The test worked. Now I wanted to test struts and tiles with definitions. This is the tiles-defs.xml file (stored in my web-app web-inf folder) tiles-definitions definition name=tests.test path=/tests/x.jsp/ /tiles-definitions I also tried tiles-definitions definition name=tests.test path=/x.jsp/ /tiles-definitions this is my test jsp (index.jsp) %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % %@ taglib uri=/WEB-INF/struts-tiles.tld prefix=tiles % html head /head body html:form action=/index.do focus=name html:errors/ tiles:insert beanName=tests.test flush=true/ table tr td Name:/td tdhtml:text property=name//td /tr /table html:submitok/html:submit /html:form /body /html I have the following plug in inside struts-config.xml plug-in className=org.apache.struts.tiles.TilesPlugin set-property property=definitions-config value=/WEB-INF/tiles-defs.xml/ /plug-in And this is the test file for tiles (x.jsp) html head /head body hr /body /html When I start this I get the following error : javax.servlet.jsp.JspException: Error - Tag Insert : No value defined for bean 'tests.test' with property 'null' in scope 'null'. Can anyone help me out... -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.344 / Virus Database: 267.12.4/142 - Release Date: 18/10/2005 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Its Impossible to update ResourceBundle?
I have to update the resource bundle from an Action Class.I found it impossible as the handle of Resource Bundle is with ActionServlet when it is intialized.So, in order to update the resource Bundle values i have remove the handle first. My Question is it true?If Yes why if No how it can be done? Please guide.. SHailesh
Re: Adding images to option items in a select drop down list
Faisal, Why you want to use image, you can use stylesheet. You may refer following code: HTML HEAD TITLE New Document /TITLE STYLE type=text/css OPTION.mar{background-color:maroon; color:white} OPTION.red{background-color:red; color:maroon} OPTION.blue{background-color:blue; color:maroon} /STYLE /HEAD BODY select name=obj style=width:100 option value=Select/option option value=M class=marnbsp;/option option value=B class=rednbsp;/option option value=R class=bluenbsp;/option /select /BODY /HTML Sunil Faisal Mahmoud [EMAIL PROTECTED] 10/20/2005 12:31 AM Please respond to Struts Users Mailing List user@struts.apache.org To Struts Users Mailing List user@struts.apache.org cc Subject Adding images to option items in a select drop down list Hi, I am creating a drop down list using the HTML select and option tags. The items in the list will be color names (ex. red, green, blue, etc..). I would like a small square image to be next to each color name text in the list. How would I go about this in my jsp file with my struts tags? -Faisal -- http://www.quidprocode.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: struts1.2.7 and tiles definitions
tiles:insert beanName=tests.test flush=true/ Try definition instead of beanName as in tiles:insert definition=tests.test flush=true/
Re: struts1.2.7 and tiles definitions
From: Simons Kevin [EMAIL PROTECTED] I have used tiles and struts1.2.7 without definitions. The test worked. Now I wanted to test struts and tiles with definitions. This is the tiles-defs.xml file (stored in my web-app web-inf folder) tiles-definitions definition name=tests.test path=/tests/x.jsp/ /tiles-definitions tiles:insert beanName=tests.test flush=true/ I'm think you want 'name' not 'beanName'. Try this: tiles:insert name=tests.test ... / http://struts.apache.org/struts-tiles/tagreference-struts-tiles.html#insert -- Wendy Smoak - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Error while adding one field in thesample application
Hi, I am new to struts development. I have got a sample application from elsewhere. and if I deployed that one works good. I have changed the files. I have added one field in to jsp page. for that I have modified form and action classes also. even it gives the following error. kindly help in this regard. I have run the application in jrun4 server My Error: Translator.CompilationFailedExceptionCompiler errors: Found 58 semantic errors compiling C:/JRun4/servers/default/struts-submit/WEB-INF/jsp/jrun__submit2ejspb.java: 58. } while(_tag0.doAfterBody() == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN); - *** Error: No method named doAfterBody was found in type org/apache/struts/taglib/html/ErrorsTag. 58. } while(_tag0.doAfterBody() == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN); -- *** Error: No field named EVAL_BODY_AGAIN was found in type javax/servlet/jsp/tagext/BodyTag. 83. if(_tagStartVal2 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 88. } while(_tag2.doAfterBody() == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN); -- *** Error: No field named EVAL_BODY_AGAIN was found in type javax/servlet/jsp/tagext/BodyTag. 90. if(_tagStartVal2 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 94. } catch(Throwable __throwable) { if(_tagStartVal2 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 109. if(_tagStartVal3 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 114. } while(_tag3.doAfterBody() == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN); -- *** Error: No field named EVAL_BODY_AGAIN was found in type javax/servlet/jsp/tagext/BodyTag. 116. if(_tagStartVal3 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 120. } catch(Throwable __throwable) { if(_tagStartVal3 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 136. if(_tagStartVal4 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 141. } while(_tag4.doAfterBody() == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN); -- *** Error: No field named EVAL_BODY_AGAIN was found in type javax/servlet/jsp/tagext/BodyTag. 143. if(_tagStartVal4 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 147. } catch(Throwable __throwable) { if(_tagStartVal4 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 163. if(_tagStartVal5 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 168. } while(_tag5.doAfterBody() == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN); -- *** Error: No field named EVAL_BODY_AGAIN was found in type javax/servlet/jsp/tagext/BodyTag. 170. if(_tagStartVal5 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 174. } catch(Throwable __throwable) { if(_tagStartVal5 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type javax/servlet/jsp/tagext/BodyTag. 189. if(_tagStartVal6 == javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_BUFFERED) { - *** Error: No field named EVAL_BODY_BUFFERED was found in type
Re: struts1.2.7 and tiles definitions
+1 Try tiles:insert name=tests.test ... / OR tiles:insert attribute=tests.test / Cheers, Thomas Joseph [EMAIL PROTECTED] From: Wendy Smoak [EMAIL PROTECTED] From: Simons Kevin [EMAIL PROTECTED] I have used tiles and struts1.2.7 without definitions. The test worked. Now I wanted to test struts and tiles with definitions. This is the tiles-defs.xml file (stored in my web-app web-inf folder) tiles-definitions definition name=tests.test path=/tests/x.jsp/ /tiles-definitions tiles:insert beanName=tests.test flush=true/ I'm think you want 'name' not 'beanName'. Try this: tiles:insert name=tests.test ... / http://struts.apache.org/struts-tiles/tagreference-struts-tiles.html#insert -- Wendy Smoak - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]