what is the diffrence between struts1.1 and 1.2
hai, what is the diffrence between struts1.1 and 1.2
Custom Validation Doesnt Work
Hi All: I have the following Code in my Custom Validation class: if (propertyVO != null) { System.out.println(propertyVO != null.Hence Errors. Will return false); errors.add(field.getKey(), Resources.getActionMessage(request, action, field)); return false; } Where the method is as follows: public static boolean validateHolidexCode(Object bean, ValidatorAction action, Field field, ActionErrors errors, HttpServletRequest request) The System.out.println( (propertyVO != null... is getting printed but it is not stopping the Form from going to the Action , neither is the Error Message being shown. Other non-Custom Validation mesaages get printed properly. Thanks. Chetan
Re: rotating text
Hi, Thanks fr the reply ..but is it specific for IE only ..i tried it for firefox but it didnt work [EMAIL PROTECTED] wrote: Hello Kavitha, Use this sample HTML Code: HTML HEAD TITLETest Page/TITLE style type=text/css .vert{ left:1px; top:5px; width:1px; writing-mode: tb-rl; } /style /HEAD BODY BGCOLOR=#FF TEXT=#00 LINK=#FF VLINK=#80 ALINK=#FF00FF BACKGROUND=? span class=vertthis will be displayed vertically now/span /BODY /HTML Look at the style : .vert{ left:1px; top:5px; width:1px; writing-mode: tb-rl; } This is applied to the text in the Span tag. Hope this helps. Thanks and regards, Pazhanikanthan. P (Paz) Consultant for AXA, Senior Software Engineer, HCL Australia Services Pty. Ltd. Off : +61-3-9618-4085 Mob : +61-0411-354-838 Kavita Mehta [EMAIL PROTECTED] 21/08/2006 07:04 PM Please respond to Struts Users Mailing List To: Struts Users Mailing List user@struts.apache.org cc: Subject:rotating text Is it possible with HTML or CSS to rotate text as its displayed in the browser? Or is this something better done with a graphic? Id like to rotate a specifc line of text 90 degrees counter clockwise so that the first letter of the first word is at the 'bottom' of a table cell. Thanks Kavita - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ This e-mail has been scanned for viruses by MCI's Internet Managed Scanning Services - powered by MessageLabs. For further information visit http://www.mci.com * Important Note This email (including any attachments) contains information which is confidential and may be subject to legal privilege. If you are not the intended recipient you must not use, distribute or copy this email. If you have received this email in error please notify the sender immediately and delete this email. Any views expressed in this email are not necessarily the views of AXA. Thank you. ** No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.405 / Virus Database: 268.11.4/424 - Release Date: 8/21/2006 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Struts 1.3 and bean write
Hi, I am testing struts 1.3.5 and I have a difference with previous version. When I call bean:write to display an int property in my jsp page I have the following value org.apache.struts.taglib.bean.format.int19 instead of 19. Have you got an idea ? Regards, Jean-Marie. --- Email Disclaimer http://www.cofidis.be/emaildisclaimer.php - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Validator html args
Hi, I am using Validator 1.3, I would like to know if I can pass argument value issued from html element? I explain me: I have an html form : ... font id=labeluser class=testUser/font html:text property=userid/ ... My validation looks like this: form name=Identification field property=uti_userid depends=required arg key=user.label position=0/ /field Do you know if there a mean to display the labeluser (font id) instead of putting value in a resource bundle? Thanks, Regards, Jean-Marie. --- Email Disclaimer http://www.cofidis.be/emaildisclaimer.php - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Problem with web.xml and Struts 1.3
Hi, I have a big problem with an struts 1.3 application. My configuration: Weblogic 8.1 sp4 Struts 1.3 Fedora And when deploy a web application (WAR) I have this problem: [DEBUG 2006-08-22 10:51:44,291] org.apache.struts.action.ActionServlet:1720 Scanning web.xml for controller servlet mapping [DEBUG 2006-08-22 10:51:46,586] org.apache.struts.util.PropertyMessageResources :115 getMessage(en_US,configWebXml) [DEBUG 2006-08-22 10:51:46,591] org.apache.struts.util.PropertyMessageResources :212 loadLocale(en_US) [DEBUG 2006-08-22 10:51:46,592] org.apache.struts.util.PropertyMessageResources :236 Loading resource 'org/apache/struts/action/ActionResources_en_US.properties' [DEBUG 2006-08-22 10:51:46,592] org.apache.struts.util.PropertyMessageResources :263 Loading resource completed [DEBUG 2006-08-22 10:51:46,593] org.apache.struts.util.PropertyMessageResources :212 loadLocale(en) [DEBUG 2006-08-22 10:51:46,593] org.apache.struts.util.PropertyMessageResources :236 Loading resource 'org/apache/struts/action/ActionResources_en.properties' [DEBUG 2006-08-22 10:51:46,593] org.apache.struts.util.PropertyMessageResources :263 Loading resource completed [DEBUG 2006-08-22 10:51:46,594] org.apache.struts.util.PropertyMessageResources :212 loadLocale() [DEBUG 2006-08-22 10:51:46,594] org.apache.struts.util.PropertyMessageResources :236 Loading resource 'org/apache/struts/action/ActionResources.properties' [DEBUG 2006-08-22 10:51:46,595] org.apache.struts.util.PropertyMessageResources :263 Loading resource completed [DEBUG 2006-08-22 10:51:46,595] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.initProcessor [DEBUG 2006-08-22 10:51:46,595] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configWebXml [DEBUG 2006-08-22 10:51:46,596] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configMissing [DEBUG 2006-08-22 10:51:46,596] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyForwardConfig.invalid [DEBUG 2006-08-22 10:51:46,596] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.unhandledException [DEBUG 2006-08-22 10:51:46,597] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyPlugInConfigs.missing [DEBUG 2006-08-22 10:51:46,597] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.processInvalid [DEBUG 2006-08-22 10:51:46,597] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.notAuthorized [DEBUG 2006-08-22 10:51:46,597] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyMessageResourcesConfigs.missing [DEBUG 2006-08-22 10:51:46,598] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyMessageResourcesConfigs.key [DEBUG 2006-08-22 10:51:46,598] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.noInput [DEBUG 2006-08-22 10:51:46,598] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configIO [DEBUG 2006-08-22 10:51:46,599] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.reloading [DEBUG 2006-08-22 10:51:46,599] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.processPath [DEBUG 2006-08-22 10:51:46,599] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configInit [DEBUG 2006-08-22 10:51:46,599] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configVerifying [DEBUG 2006-08-22 10:51:46,600] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configExtends [DEBUG 2006-08-22 10:51:46,600] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configFieldRequired [DEBUG 2006-08-22 10:51:46,600] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.sessionCreate [DEBUG 2006-08-22 10:51:46,601] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyForwardConfig.missing [DEBUG 2006-08-22 10:51:46,601] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configExtends.creation [DEBUG 2006-08-22 10:51:46,601] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configCompleted [DEBUG 2006-08-22 10:51:46,601] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyActionMappingClass.invalid [DEBUG 2006-08-22 10:51:46,602] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configMapping [DEBUG 2006-08-22 10:51:46,602] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.requestDispatcher [DEBUG 2006-08-22 10:51:46,602] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configParse [DEBUG 2006-08-22 10:51:46,603] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.finalizing [DEBUG 2006-08-22 10:51:46,603]
RE: Struts Layouts
Display tag usually : http://displaytag.sourceforge.net/11/ Although I am currently writing an application using Rico and Prototype Ajax libraries and have implemented my own pagination of results :) -Original Message- From: Sherwood, Reg [mailto:[EMAIL PROTECTED] Sent: 21 August 2006 20:24 To: user@struts.apache.org Subject: Struts Layouts Hi Can anyone provide alternatives to the struts-layout tag lib package. I have been looking for additional struts extensions for table display/layout with little affect. From previous (limited) experience I have found the struts-layout package to be unstable. Basically, I am wondering what others are using for collection iteration in an html format. Thanks Reg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This email originated externally and has been scanned by MessageLabs __ This email has been scanned for all viruses by the MessageLabs SkyScan service. For more information on a proactive anti-virus service working around the clock, around the globe, visit http://www.messagelabs.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: what is the diffrence between struts1.1 and 1.2
0.1 No seriously there are articles all over the web on this matter. Heres a nice run down of 1.2 enhancements on top of 1.1 : http://www.oreillynet.com/onjava/blog/2004/12/struts_12_offers_cool_new_feat .html -Original Message- From: Gomathi [mailto:[EMAIL PROTECTED] Sent: 22 August 2006 08:36 To: Struts Users Mailing List Subject: what is the diffrence between struts1.1 and 1.2 hai, what is the diffrence between struts1.1 and 1.2 This email originated externally and has been scanned by MessageLabs __ This email has been scanned for all viruses by the MessageLabs SkyScan service. For more information on a proactive anti-virus service working around the clock, around the globe, visit http://www.messagelabs.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Struts Editing in IDE
Try myEclipse workbench Its realy nice - How low will we go? Check out Yahoo! Messengers low PC-to-Phone call rates.
Re: Struts Layouts
I'd give displaytag a +1, it's got some really nice features such as external paging and sorting. http://displaytag.sourceforge.net/11/tut_externalSortAndPage.html Chris McCormack wrote: Display tag usually : http://displaytag.sourceforge.net/11/ Although I am currently writing an application using Rico and Prototype Ajax libraries and have implemented my own pagination of results :) -Original Message- From: Sherwood, Reg [mailto:[EMAIL PROTECTED] Sent: 21 August 2006 20:24 To: user@struts.apache.org Subject: Struts Layouts Hi Can anyone provide alternatives to the struts-layout tag lib package. I have been looking for additional struts extensions for table display/layout with little affect. From previous (limited) experience I have found the struts-layout package to be unstable. Basically, I am wondering what others are using for collection iteration in an html format. Thanks Reg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This email originated externally and has been scanned by MessageLabs __ This email has been scanned for all viruses by the MessageLabs SkyScan service. For more information on a proactive anti-virus service working around the clock, around the globe, visit http://www.messagelabs.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Gareth Evans Senior Developer MSoft eSolutions Limited Technology Centre Inward Way Rossmore Business Park Ellesmere Port Cheshire CH65 3EN -- Tel:+44 (0)870 0100 704 Fax:+44 (0)870 9010 705 E-Mail: [EMAIL PROTECTED] Web:www.msoft.co.uk -- Terms: Please note that any prices quoted within this e-mail are subject to VAT. All program details and code described in this e-mail are subject to copyright © of MSoft eSolutions Limited and remain the intellectual property of MSoft eSolutions Limited. Any proposal or pricing information contained within this e-mail are subject to MSoft eSolutions' Terms and Conditions -- Disclaimer: This message is intended only for use of the addressee. If this message was sent to you in error, please notify the sender and delete this message. MSoft eSolutions Limited cannot accept responsibility for viruses, so please scan attachments. Views expressed in this message do not necessarily reflect those of MSoft eSolutions Limited who will not necessarily be bound by its contents. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: RePopulating EditScreen with ActionForm Data
Use the struts taglibs and put your form into session scope and you'll get the behaviour you want out of the box. Bart. Mississippi John Hurt wrote: Hi, What's the best way to do this? User finished an edit screen, formaction is populated, and info is displayed on a ReviewInfo page. User clicks go-back-edit goes back to the editscreen, but now data is gone. So how should I fix this? Is the best way to put hidden properties for the form on the review page, thus if user clicks boBackEdit, it will repopulate the edit screen? If I put the values in hidden fields, then what if they have special chars like (,,,etc)? How to escape them so they dont screw up html, and how to unescape them when read them back (is that necessary)? Or is it better to, at the edit screen, after user continues, copy formaction data to a modelbean, put modelbean in session? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AJAX + Struts
Dear All, How can i use Ajax with struts , Thanks and Regards Mohan - Do you Yahoo!? Everyone is raving about the all-new Yahoo! Mail.
Re: AJAX + Struts
Go to Google, type in Ajax struts and RTFM. Just looking at the first page of results I'd strongly suggest reading http://wiki.apache.org/struts/AjaxStruts. A.Mohan wrote: Dear All, How can i use Ajax with struts , Thanks and Regards Mohan - Do you Yahoo!? Everyone is raving about the all-new Yahoo! Mail. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Passing value from pop window to parent window
Hi I have a pop up window.And I need to pass the value from a text box to parent window. pop up window The text box in the child window is something like this html:text property=secondForm.attribute/ html:submit onclick=updatetext()/ function updatetext() { parent.document.getElementbyid(secondForm.attribute).value = document.getElementbyid(secondForm.attribute).value = } the attribute are same in both parent and pop up window. And I have anested form. I am not getting error after submitting and in the javascript i am getting the text field value correctly. but in parent window it is not setting the value. Any help will be highly appriciated -- Thanks and Regards Hanmayya Udgiri
RE: Passing value from pop window to parent window
Hi, You can try something like: function updatetext() { var val = document.getElementbyid(secondForm.attribute).value; window.opener.func(val); } Here, func is a JS function in the parent window. In func, write your code to set the value. With best regards, Anjishnu. -Original Message- From: Hanmay Udgiri [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 22, 2006 6:50 PM To: Struts Users Mailing List Subject: Passing value from pop window to parent window Hi I have a pop up window.And I need to pass the value from a text box to parent window. pop up window The text box in the child window is something like this html:text property=secondForm.attribute/ html:submit onclick=updatetext()/ function updatetext() { parent.document.getElementbyid(secondForm.attribute).value = document.getElementbyid(secondForm.attribute).value = } the attribute are same in both parent and pop up window. And I have anested form. I am not getting error after submitting and in the javascript i am getting the text field value correctly. but in parent window it is not setting the value. Any help will be highly appriciated -- Thanks and Regards Hanmayya Udgiri CAUTION - Disclaimer * This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of the addressee(s). If you are not the intended recipient, please notify the sender by e-mail and delete the original message. Further, you are not to copy, disclose, or distribute this e-mail or its contents to any other person and any such actions are unlawful. This e-mail may contain viruses. Infosys has taken every reasonable precaution to minimize this risk, but is not liable for any damage you may sustain as a result of any virus in this e-mail. You should carry out your own virus checks before opening the e-mail or attachment. Infosys reserves the right to monitor and review the content of all messages sent to or from this e-mail address. Messages sent to or from this e-mail address may be stored on the Infosys e-mail system. ***INFOSYS End of Disclaimer INFOSYS***
Re: Passing value from pop window to parent window
Hi It is working perfect!! thanks and regards hanmayya udgiri On 8/22/06, Anjishnu Bandyopadhyay [EMAIL PROTECTED] wrote: Hi, You can try something like: function updatetext() { var val = document.getElementbyid(secondForm.attribute).value; window.opener.func(val); } Here, func is a JS function in the parent window. In func, write your code to set the value. With best regards, Anjishnu. -Original Message- From: Hanmay Udgiri [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 22, 2006 6:50 PM To: Struts Users Mailing List Subject: Passing value from pop window to parent window Hi I have a pop up window.And I need to pass the value from a text box to parent window. pop up window The text box in the child window is something like this html:text property=secondForm.attribute/ html:submit onclick=updatetext()/ function updatetext() { parent.document.getElementbyid(secondForm.attribute).value = document.getElementbyid(secondForm.attribute).value = } the attribute are same in both parent and pop up window. And I have anested form. I am not getting error after submitting and in the javascript i am getting the text field value correctly. but in parent window it is not setting the value. Any help will be highly appriciated -- Thanks and Regards Hanmayya Udgiri CAUTION - Disclaimer * This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of the addressee(s). If you are not the intended recipient, please notify the sender by e-mail and delete the original message. Further, you are not to copy, disclose, or distribute this e-mail or its contents to any other person and any such actions are unlawful. This e-mail may contain viruses. Infosys has taken every reasonable precaution to minimize this risk, but is not liable for any damage you may sustain as a result of any virus in this e-mail. You should carry out your own virus checks before opening the e-mail or attachment. Infosys reserves the right to monitor and review the content of all messages sent to or from this e-mail address. Messages sent to or from this e-mail address may be stored on the Infosys e-mail system. ***INFOSYS End of Disclaimer INFOSYS*** -- Thanks and Regards Hanmayya Udgiri
Using websphere datasource in Struts
What is the best place to call Websphere DataSource in Struts application. Instantiate it when ActionServlet is loaded and then pass onto Model classes as reference OR create a static class that instantiates the DataSource and getConnections from this class which should be Singleton - Do you Yahoo!? Get on board. You're invited to try the new Yahoo! Mail.
Re: Extending MessageResource in struts 1.2.9.
From memory (its a long while since I used Struts 1.0) wasn't configuring message resources was in the web.xml? To configure custom message resources in Struts 1.2.x you need to use the message-resources element in your struts-config.xml http://struts.apache.org/1.2.x/userGuide/configuration.html#resources_config Maybe you could post how you're trying to configure your custom implementations Niall On 8/22/06, sudhir howale [EMAIL PROTECTED] wrote: We have a requirement of fetching the content from DB instead of storing the name value pair in application.properties. I already have a working version of this feature which works with struts 1.0 but when I tried the same version with strus 1.2.9, the latest version, application doesnt read the extended MessageResource and MessageResourceFactory classes. In short I am not able to trigger the exteded MessageResource and MessageResoruceFactory class with Struts 1.2.9. I am attaching a working version of this feature, which works with Struts 1.0 and doest work with Struts 1.2.9 Sudhir __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.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: Validator html args
Theres no way of picking up what was rendered in your view in the validation config. If you're hard coding your label values rather than putting them in the message resources though, you can do the same in your validation.xml - using the resource=false attribute. arg key=User position=0 resource=false/ ... or even the whole error message. Niall On 8/22/06, Jean-Marie Pitre [EMAIL PROTECTED] wrote: Hi, I am using Validator 1.3, I would like to know if I can pass argument value issued from html element? I explain me: I have an html form : ... font id=labeluser class=testUser/font html:text property=userid/ ... My validation looks like this: form name=Identification field property=uti_userid depends=required arg key=user.label position=0/ /field Do you know if there a mean to display the labeluser (font id) instead of putting value in a resource bundle? Thanks, Regards, Jean-Marie. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[OT] Re: Using websphere datasource in Struts
Shyamsunder Reddy ha scritto: What is the best place to call Websphere DataSource in Struts application. Eheh, it's not so simple :-) Instantiate it when ActionServlet is loaded and then pass onto Model classes as reference ABSOLUTELY NOT! OR create a static class that instantiates the DataSource and getConnections from this class which should be Singleton Do not use singleton in web application, because it raises several problem during reloading the webapp. Instead, you could use a container-managed datasource to call through JNDI: http://tomcat.apache.org/tomcat-5.5-doc/jndi-datasource-examples-howto.html Or use Spring or a similar IoC container to configure your Model (this is what I prefer to do): http://static.springframework.org/spring/docs/2.0.x/reference/beans.html#beans-value-element HTH Antonio - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: AJAX + Struts
http://wiki.apache.org/struts/AjaxStruts. There is a lot of fantastic info there.. thanks!!! -- Puneet
select tag and value issue
I'm fairly new to struts and am having a problem with the html:select tag. I can't get the value property to work correctly. I have a list of licenses that I want displayed in the drop down box. I want the license that is used by the current software to be selected. If I hard code the value property to be 22 for example, the license that has 22 for its key is selected. It seems like I should be able to use the license property in my SoftwareForm bean for the value but that does not work. When I do that, nothing ends up being selected. My JSP page looks like html:form action=/updateSoftware html:hidden property=id/ Name html:text property=name /br Location html:text property=location /br Approved html:checkbox property=approved value=true/br License html:select property=license value=22 html:option value=-1nbsp;/html:option html:options collection=allLicenses property=id labelProperty=name / /html:selectbr Notes html:text property=notes /br html:submit/ /html:form My action mapping looks like. action name=SoftwareForm path=/updateSoftware scope=request type=org.springframework.web.struts.DelegatingActionProxy input=/EditSoftware.jsp forward name=success path=/loadAllSoftware.do /forward forward name=Failure path=/EditSoftware.jsp /forward /action As you can see I am using spring. My SoftwareForm bean contains the String properties you would expect. In the action that forwards to the above form I have the following code Software s = softwareDAO.get(Long.decode(id)); Iterator i = licenseDAO.getAllLicenses(); SoftwareForm sForm = new SoftwareForm(); sForm.setApproved(Boolean.toString(s.isApproved())); sForm.setId(s.getId().toString()); sForm.setLicense(s.getLicense().getId().toString()); sForm.setLocation(s.getLocation()); sForm.setName(s.getName()); sForm.setNotes(s.getNotes()); request.setAttribute(SoftwareForm,sForm); request.setAttribute(allLicenses,i); This seems like it should be a fairly simple thing to do. What am I missing? Jon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: AJAX + Struts
Hello, I have some questions, what should be used on server side? we send XMLHttpRequest from client it should be received in action or we have to write servlet to process it? If we can use action, then what should be forward for that action. Thanks and Regards, Nikhil On 8/22/06, Puneet Lakhina [EMAIL PROTECTED] wrote: http://wiki.apache.org/struts/AjaxStruts. There is a lot of fantastic info there.. thanks!!! -- Puneet -- Nikhil
Re: AJAX + Struts
In short: it depends on what your passing in to the server. If you do regular POSTs and GETs, you can write Actions, just like always, there is zero difference. If you want to pass JSON or XML, then you'll have to add some code to handle that, either modifying the RP (or RP chain in 1.3), or else handle it in your Action. Or write a servlet. AJAX doesn't fundamentally change what you do on the server (in most cases... something like DWR is an exception, although under the covers, not really!). Take a peek at the AjaxChat example mentioned on that Wiki page... this is a Struts app using plain AJAX (i.e., no library). It's just plain old Struts, no modifications or anything to it. Frank -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM/Yahoo: fzammetti MSN: [EMAIL PROTECTED] Author of Practical Ajax Projects With Java Technology (2006, Apress, ISBN 1-59059-695-1) Java Web Parts - http://javawebparts.sourceforge.net Supplying the wheel, so you don't have to reinvent it! On Tue, August 22, 2006 1:06 pm, Nikhil Walvekar wrote: Hello, I have some questions, what should be used on server side? we send XMLHttpRequest from client it should be received in action or we have to write servlet to process it? If we can use action, then what should be forward for that action. Thanks and Regards, Nikhil On 8/22/06, Puneet Lakhina [EMAIL PROTECTED] wrote: http://wiki.apache.org/struts/AjaxStruts. There is a lot of fantastic info there.. thanks!!! -- Puneet -- Nikhil - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Centralized logging software
Hello, This my question off the topic, but was just wondering if you guys know of any open source software that lets me view all my application logs deployed on various servers to be viewable from one place and that should be online. Please share if you know of any such software? Thanks much Gnan This email message is for the sole use of the intended recipient (s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message. To reply to our email administrator directly, send an email to [EMAIL PROTECTED] Toys R Us, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Problem with web.xml and Struts 1.3
Would you like to include your struts-config.xml and web.xml so we can try to help? -Original Message- From: Angel Navarro [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 22, 2006 6:14 AM To: user@struts.apache.org Subject: Problem with web.xml and Struts 1.3 Hi, I have a big problem with an struts 1.3 application. My configuration: Weblogic 8.1 sp4 Struts 1.3 Fedora And when deploy a web application (WAR) I have this problem: [DEBUG 2006-08-22 10:51:44,291] org.apache.struts.action.ActionServlet:1720 Scanning web.xml for controller servlet mapping [DEBUG 2006-08-22 10:51:46,586] org.apache.struts.util.PropertyMessageResources :115 getMessage(en_US,configWebXml) [DEBUG 2006-08-22 10:51:46,591] org.apache.struts.util.PropertyMessageResources :212 loadLocale(en_US) [DEBUG 2006-08-22 10:51:46,592] org.apache.struts.util.PropertyMessageResources :236 Loading resource 'org/apache/struts/action/ActionResources_en_US.properties' [DEBUG 2006-08-22 10:51:46,592] org.apache.struts.util.PropertyMessageResources :263 Loading resource completed [DEBUG 2006-08-22 10:51:46,593] org.apache.struts.util.PropertyMessageResources :212 loadLocale(en) [DEBUG 2006-08-22 10:51:46,593] org.apache.struts.util.PropertyMessageResources :236 Loading resource 'org/apache/struts/action/ActionResources_en.properties' [DEBUG 2006-08-22 10:51:46,593] org.apache.struts.util.PropertyMessageResources :263 Loading resource completed [DEBUG 2006-08-22 10:51:46,594] org.apache.struts.util.PropertyMessageResources :212 loadLocale() [DEBUG 2006-08-22 10:51:46,594] org.apache.struts.util.PropertyMessageResources :236 Loading resource 'org/apache/struts/action/ActionResources.properties' [DEBUG 2006-08-22 10:51:46,595] org.apache.struts.util.PropertyMessageResources :263 Loading resource completed [DEBUG 2006-08-22 10:51:46,595] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.initProcessor [DEBUG 2006-08-22 10:51:46,595] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configWebXml [DEBUG 2006-08-22 10:51:46,596] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configMissing [DEBUG 2006-08-22 10:51:46,596] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyForwardConfig.invalid [DEBUG 2006-08-22 10:51:46,596] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.unhandledException [DEBUG 2006-08-22 10:51:46,597] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyPlugInConfigs.missing [DEBUG 2006-08-22 10:51:46,597] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.processInvalid [DEBUG 2006-08-22 10:51:46,597] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.notAuthorized [DEBUG 2006-08-22 10:51:46,597] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyMessageResourcesConfigs.missing [DEBUG 2006-08-22 10:51:46,598] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyMessageResourcesConfigs.key [DEBUG 2006-08-22 10:51:46,598] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.noInput [DEBUG 2006-08-22 10:51:46,598] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configIO [DEBUG 2006-08-22 10:51:46,599] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.reloading [DEBUG 2006-08-22 10:51:46,599] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.processPath [DEBUG 2006-08-22 10:51:46,599] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configInit [DEBUG 2006-08-22 10:51:46,599] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configVerifying [DEBUG 2006-08-22 10:51:46,600] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configExtends [DEBUG 2006-08-22 10:51:46,600] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configFieldRequired [DEBUG 2006-08-22 10:51:46,600] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.sessionCreate [DEBUG 2006-08-22 10:51:46,601] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyForwardConfig.missing [DEBUG 2006-08-22 10:51:46,601] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configExtends.creation [DEBUG 2006-08-22 10:51:46,601] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configCompleted [DEBUG 2006-08-22 10:51:46,601] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.verifyActionMappingClass.invalid [DEBUG 2006-08-22 10:51:46,602] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.configMapping [DEBUG 2006-08-22 10:51:46,602] org.apache.struts.util.PropertyMessageResources :278 Saving message key '.requestDispatcher [DEBUG 2006-08-22
Re: select tag and value issue
Your JSP code looks OK (except obviously you want to remove the value=22 from the html:select tag). Are you sure the value you're setting in form.license is correct? L. Jonathan Drnek wrote: I'm fairly new to struts and am having a problem with the html:select tag. I can't get the value property to work correctly. I have a list of licenses that I want displayed in the drop down box. I want the license that is used by the current software to be selected. If I hard code the value property to be 22 for example, the license that has 22 for its key is selected. It seems like I should be able to use the license property in my SoftwareForm bean for the value but that does not work. When I do that, nothing ends up being selected. My JSP page looks like html:form action=/updateSoftware html:hidden property=id/ Name html:text property=name /br Location html:text property=location /br Approved html:checkbox property=approved value=true/br License html:select property=license value=22 html:option value=-1nbsp;/html:option html:options collection=allLicenses property=id labelProperty=name / /html:selectbr Notes html:text property=notes /br html:submit/ /html:form My action mapping looks like. action name=SoftwareForm path=/updateSoftware scope=request type=org.springframework.web.struts.DelegatingActionProxy input=/EditSoftware.jsp forward name=success path=/loadAllSoftware.do /forward forward name=Failure path=/EditSoftware.jsp /forward /action As you can see I am using spring. My SoftwareForm bean contains the String properties you would expect. In the action that forwards to the above form I have the following code Software s = softwareDAO.get(Long.decode(id)); Iterator i = licenseDAO.getAllLicenses(); SoftwareForm sForm = new SoftwareForm(); sForm.setApproved(Boolean.toString(s.isApproved())); sForm.setId(s.getId().toString()); sForm.setLicense(s.getLicense().getId().toString()); sForm.setLocation(s.getLocation()); sForm.setName(s.getName()); sForm.setNotes(s.getNotes()); request.setAttribute(SoftwareForm,sForm); request.setAttribute(allLicenses,i); This seems like it should be a fairly simple thing to do. What am I missing? Jon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
re: Centralized logging software
Hello, This my question off the topic, but was just wondering if you guys know of any open source software that lets me view all my application logs deployed on various servers to be viewable from one place and that should be online. Please share if you know of any such software? Thanks much Gnan Here's one way... log4j has a number of appenders that would allow you to send logging into to a central logging server. Chainsaw (http://logging.apache.org/log4j/docs/chainsaw.html) is a GUI tool that allows you to read multiple log files: Rather than rely on a combination of tail/grep/vi or equivalent to view/query/trace-through a huge trail of logging events, you can use Chainsaw. Chainsaw can read log files formatted in Log4j's XMLLayout, receive events from remote locations, read events from a DB, it can even work with the JDK 1.4 logging events. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Question about Lookup dispatch action
Thanks for your help guyz. It doesn't seem to work. The value of submitText is not passed to the hidden.value The form gets submitted but gives an error Request[/planName] does not contain handler parameter named navigation I am pasting my code below. input type=hidden id=hiddenNavigation name=navigation value= disabled c:set var=submitText bean:message key=button.refresh / /c:set script type=text/javascript function onClickSubmit() { var hiddenField = document.getElementById( hiddenNavigation ); hiddenField.disabled = false; hiddenField.value = ${submitText}; alert(hiddenField.value); document.planNameForm.submit(); } /script !-- a onclick=onClickSubmit() -- Thanks again! Puneet Lakhina wrote: The return false; would have to go LAST, otherwise onClickSubmit() wouldn't get called. Yup..sorry.. my wrong.. -- Puneet -- View this message in context: http://www.nabble.com/Question-about-Lookup-dispatch-action-tf2124092.html#a5937309 Sent from the Struts - User forum at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Question about Lookup dispatch action
mosho wrote: Request[/planName] does not contain handler parameter named navigation In your struts-config.xml, are you including 'parameter=navigation' in your action mapping? A la: action path=/planName type=my.pkg.PlanNameAction name=planNameForm parameter=navigation ... /action The parameter gives you a place to pass additional data to your action. In the case of LookupDispatchAction, it uses it to find out which request parameter (in this case, navigation) it should look at to determine which method to call in your subclass. So your form will submit, and be stuff like: navigation=Next%20Record It looks messy, but that's OK. The framework takes it and translates it back into Next Record. Now in your subclass, you override getKeyMethodMap() right? And somewhere in there, you have something like, map.put( navigation.next.record, next ); Where next corresponds to the public ActionForward next( ActionMapping...) method you have defined in your subclass. And in your MessageResources.properties (or whatever the file's called in your web app), you have: navigation.next.record=Next Record See how everything links together? Now the button text you choose is likely different, but this flexibility is the reason you NEVER refer to the button by its text. Let Struts do that internally, only your users should see it. Just thought I'd give you a little background so you know what you're getting into; anyone correct me if I'm wrong :) Oh one last thing. Make sure you're NOT overriding execute() in your subclass. It's fine for regular Action-derived classes, but you're using LookupDispatchAction, which needs to run its own implementation of execute(). - Scott - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Form Validation
Hi All: I have one Dispatch Action class with two methods 'create' and 'edit'. Before Form is sent over it has to be validated. I have the following in struts-config.xml action path=/manageProperty type=com.BLUE.lms.actions.property.ManageProperty parameter=function name=propertyForm scope=session validate=true input=property.create.page forward name=message path=lms.message.display.page / /action But the thing is Line input=property.create.page makes validation possible for Creation. However I need to make Validation possible for input=property.edit.page also. Is their a way to specify multiple inputs. So that Validation will work for edit/create not just create. Thanks. Chetan
request processor
hai, what is the use of request processor?
Can we specify variables in html form tags action attribute
Dear All: I am trying to put a variable in action attribute but it doesnt work. %String propertyaction = /manageProperty?function=edit; pageContext.setAttribute(propertyaction,propertyaction);% html:form action=${propertyaction} Thanks. Chetan
Re: request processor
Is this a bad Karnak routine? Johnny: To parse requests Ed McMahon: To parse requests -tears envelope open- Johnny: What is the use of request processor? :grin: Sorry, couldn't resist :grin: The RP is essentially the series of steps that Struts goes though when a request is received and recognized as a request it should handle (i.e., mapped to ActionServlet). ActionServlet delegates to the RP (be it the monolithic RP of pre-1.3 Struts, or the chain-based RP of Struts 1.3.x). We're talking steps like populating the associated form bean, determining which Action to call, etc. Frank Gomathi wrote: hai, what is the use of request processor? -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM/Yahoo: fzammetti MSN: [EMAIL PROTECTED] Author of Practical Ajax Projects With Java Technology (2006, Apress, ISBN 1-59059-695-1) Java Web Parts - http://javawebparts.sourceforge.net Supplying the wheel, so you don't have to reinvent it! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]