RE: [OT] RE: Struts London Square Mile Java Developers
I see your point, but leaving in the same city would allow us to meet once a week, for instance. Certainly it's easier (and cheaper) than meeting someone in Manchester or South of England. Marco -Original Message- From: PILGRIM, Peter, FM [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 5:37 PM To: Struts-user-list Subject: [OT] RE: Struts London Square Mile Java Developers -Original Message- From: Marco Tedone [mailto:[EMAIL PROTECTED] I live in Leyton, when the central line will work again, is not that far from the SM. I live in the South london in the suburbs. I was hoping for response from other IT city workers, because it is easier to meet up after a hard working day in the centre of town ( or downtown for US readers). PS: This also applies to Expresso Frameworkers -- Peter Pilgrim, Struts/J2EE Consultant, RBoS FM, Risk IT Tel: +44 (0)207-375-4923 ** * Visit our Internet site at http://www.rbsmarkets.com This e-mail is intended only for the addressee named above. As this e-mail may contain confidential or privileged information, if you are not the named addressee, you are not authorised to retain, read, copy or disseminate this message or any part of it. The Royal Bank of Scotland plc is registered in Scotland No 90312 Registered Office: 36 St Andrew Square, Edinburgh EH2 2YB Regulated by the Financial Services Authority ** * - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Validating user inputs
Hi! Im using Struts 1.1 RC1 and I want to validate user input. I have a password field that should have at least 6 characters. Therefore, I use the following validator-rule in validator-rules.xml: form-validation global validator name=minlength classname=org.apache.struts.validator.FieldChecks method=validateMinLength methodParams=java.lang.Object, org.apache.commons.validator.ValidatorAction, org.apache.commons.validator.Field, org.apache.struts.action.ActionErrors, javax.servlet.http.HttpServletRequest depends=required msg=errors.minlength javascript![CDATA[ function validateMinLength(form) { var bValid = true; var focusField = null; var i = 0; var fields = new Array(); oMinLength = new minlength(); for (x in oMinLength) { if (form[oMinLength[x][0]].type == 'text' || form[oMinLength[x][0]].type == 'textarea') { var iMin = parseInt(oMinLength[x][2](minlength)); if (form[oMinLength[x][0]].value.length iMin) { if (i == 0) { focusField = form[oMinLength[x][0]]; } fields[i++] = oMinLength[x][1]; bValid = false; } } } if (fields.length 0) { focusField.focus(); alert(fields.join('\n')); } return bValid; }]] /javascript /validator !-- ... -- /global /form-validation The validator is used in validation.xml like this: form-validation formset form name=logonForm !-- ... -- field property=password depends=required,minlength arg0 key=prompt.password/ arg1 name=minlength key=${var:minlength} resource=false/ var var-nameminlength/var-name var-value6/var-value /var /field /form /formset /form-validation My logon.jsp: %@ page contentType=text/html;charset=UTF-8 language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % %@ taglib uri=/WEB-INF/struts-logic.tld prefix=logic % html:html locale=true body html:form action=/logon focus=username onsubmit=return validateLogonForm(this); table border=0 width=100% !-- ... -- tr th align=right width=50% bean:message key=prompt.password/: /th td align=left width=50% html:password property=password size=16 maxlength=18 redisplay=false/ /td /tr /table !-- Submit and cancel button -- /html:form html:javascript formName=logonForm dynamicJavascript=true staticJavascript=true / /body /html:html Last but not least, the entry in the struts-config.xml: plug-in className=org.apache.struts.validator.ValidatorPlugIn set-property property=pathnames value=/WEB-INF/validator-rules.xml,/WEB-INF/validation.xml/ /plug-in My problem is that there is only a server-side validation for the minlength-property. If nothing is entered in the password-field, Javascript-validation (required) works fine (i.e the validation is done on client-side). What am I doing wrong? Thanks for help! Stefan __ Mit der Auslands-SMS von WEB.DE FreeMail erreichen Sie Ihre Freunde auf der ganzen Welt - http://freemail.web.de/features/?mc=021171 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [OT] Help: JavaScript pop-up menu goes behind drop down list i n Internet Explorer
I know that CoolMenu 3 hasn't this problem. You can study the sources in struts-menu where there's an example. http://sourceforge.net/projects/struts-menu/ Arnaud -Message d'origine- De : Denis Wang [mailto:[EMAIL PROTECTED] Envoyé : mercredi 2 avril 2003 17:42 À : Struts Users Mailing List Objet : RE: [OT] Help: JavaScript pop-up menu goes behind drop down list i n Internet Explorer Thanks a lot. I will have a try. Denis -Original Message- From: McCarthy, Jeffrey - Contractor - IMSC [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 10:24 AM To: Struts Users Mailing List Subject: RE: [OT] Help: JavaScript pop-up menu goes behind drop down list i n Internet Explorer We had a similar problem. We solved this by putting each drop down list box into it's own div , assign it an id and write a JavaScript function that hides each drop-down div when the user mouse over the drop down. Hope that helps -Original Message- From: Eva Sager [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 9:57 AM To: 'Struts Users Mailing List' Subject: RE: [OT] Help: JavaScript pop-up menu goes behind drop down list i n Internet Explorer or moving the drop down or the menu... -Original Message- From: Jarnot Voytek Contr AU HQ/SC [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 9:52 AM To: 'Struts Users Mailing List' Subject: RE:[OT] Help: JavaScript pop-up menu goes behind drop down list i n Internet Explorer I'm assuming you mean in IE? No way to fix this, other than hiding the drop-down while the menu is displayed... -- Voytek Jarnot Quidquid latine dictum sit, altum viditur. -Original Message- From: Denis Wang [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 8:42 AM To: Struts Users Mailing List Subject: Help: JavaScript pop-up menu goes behind drop down list in Internet Explorer Hello, all, Sorry if it is off the subject of this mailing list. I use JavaScript to generate a pop-up menu. However, the menu is shadowed by my drop down list on the same page. Does anybody have any idea how to fix it. Thanks. Denis p.s. my JavaScript code to generate the menu function showMyMenu( myMenuName, myAnchorId ) { myAnchor = getAnchorPosition( myAnchorId ); window.showMenu( myMenuName, myAnchor.x, myAnchor.y+15 ); } - 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] - 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]
Resetting checkboxes in a multipage form
Hello everybody, I'm trying to implement a multipage form, with at least one checkbox. To solve the problem with unchecked boxes not being submitted to the server, I implemented the reset() method to set my checkboxValue to false. However this solution does not work in a multipage form, as the reset() method is called for every page of my form, even the pages where my checkbox is not on. For ex. a 3 page form I check the box on page1, submit and go to page 2 -- everything works fine fill in page 2, submit and got to page3 -- not ok reset is called -- checkboxvalue back to false, and my bean is not repopulated with the correct value because my checkbox was not on page2. Does anybody know an elegant solution to this problem? Or am I forced to put a hidden parameter with the same name/value pair as my checkbox on the pages where my checkbox is not on. thx for your time, Nicolas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Resetting checkboxes in a multipage form
Hi, Do you use HTML tags or STRUTS tags for your checkboxes -Message d'origine- De : Nicolas Pottrain [mailto:[EMAIL PROTECTED] Envoyé : jeudi 3 avril 2003 10:45 À : '[EMAIL PROTECTED]' Objet : Resetting checkboxes in a multipage form Hello everybody, I'm trying to implement a multipage form, with at least one checkbox. To solve the problem with unchecked boxes not being submitted to the server, I implemented the reset() method to set my checkboxValue to false. However this solution does not work in a multipage form, as the reset() method is called for every page of my form, even the pages where my checkbox is not on. For ex. a 3 page form I check the box on page1, submit and go to page 2 -- everything works fine fill in page 2, submit and got to page3 -- not ok reset is called -- checkboxvalue back to false, and my bean is not repopulated with the correct value because my checkbox was not on page2. Does anybody know an elegant solution to this problem? Or am I forced to put a hidden parameter with the same name/value pair as my checkbox on the pages where my checkbox is not on. thx for your time, Nicolas - 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: Resetting checkboxes in a multipage form
I use struts tags, does it matter? html:checkbox property=foobar/html:checkbox -Original Message- From: ROMERO NAVARRO Guillermo [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 10:55 AM To: Struts Users Mailing List Subject: RE: Resetting checkboxes in a multipage form Hi, Do you use HTML tags or STRUTS tags for your checkboxes -Message d'origine- De : Nicolas Pottrain [mailto:[EMAIL PROTECTED] Envoyé : jeudi 3 avril 2003 10:45 À : '[EMAIL PROTECTED]' Objet : Resetting checkboxes in a multipage form Hello everybody, I'm trying to implement a multipage form, with at least one checkbox. To solve the problem with unchecked boxes not being submitted to the server, I implemented the reset() method to set my checkboxValue to false. However this solution does not work in a multipage form, as the reset() method is called for every page of my form, even the pages where my checkbox is not on. For ex. a 3 page form I check the box on page1, submit and go to page 2 -- everything works fine fill in page 2, submit and got to page3 -- not ok reset is called -- checkboxvalue back to false, and my bean is not repopulated with the correct value because my checkbox was not on page2. Does anybody know an elegant solution to this problem? Or am I forced to put a hidden parameter with the same name/value pair as my checkbox on the pages where my checkbox is not on. thx for your time, Nicolas - 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]
[OT] Using struts menus in xslt.
Hi all, Would it be possible to use the struts menu system within an xslt file? I like the idea of the menu system, but can't, due to project restrictions use jsp pages. Cheers Simon Institut fuer Prozessdatenverarbeitung und Elektronik, Forschungszentrum Karlsruhe GmbH, Postfach 3640, D-76021 Karlsruhe, Germany. Tel: (+49)/7247 82-4042 E-mail : [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Resetting checkboxes in a multipage form
We'd the same problem but we used HTML tags, i only want to know if the same problem arrive with Struts tags... For the solution we made like you, one hidden parameter :( -Message d'origine- De : Nicolas Pottrain [mailto:[EMAIL PROTECTED] Envoyé : jeudi 3 avril 2003 10:52 À : 'Struts Users Mailing List' Objet : RE: Resetting checkboxes in a multipage form I use struts tags, does it matter? html:checkbox property=foobar/html:checkbox -Original Message- From: ROMERO NAVARRO Guillermo [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 10:55 AM To: Struts Users Mailing List Subject: RE: Resetting checkboxes in a multipage form Hi, Do you use HTML tags or STRUTS tags for your checkboxes -Message d'origine- De : Nicolas Pottrain [mailto:[EMAIL PROTECTED] Envoyé : jeudi 3 avril 2003 10:45 À : '[EMAIL PROTECTED]' Objet : Resetting checkboxes in a multipage form Hello everybody, I'm trying to implement a multipage form, with at least one checkbox. To solve the problem with unchecked boxes not being submitted to the server, I implemented the reset() method to set my checkboxValue to false. However this solution does not work in a multipage form, as the reset() method is called for every page of my form, even the pages where my checkbox is not on. For ex. a 3 page form I check the box on page1, submit and go to page 2 -- everything works fine fill in page 2, submit and got to page3 -- not ok reset is called -- checkboxvalue back to false, and my bean is not repopulated with the correct value because my checkbox was not on page2. Does anybody know an elegant solution to this problem? Or am I forced to put a hidden parameter with the same name/value pair as my checkbox on the pages where my checkbox is not on. thx for your time, Nicolas - 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: Resetting checkboxes in a multipage form
You will need to put conditional logic in your reset() method so that it only resets checkbox values on the page that is being submitted and leaves checkbox values for other pages well alone. -Original Message- From: Nicolas Pottrain [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 16:45 To: '[EMAIL PROTECTED]' Subject: Resetting checkboxes in a multipage form Hello everybody, I'm trying to implement a multipage form, with at least one checkbox. To solve the problem with unchecked boxes not being submitted to the server, I implemented the reset() method to set my checkboxValue to false. However this solution does not work in a multipage form, as the reset() method is called for every page of my form, even the pages where my checkbox is not on. For ex. a 3 page form I check the box on page1, submit and go to page 2 -- everything works fine fill in page 2, submit and got to page3 -- not ok reset is called -- checkboxvalue back to false, and my bean is not repopulated with the correct value because my checkbox was not on page2. Does anybody know an elegant solution to this problem? Or am I forced to put a hidden parameter with the same name/value pair as my checkbox on the pages where my checkbox is not on. thx for your time, Nicolas - 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: Resetting checkboxes in a multipage form
Nicolas Pottrain írta: Does anybody know an elegant solution to this problem? Carry your input with the help of a hidden field. Tib - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Resetting checkboxes in a multipage form
ok, I will do it like this, thx for the info people -Original Message- From: Andrew Hill [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 10:58 AM To: Struts Users Mailing List Subject: RE: Resetting checkboxes in a multipage form You will need to put conditional logic in your reset() method so that it only resets checkbox values on the page that is being submitted and leaves checkbox values for other pages well alone. -Original Message- From: Nicolas Pottrain [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 16:45 To: '[EMAIL PROTECTED]' Subject: Resetting checkboxes in a multipage form Hello everybody, I'm trying to implement a multipage form, with at least one checkbox. To solve the problem with unchecked boxes not being submitted to the server, I implemented the reset() method to set my checkboxValue to false. However this solution does not work in a multipage form, as the reset() method is called for every page of my form, even the pages where my checkbox is not on. For ex. a 3 page form I check the box on page1, submit and go to page 2 -- everything works fine fill in page 2, submit and got to page3 -- not ok reset is called -- checkboxvalue back to false, and my bean is not repopulated with the correct value because my checkbox was not on page2. Does anybody know an elegant solution to this problem? Or am I forced to put a hidden parameter with the same name/value pair as my checkbox on the pages where my checkbox is not on. thx for your time, Nicolas - 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]
How can one define a hypertext link on an image ?
How can I associate a link (call to an action) to an image with the Struts tags ? I tried td width=100% valign=top bgcolor=#CC div html:link href=login.do /html:link img src=%=request.getContextPath()%/images/Compagny.gif border=0 align=right/ /div /td but it dosen't work, the image is displayed but any link is available. Is it possible to access images that are not located within the application directory ? Thanks a lot in advance As of February 12th, 2003 Thomson unifies its email addresses on a worldwide basis. Please note my new email address: [EMAIL PROTECTED] http://www.thomson.net/
RE: How can one define a hypertext link on an image ?
try putting the image between the link tags, like this html:link href=login.do img src=%=request.getContextPath()%/images/Compagny.gif border=0 align=right/ /html:link -Original Message- From: Heligon Sandra [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 11:01 AM To: '[EMAIL PROTECTED]' Subject: How can one define a hypertext link on an image ? Importance: High How can I associate a link (call to an action) to an image with the Struts tags ? I tried td width=100% valign=top bgcolor=#CC div img src=%=request.getContextPath()%/images/Compagny.gif border=0 align=right/ /div /td but it dosen't work, the image is displayed but any link is available. Is it possible to access images that are not located within the application directory ? Thanks a lot in advance As of February 12th, 2003 Thomson unifies its email addresses on a worldwide basis. Please note my new email address: [EMAIL PROTECTED] http://www.thomson.net/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Resetting checkboxes in a multipage form
As you suggest, a solution is to use hidden fields on all pages for boolean (checkboxed) properties from other pages of the wizard-like form. As reset() gets the mapping I would suggest this : - extend ActionMapping to add a new property checkboxes - use this extended ActionMapping for your action, setting the new property with a comma separated list of boolean properties that this mapping should handle : action className=com.foo.WizardActionMapping name=wizardForm type=... set-property property=checkboxes value=checbox1, checkbox2 / forward .../ /action - in reset(), cast mapping to your extended mapping, and use it to get the list of boolean properties to reset. (this is example test, not tested and should not compile) resest(mapping, request) { if (mapping instanceOf WizardActionMapping) { WizardActionMapping wizardMapping = (WizardActionMapping) mapping; StringTokenizer tokenizer = new StringTokenizer(wizardMapping.getCheckBoxes(), ,); while (tokenizer.hasMoreToken()) { String checkbox = tokenizer.nextToken().trim(); // reset checkbox if (checbox1.equals(checkbox)) { checbox1 = false; } ... } } } If you find a good portable solution, you should redistribute it in Scaffold Struts tools (contribs), as I think it is a common problem. Hope it will help you. Nico. Hello everybody, I'm trying to implement a multipage form, with at least one checkbox. To solve the problem with unchecked boxes not being submitted to the server, I implemented the reset() method to set my checkboxValue to false. However this solution does not work in a multipage form, as the reset() method is called for every page of my form, even the pages where my checkbox is not on. For ex. a 3 page form I check the box on page1, submit and go to page 2 -- everything works fine fill in page 2, submit and got to page3 -- not ok reset is called -- checkboxvalue back to false, and my bean is not repopulated with the correct value because my checkbox was not on page2. Does anybody know an elegant solution to this problem? Or am I forced to put a hidden parameter with the same name/value pair as my checkbox on the pages where my checkbox is not on. thx for your time, Nicolas - 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: How can one define a hypertext link on an image ?
Thanks a lot it works. As of February 12th, 2003 Thomson unifies its email addresses on a worldwide basis. Please note my new email address: [EMAIL PROTECTED] http://www.thomson.net/ Original Message- From: Nicolas Pottrain [mailto:[EMAIL PROTECTED] Sent: 03 April 2003 11:03 To: 'Struts Users Mailing List' Subject: RE: How can one define a hypertext link on an image ? try putting the image between the link tags, like this html:link href=login.do img src=%=request.getContextPath()%/images/Compagny.gif border=0 align=right/ /html:link -Original Message- From: Heligon Sandra [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 11:01 AM To: '[EMAIL PROTECTED]' Subject: How can one define a hypertext link on an image ? Importance: High How can I associate a link (call to an action) to an image with the Struts tags ? I tried td width=100% valign=top bgcolor=#CC div img src=%=request.getContextPath()%/images/Compagny.gif border=0 align=right/ /div /td but it dosen't work, the image is displayed but any link is available. Is it possible to access images that are not located within the application directory ? Thanks a lot in advance As of February 12th, 2003 Thomson unifies its email addresses on a worldwide basis. Please note my new email address: [EMAIL PROTECTED] http://www.thomson.net/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT] EXTREMELY URGENT: JBoss JAAS/Container Security issue
Hello! Try changing this line in login-config.xml module-option name = rolesQuerySELECT user_roles, user_group FROM USER_ROLES WHERE USERNAME=?/module-option To module-option name = rolesQuerySELECT user_roles, 'Roles' FROM USER_ROLES WHERE USERNAME=?/module-option or change the value of user_group in all rows to Roles. My understanding of the second parameter that the rolesquery should return is that you can somhow categorize users in diffent ways, but that the default user/role handling should return Roles. It also sounds like you might have misunderstood how the run-as identity is used. That identity does not affect the callers of a bean or who can call it, it says that when the bean tries to access other beans it will do so with the run-as identity. This is so you can define beans that only can be called by internal identities so that noone can call them directly from the outside. Regards /Mikael At 09:51 2003-04-03 +0200, [EMAIL PROTECTED] wrote: I appologize for this Off-Topic message, but I desperatly need help! I have been fighting with the JBoss DatabaseServerLoginModule for almost 2 months now without success. I have tried an infinite number of combinations to try to get to a _SIMPLE_ solution as outlined by the JBoss manual, the JAAS article in JavaWorld, and hundreds of documents and examples from all over the internet. Well, I just don't have anymore time to waste as my deadline is now 48 hours away! I desperately need help: 1. Find someone to offer some help to resolve this by Friday. 2. Direct me somewhere to find the help I need 3. Tell who would be willing to have me hire them for the help I need. Here is my current situation: I am using JBoss 3.0.6 with Catalina on NT 4.0, MySql, XDoclet 1.2, Struts 1.1rc1, JDK 1.4. I create a beans.jar, common.jar, app.war and package everything into app.ear. The only things that are not in my EAR are the mysql-service.xml, auth.conf, login-config.xml, and server.policy which reside in the $JBOSS_HOME\server\default\conf and the $JBOSS_HOME\server\default\deploy directories. I also attached all the above file in a zip file here in this message. I have the DatabaseServerLoginModule configured and it seems to be operating, but not correctly. When I try to access a page under /private/* I get forwarded to /logon.jsp correctly. My MySql Database has 2 tables: TABLE_USER: columns: username, password TABLE_USER_ROLES: columns: username, user_roles, user_group TABLE_USER: data: mick, mickPassword TABLE_USER_ROLES: data1: mick, user, user TABLE_USER_ROLES: data2: mick, admin, admin I then type in j_username: mick, j_password: mickPassword and click ENTER. I seem to be logged in successfully as the console shows that I have 3 Principals: mick, user, admin and when I attempt to navigate to pages in the private area that do not require EJB access, I continue to see that my Principal is kept successfully through each page. So I do _not_ currently have the Principal=null issue. I do however have a UserPreferenceFilter that I check if the user is in role user, admin, or guest and all 3 come up as NO. Also, when I attempt to access a page that goes to my EJB layer, I get a Security violation error that states user must belong to [ANYONE] role. But I have added a run-as = InternalUser for all my EJB's so far. But that does not seem to work. When I remove the run-as=InternalUser, I get a Security Violation that states the user must belong to the role I specified. So it seems that my main 2 issues are getting the Roles to stick to the user when they login, and the EJB's to be able to use the user Roles, or the run-as=InternalUser - Thank You Mick Knutson Sr. Designer - Project Trust aUBS AG, Financial - Zürich Office: +41 (0)1/234.42.75 Internal: 48194 Mobile: 079.726.14.26 - Visit our website at http://www.ubswarburg.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL
How to do inherited validation using validation.xml
Hi, I am desigining an application, in which I have action forms that inherit from other created action forms. E.g public class BaseActionForm extends ValidatorAction { private String attributeOne; private String attributeTwo; } public class ExtendedActionForm extends BaseActionForm { private String attributeThree; private String attributeFour; } Now I have validations defined for BaseActionForm in the validationConfig, now I need to add validation for ExtendedActionForm, in which I want to mention to implicitly include all the validations mentioned in BaseActionForm. How can I achive this, can someone please help me. Regards Kartik Get Your Private, Free E-mail from Indiatimes at http://email.indiatimes.com Buy The Best In BOOKS at http://www.bestsellers.indiatimes.com Bid for for Air Tickets @ Re.1 on Air Sahara Flights. Just log on to http://airsahara.indiatimes.com and Bid Now ! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [OT] EXTREMELY URGENT: JBoss JAAS/Container Security issue
I will try the module-option ... in about 30 minutes. Thanks. On the run-as, I do understand that this bean will run other beans as this identity. My Session Facade actually have permission unchecked so anyone should be able to get to my session facade currently. It is not what I want, but it is a start at least. Then I can get the user Roles issue resolved. I am very grateful for your help! This JAAS has been so difficult! -Original Message- From: Mikael Eriksson [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 11:17 AM To: Struts Users Mailing List Cc: Knutson, Mick Subject: Re: [OT] EXTREMELY URGENT: JBoss JAAS/Container Security issue Hello! Try changing this line in login-config.xml module-option name = rolesQuerySELECT user_roles, user_group FROM USER_ROLES WHERE USERNAME=?/module-option To module-option name = rolesQuerySELECT user_roles, 'Roles' FROM USER_ROLES WHERE USERNAME=?/module-option or change the value of user_group in all rows to Roles. My understanding of the second parameter that the rolesquery should return is that you can somhow categorize users in diffent ways, but that the default user/role handling should return Roles. It also sounds like you might have misunderstood how the run-as identity is used. That identity does not affect the callers of a bean or who can call it, it says that when the bean tries to access other beans it will do so with the run-as identity. This is so you can define beans that only can be called by internal identities so that noone can call them directly from the outside. Regards /Mikael At 09:51 2003-04-03 +0200, [EMAIL PROTECTED] wrote: I appologize for this Off-Topic message, but I desperatly need help! I have been fighting with the JBoss DatabaseServerLoginModule for almost 2 months now without success. I have tried an infinite number of combinations to try to get to a _SIMPLE_ solution as outlined by the JBoss manual, the JAAS article in JavaWorld, and hundreds of documents and examples from all over the internet. Well, I just don't have anymore time to waste as my deadline is now 48 hours away! I desperately need help: 1. Find someone to offer some help to resolve this by Friday. 2. Direct me somewhere to find the help I need 3. Tell who would be willing to have me hire them for the help I need. Here is my current situation: I am using JBoss 3.0.6 with Catalina on NT 4.0, MySql, XDoclet 1.2, Struts 1.1rc1, JDK 1.4. I create a beans.jar, common.jar, app.war and package everything into app.ear. The only things that are not in my EAR are the mysql-service.xml, auth.conf, login-config.xml, and server.policy which reside in the $JBOSS_HOME\server\default\conf and the $JBOSS_HOME\server\default\deploy directories. I also attached all the above file in a zip file here in this message. I have the DatabaseServerLoginModule configured and it seems to be operating, but not correctly. When I try to access a page under /private/* I get forwarded to /logon.jsp correctly. My MySql Database has 2 tables: TABLE_USER: columns: username, password TABLE_USER_ROLES: columns: username, user_roles, user_group TABLE_USER: data: mick, mickPassword TABLE_USER_ROLES: data1: mick, user, user TABLE_USER_ROLES: data2: mick, admin, admin I then type in j_username: mick, j_password: mickPassword and click ENTER. I seem to be logged in successfully as the console shows that I have 3 Principals: mick, user, admin and when I attempt to navigate to pages in the private area that do not require EJB access, I continue to see that my Principal is kept successfully through each page. So I do _not_ currently have the Principal=null issue. I do however have a UserPreferenceFilter that I check if the user is in role user, admin, or guest and all 3 come up as NO. Also, when I attempt to access a page that goes to my EJB layer, I get a Security violation error that states user must belong to [ANYONE] role. But I have added a run-as = InternalUser for all my EJB's so far. But that does not seem to work. When I remove the run-as=InternalUser, I get a Security Violation that states the user must belong to the role I specified. So it seems that my main 2 issues are getting the Roles to stick to the user when they login, and the EJB's to be able to use the user Roles, or the run-as=InternalUser - Thank You Mick Knutson Sr. Designer - Project Trust aUBS AG, Financial - Zürich Office: +41 (0)1/234.42.75 Internal: 48194 Mobile: 079.726.14.26 - Visit our website at http://www.ubswarburg.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be
RE: Resetting checkboxes in a multipage form
I know that it is not the exact subject of the message but I will wish to know if somebody implemented buttons check all/uncheck all on a struts page. So yes how? I already posted several messages on this subject but nobody answered. if somebody has a few minutes. My JSP page: logic:iterate name=myForm id=employees property=employees type=comm.Employeeoffset=offset length=length tr td bgcolor=#EBEBEB width=10% html:checkbox name=myForm property=selected/ /td /tr /logic:iterate table width=100% border=0 cellpadding=0 cellspacing=0 bgcolor=#ff tr td align=right valign=top width=10% html:button property=callId onclick=checkAll(this.myForm.selected) Checkall /html:button html:button property=callId onclick=uncheckAl(this.myForm.selected) Uncheckall /html:button /td tr /table script language=JavaScript function checkAll(field) { for (i = 0; i field.length; i++) field[i] = true ; } function uncheckAll(field) { for (i = 0; i field.length; i++) field[i] = false ; } /script My struts-config.xml form-bean name=myForm dynamic=true type=org.apache.struts.validator.DynaValidatorForm form-property name=selected type=java.lang.Boolean[] / /form-bean Thanks a lot in advance. As of February 12th, 2003 Thomson unifies its email addresses on a worldwide basis. Please note my new email address: [EMAIL PROTECTED] http://www.thomson.net/ Original Message- From: Nicolas Pottrain [mailto:[EMAIL PROTECTED] Sent: 03 April 2003 11:00 To: 'Struts Users Mailing List' Subject: RE: Resetting checkboxes in a multipage form ok, I will do it like this, thx for the info people -Original Message- From: Andrew Hill [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 10:58 AM To: Struts Users Mailing List Subject: RE: Resetting checkboxes in a multipage form You will need to put conditional logic in your reset() method so that it only resets checkbox values on the page that is being submitted and leaves checkbox values for other pages well alone. -Original Message- From: Nicolas Pottrain [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 16:45 To: '[EMAIL PROTECTED]' Subject: Resetting checkboxes in a multipage form Hello everybody, I'm trying to implement a multipage form, with at least one checkbox. To solve the problem with unchecked boxes not being submitted to the server, I implemented the reset() method to set my checkboxValue to false. However this solution does not work in a multipage form, as the reset() method is called for every page of my form, even the pages where my checkbox is not on. For ex. a 3 page form I check the box on page1, submit and go to page 2 -- everything works fine fill in page 2, submit and got to page3 -- not ok reset is called -- checkboxvalue back to false, and my bean is not repopulated with the correct value because my checkbox was not on page2. Does anybody know an elegant solution to this problem? Or am I forced to put a hidden parameter with the same name/value pair as my checkbox on the pages where my checkbox is not on. thx for your time, Nicolas - 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: Resetting checkboxes in a multipage form
Heligon Sandra írta: I already posted several messages on this subject but nobody answered. Maybe your problem has nothing to do with struts. Try a javascript forum. Tib - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How can one define a hypertext link on an image ?
html:link href=login.do html:img page=/images/Compagny.gif border=0 align=right alt=company/ /html:link Nico try putting the image between the link tags, like this html:link href=login.do img src=%=request.getContextPath()%/images/Compagny.gif border=0 align=right/ /html:link -Original Message- From: Heligon Sandra [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 11:01 AM To: '[EMAIL PROTECTED]' Subject: How can one define a hypertext link on an image ? Importance: High How can I associate a link (call to an action) to an image with the Struts tags ? I tried td width=100% valign=top bgcolor=#CC div img src=%=request.getContextPath()%/images/Compagny.gif border=0 align=right/ /div /td but it dosen't work, the image is displayed but any link is available. Is it possible to access images that are not located within the application directory ? Thanks a lot in advance As of February 12th, 2003 Thomson unifies its email addresses on a worldwide basis. Please note my new email address: [EMAIL PROTECTED] http://www.thomson.net/ - 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]
Non default resource bundle in Validator cofiguration
Hi all, is there a way to specify the resourcebundle that must be used when retrieving the error message for a validation error. something like this: msg key=foo.bar name=required bundle=NonDefaultResourceBundle/ Nicolas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How to do inherited validation using validation.xml
Hi, I am desigining an application, in which I have action forms that inherit from other created action forms. E.g public class BaseActionForm extends ValidatorAction { private String attributeOne; private String attributeTwo; } public class ExtendedActionForm extends BaseActionForm { private String attributeThree; private String attributeFour; } Now I have validations defined for BaseActionForm in the validationConfig, now I need to add validation for ExtendedActionForm, in which I want to mention to implicitly include all the validations mentioned in BaseActionForm. How can I achive this, can someone please help me. Regards Kartik Missed your favourite TV serial last night? Try the new, Yahoo! TV. visit http://in.tv.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Struts newbie
Hi All ... I have certain questions regarding an application i have to build using struts. 1. First problem relates to packaging of web-app: Lets say i have only three features (search, My profile, Editor bulletin). The problem is supppose i want to deploy the solution in three packages. So for eg Standard deployment will have ONLY search. Premium would have search + My Profile and Enterprise would have all the three. Whats the best way to package a web-app in terms of features. Is there a standard way of packaging a web app so that its easily deployable in all three modes. So problem translates into: a.) When to show which button on UI screen and at a proper place on UI window based on the mode of deployment b.) When to enable/Disable an Action So is there a standard way of doing this or do i have to write huge if-then-elses at all places in the code. 2. Second question is regarding user and roles: Does struts provide some way of maintaining users, user-groups, and ROLES for them(The roles here are based on Features or Actions which different groups can access). So the complete problem is: I want to have three deployment modes, all of them would have different sets of users and features and different set of users will have access to different kind of features. Is there a standard way of doing this? Thanx in advance, Regards, Ubhay. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: how to switch of logging with log4j at initialization
Since you are still having problems, I would set up a simple test app with a class or two and a clean classpath. Edgar -Original Message- From: Martin Monsorno [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 2:37 AM To: 'Struts Users Mailing List' Cc: 'Niesen, Nathan'; Edgar Dollin Subject: Re: how to switch of logging with log4j at initialization Craig R. McClanahan [EMAIL PROTECTED] writes: [...] As I wrote as an answer to Edgar Dollin, my problem is not that log4j is used, but that my log4j configuration seems to be not the only one used, as I set the logging for com.apache to a file with ERROR level, but the output for (some of?) the commons-classes is logged anyway to stdout. Assuming that com.apache is not a typo, you might try org.apache instead. Yes, it's a typo. Unfortunately NOT in my log4j.configuration, only in my posting, so no luck with this, too :-( -- Martin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Page Iteration
Hi Jacob, thanks for the reply, in fact I'm using ejbs so I suppose I am pulling it from the database. Unfortunately though, in order to know how many pages to show I presumably must get the size of the collection I want to iterate, so I presume that means pulling all the items from the database in one go anyway? No? I've downloaded the suggested jar at any rate, and very much appreciate the advice. Brian - Original Message - From: Jacob Hookom [EMAIL PROTECTED] To: 'Struts Users Mailing List' [EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 5:25 PM Subject: RE: Page Iteration If the data is coming from the DB, you should NOT pull down all the data and slap it in their session for paging. It's a waste of resources, especially if they found what they wanted on the first page. A better solution would be to use DB -specific bounding of the results returned, like MySql's LIMIT on SELECT queries (btw, google uses MySql). By bounding the data returned from the DB in the first place, you just return all objects received in the scope of the SELECT statement to the page. If you aren't pulling from the DB, look at JSTL under Taglibs-Standard at Jakarta's web site. Their demo war for JSTL goes over scoped iteration. -Jacob | -Original Message- | From: Brian McSweeney [mailto:[EMAIL PROTECTED] | Sent: Wednesday, April 02, 2003 10:13 AM | To: Struts Users Mailing List | Subject: Page Iteration | | Hi all, | | I want to iterate over a collection and display a certain amount of items | per page and list all the | further pages available (just like on google). | | I presume this is a feature that has been added a million times. | | Did a quick search on the list and I see that use of the iterator with | parameter offset can be used. | Is this the general approach people would recommend? | | Any good resources on showing how to do it? | cheers, | Brian - 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: Page Iteration
Hi Michael, thanks for the reply, I'm using ejbs, so wouldn't you have to get a count of the whole collection size to know how many pages exist in the first place to iterate over? Doesn't this mean you are still going to have to get all the objects anyway? cheers, Brian - Original Message - From: Michael C. Lee Jr. [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 6:31 PM Subject: Re: Page Iteration These are database specific and probably won't work anyway for queries that require things such as order by, etc. In JDBC there is a call setMaxRows() that limits the total set of data returned from the database. Unfortuantely, the full query is performed but DB optimizations of that sort should be done by the DBA using a query analyzer type tool. Michael Lee - Original Message - From: Jacob Hookom [EMAIL PROTECTED] To: 'Struts Users Mailing List' [EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 11:25 AM Subject: RE: Page Iteration If the data is coming from the DB, you should NOT pull down all the data and slap it in their session for paging. It's a waste of resources, especially if they found what they wanted on the first page. A better solution would be to use DB -specific bounding of the results returned, like MySql's LIMIT on SELECT queries (btw, google uses MySql). By bounding the data returned from the DB in the first place, you just return all objects received in the scope of the SELECT statement to the page. If you aren't pulling from the DB, look at JSTL under Taglibs-Standard at Jakarta's web site. Their demo war for JSTL goes over scoped iteration. -Jacob | -Original Message- | From: Brian McSweeney [mailto:[EMAIL PROTECTED] | Sent: Wednesday, April 02, 2003 10:13 AM | To: Struts Users Mailing List | Subject: Page Iteration | | Hi all, | | I want to iterate over a collection and display a certain amount of items | per page and list all the | further pages available (just like on google). | | I presume this is a feature that has been added a million times. | | Did a quick search on the list and I see that use of the iterator with | parameter offset can be used. | Is this the general approach people would recommend? | | Any good resources on showing how to do it? | cheers, | Brian - 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: Resetting checkboxes in a multipage form
it is not that a simple problem of Javascript because the difficulty is to integrate the Javascript with the tags of struts html:button, html:checkbox. I cannot adapt the examples directly that I downloaded. this is why I address to the users of Struts As of February 12th, 2003 Thomson unifies its email addresses on a worldwide basis. Please note my new email address: [EMAIL PROTECTED] http://www.thomson.net/ Original Message- From: Gemes Tibor [mailto:[EMAIL PROTECTED] Sent: 03 April 2003 11:34 To: Struts Users Mailing List Subject: Re: Resetting checkboxes in a multipage form Heligon Sandra írta: I already posted several messages on this subject but nobody answered. Maybe your problem has nothing to do with struts. Try a javascript forum. Tib - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Where to catch/throw Exceptions in Struts Tiered Architecture
Hi, Take a simple case. Action Y UserAction - User - Database | V user.jsp Say, Database throws exception. What is best way to handle exception? 1. Catch in User class and return NULL / some ErrorObject to UserAction and let UserAction decide how to handle it? 2. Let User class __pass on__ the Exception from Database to UserAction. 2a. As execute() is already throwing Exception so it will handle ALL so Set global-exception handler that can send the user to some nice page? 2b. Catch Exception in UserAction and then do some thing ... Which one do you guys follow in not-so-large scale web applications? would appreciate any comments. -navjot singh - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Resetting checkboxes in a multipage form
If your limiting users to browsers that support DOM properly, perhaps you could just recurse through the DOM looking for checkbox objects and changing their values? -Original Message- From: Heligon Sandra [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 17:52 To: 'Struts Users Mailing List' Subject: RE: Resetting checkboxes in a multipage form it is not that a simple problem of Javascript because the difficulty is to integrate the Javascript with the tags of struts html:button, html:checkbox. I cannot adapt the examples directly that I downloaded. this is why I address to the users of Struts As of February 12th, 2003 Thomson unifies its email addresses on a worldwide basis. Please note my new email address: [EMAIL PROTECTED] http://www.thomson.net/ Original Message- From: Gemes Tibor [mailto:[EMAIL PROTECTED] Sent: 03 April 2003 11:34 To: Struts Users Mailing List Subject: Re: Resetting checkboxes in a multipage form Heligon Sandra írta: I already posted several messages on this subject but nobody answered. Maybe your problem has nothing to do with struts. Try a javascript forum. Tib - 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: Where to catch/throw Exceptions in Struts Tiered Architecture
I use nested exceptions, and virtually all my methods (and thus layers) catch and wrap and throw... Makes for some impressively long stacktraces - and is marvellous for debugging! :-) -Original Message- From: Navjot Singh [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 18:05 To: Struts Users List Subject: Where to catch/throw Exceptions in Struts Tiered Architecture Hi, Take a simple case. Action Y UserAction - User - Database | V user.jsp Say, Database throws exception. What is best way to handle exception? 1. Catch in User class and return NULL / some ErrorObject to UserAction and let UserAction decide how to handle it? 2. Let User class __pass on__ the Exception from Database to UserAction. 2a. As execute() is already throwing Exception so it will handle ALL so Set global-exception handler that can send the user to some nice page? 2b. Catch Exception in UserAction and then do some thing ... Which one do you guys follow in not-so-large scale web applications? would appreciate any comments. -navjot singh - 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]
Best way to migrate from Templates to Tiles(Struts 1.0)
Hi All, We are developing a fairly large web application using struts 1.0 and have almost finished it. We were using struts templates till now but are planning to switch to tiles library . So what is the best way to migrate a struts 1.0 application from Template to tiles? I couldnt find any definate resources about the same on the web.My problem is all i can see on the tiles web site seems to talk about struts 1.1. They have downloads of Tiles compactible with struts 1.0 but there is no documentation how to do this. More specifically ,What changes i have to do so that I can use tiles definations?DO i have to use ActionCOmponentServlet from Tiles instead of ActionServlet? Any help in this regard will be appreciated, Regards, Shirish - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Reload my application
Hi! Can I reload (How?) my properties and XML configuration files without restart the Application Server? Thx Mauro - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Reload my application
You can use the manager app included with tomcat. Binaghi Mauro wrote: Hi! Can I reload (How?) my properties and XML configuration files without restart the Application Server? Thx Mauro - 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: Reload my application
But I use JRun 3.0 (sigh) or Resin -Original Message- From: Kwok Peng Tuck [mailto:[EMAIL PROTECTED] Sent: giovedì 3 aprile 2003 12.42 To: Struts Users Mailing List Subject: Re: Reload my application You can use the manager app included with tomcat. Binaghi Mauro wrote: Hi! Can I reload (How?) my properties and XML configuration files without restart the Application Server? Thx Mauro - 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: Where to catch/throw Exceptions in Struts Tiered Architecture
IMO, catch the database exception in user, then throw a new (wrapped) exception, catch it in UserAction and throw a new exception, and use struts decalritive exception handling features to handle it. This avoids undue coupling between UserAction, User and Database. Gareth. Navjot Singh wrote: Hi, Take a simple case. Action Y UserAction - User - Database | V user.jsp Say, Database throws exception. What is best way to handle exception? 1. Catch in User class and return NULL / some ErrorObject to UserAction and let UserAction decide how to handle it? 2. Let User class __pass on__ the Exception from Database to UserAction. 2a. As execute() is already throwing Exception so it will handle ALL so Set global-exception handler that can send the user to some nice page? 2b. Catch Exception in UserAction and then do some thing ... Which one do you guys follow in not-so-large scale web applications? would appreciate any comments. -navjot singh - 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]
checkbox
is there a maximum # of checkbox that a user can only select... i have a least 500 checkboxes when i all of them is check submit won't work but checking say sumthing around 200 chekboxes , submit will work? is there a limitation of html checkox that i'm not aware of... thanks...
Probelm with Tiles download...
Hi All, I just downloaded Tiles.zip from the tiles home page(http://www.lifl.fr/%7Edumoulin/tiles/).I need to use it with struts 1.0. The readme.txt says that there is a tilies-tutorial.war which i cant find any where. Also there are 2 jar files(tiles.jar in /lib and tilesForStruts1-0.jar in /lib/struts1.0).SO which one i shoule be using? And when I deploy the tiles-documentation.war and access it,I get following exception org.apache.jasper.JasperException: Can't get definitions factory from context. at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:248) Where can I get a proper download of Tiles for struts 1.0. regards, Shirish - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Reload my application
The last time I used Jrun (it was the eval version, yes I know I'm a cheapskate) I did remember seeing options for that. You might try to poke around in the admin interface for Jrun. Good luck. Binaghi Mauro wrote: But I use JRun 3.0 (sigh) or Resin -Original Message- From: Kwok Peng Tuck [mailto:[EMAIL PROTECTED] Sent: giovedì 3 aprile 2003 12.42 To: Struts Users Mailing List Subject: Re: Reload my application You can use the manager app included with tomcat. Binaghi Mauro wrote: Hi! Can I reload (How?) my properties and XML configuration files without restart the Application Server? Thx Mauro - 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: Where to catch/throw Exceptions in Struts Tiered Architecture
hi andrew, but surely these long stacktraces are not meant for users ;-) what i have got from your statement is something like this SQLException |__DatabaseException |ApplicationException finally, this ApplicationException is what is being thrown into execute() call. May i am novice, but I still need to be convinced about throwing so many exceptions in chain Can't the stuff be handled in a simple way -- SAY a. when you get SQLException, catch and return NULL b. Calling Class __ifs__ for NULL instead of __catching__ and transfer the control accordingly. Is there something i am ignoring? regards Navjot Singh - Original Message - From: Andrew Hill [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 3:49 PM Subject: RE: Where to catch/throw Exceptions in Struts Tiered Architecture | I use nested exceptions, and virtually all my methods (and thus layers) | catch and wrap and throw... | Makes for some impressively long stacktraces - and is marvellous for | debugging! :-) | | | -Original Message- | From: Navjot Singh [mailto:[EMAIL PROTECTED] | Sent: Thursday, 3 April 2003 18:05 | To: Struts Users List | Subject: Where to catch/throw Exceptions in Struts Tiered Architecture | | | Hi, | | Take a simple case. | |Action | Y | UserAction - User - Database | | | V | user.jsp | | Say, Database throws exception. What is best way to handle exception? | | 1. Catch in User class and return NULL / some ErrorObject to UserAction and | let UserAction decide how to handle it? | | 2. Let User class __pass on__ the Exception from Database to UserAction. | | 2a. As execute() is already throwing Exception so it will handle ALL so Set | global-exception handler that can send the user to some nice page? | 2b. Catch Exception in UserAction and then do some thing ... | | Which one do you guys follow in not-so-large scale web applications? | | would appreciate any comments. | -navjot singh | | | | | - | 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: checkbox
Richard Raquepo írta: is there a maximum # of checkbox that a user can only select... i have a least 500 checkboxes when i all of them is check submit won't work but checking say sumthing around 200 chekboxes , submit will work? No, but there is a limitation of max length (around 2000, not sure) of the GET URL in IE. So if you have a plenty of input fields, you can easily reach this length. Try to use POST instead. Hth, Tib - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: checkbox
I was under the impression the max length of a get url was much lower (as far as the spec goes - although I believe IE and Mozilla both support longer ones than the minumum the spec mandates). Dont have the figures though :-( -Original Message- From: Gemes Tibor [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 18:57 To: Struts Users Mailing List Subject: Re: checkbox Richard Raquepo írta: is there a maximum # of checkbox that a user can only select... i have a least 500 checkboxes when i all of them is check submit won't work but checking say sumthing around 200 chekboxes , submit will work? No, but there is a limitation of max length (around 2000, not sure) of the GET URL in IE. So if you have a plenty of input fields, you can easily reach this length. Try to use POST instead. Hth, Tib - 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: checkbox
Andrew Hill írta: I was under the impression the max length of a get url was much lower (as far as the spec goes - although I believe IE and Mozilla both support longer ones than the minumum the spec mandates). Dont have the figures though :-( Ok I looked it up: The HTTP 1.1 (RFC2068) does not explicitly limit the length of the URL to anything. The length of a URL is unbounded. Most versions of Internet Explorer have a well defined hard limit of 2083 characters for the length of the URL. Tib - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Where to catch/throw Exceptions in Struts Tiered Architecture
thanks gareth, i got the point. thanks to Ted (Tip 15) and Andrew as well. -navjot - Original Message - From: Gareth Andrew [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 4:09 PM Subject: Re: Where to catch/throw Exceptions in Struts Tiered Architecture | IMO, catch the database exception in user, then throw a new (wrapped) | exception, catch it in UserAction and throw a new exception, and use | struts decalritive exception handling features to handle it. This | avoids undue coupling between UserAction, User and Database. | | Gareth. | | Navjot Singh wrote: | | Hi, | | Take a simple case. | |Action | Y | UserAction - User - Database | | | V | user.jsp | | Say, Database throws exception. What is best way to handle exception? | | 1. Catch in User class and return NULL / some ErrorObject to UserAction and | let UserAction decide how to handle it? | | 2. Let User class __pass on__ the Exception from Database to UserAction. | | 2a. As execute() is already throwing Exception so it will handle ALL so Set | global-exception handler that can send the user to some nice page? | 2b. Catch Exception in UserAction and then do some thing ... | | Which one do you guys follow in not-so-large scale web applications? | | would appreciate any comments. | -navjot singh | | | | | - | 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: [OT] EXTREMELY URGENT: JBoss JAAS/Container Security issue
I will try the module-option ... in about 30 minutes. Thanks. Ok, Hope that it will work as it should On the run-as, I do understand that this bean will run other beans as this identity. My Session Facade actually have permission unchecked so anyone should be able to get to my session facade currently. It is not what I want, but it is a start at least. Then I can get the user Roles issue resolved. I guess I misunderstood your first mail then. I am very grateful for your help! This JAAS has been so difficult! Yes, everything would be much easier without security :-) Regards /Mikael -Original Message- From: Mikael Eriksson [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 11:17 AM To: Struts Users Mailing List Cc: Knutson, Mick Subject: Re: [OT] EXTREMELY URGENT: JBoss JAAS/Container Security issue Hello! Try changing this line in login-config.xml module-option name = rolesQuerySELECT user_roles, user_group FROM USER_ROLES WHERE USERNAME=?/module-option To module-option name = rolesQuerySELECT user_roles, 'Roles' FROM USER_ROLES WHERE USERNAME=?/module-option or change the value of user_group in all rows to Roles. My understanding of the second parameter that the rolesquery should return is that you can somhow categorize users in diffent ways, but that the default user/role handling should return Roles. It also sounds like you might have misunderstood how the run-as identity is used. That identity does not affect the callers of a bean or who can call it, it says that when the bean tries to access other beans it will do so with the run-as identity. This is so you can define beans that only can be called by internal identities so that noone can call them directly from the outside. Regards /Mikael - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Where to catch/throw Exceptions in Struts Tiered Architecture
Generally, returning null when it should be an error is considered bad practice. (If null is a valid return value of course thats a different matter). In this case you should throw an exception and catch it in the calling class and branch or throw again appropriately. You dont want your calling class to have to know about low level details like specific sql exceptions though, so instead of just letting the sql exception propogate upwards, you would catch it and throw a different more abstract exception (probably one you create yourself) up to the caller - the caller shouldnt have to know the details about your persistence mechanism - it just needs to know it failed - and sometimes needs to know if the failure is fatal and any other pertinent info. The nested excpetion classes should also be able to keep a reference to the exception they wrap so the stacktrace show all the exceptions in the chain - useful when debugging. btw: If I recall rightly Ted Husted explains this 10 times better in one tenth the words in his book (struts in action) Have a look at these articles: http://developer.java.sun.com/developer/technicalArticles/Programming/except ions/ http://www-106.ibm.com/developerworks/java/library/j-ejb01283.html http://www.javaworld.com/javatips/jw-javatip91_p.html There was another very good one too - but it doesnt seem to be in my favourites list and I cant seem to find it now. -Original Message- From: Navjot Singh [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 18:53 To: Struts Users Mailing List; [EMAIL PROTECTED] Subject: Re: Where to catch/throw Exceptions in Struts Tiered Architecture hi andrew, but surely these long stacktraces are not meant for users ;-) what i have got from your statement is something like this SQLException |__DatabaseException |ApplicationException finally, this ApplicationException is what is being thrown into execute() call. May i am novice, but I still need to be convinced about throwing so many exceptions in chain Can't the stuff be handled in a simple way -- SAY a. when you get SQLException, catch and return NULL b. Calling Class __ifs__ for NULL instead of __catching__ and transfer the control accordingly. Is there something i am ignoring? regards Navjot Singh - Original Message - From: Andrew Hill [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 3:49 PM Subject: RE: Where to catch/throw Exceptions in Struts Tiered Architecture | I use nested exceptions, and virtually all my methods (and thus layers) | catch and wrap and throw... | Makes for some impressively long stacktraces - and is marvellous for | debugging! :-) | | | -Original Message- | From: Navjot Singh [mailto:[EMAIL PROTECTED] | Sent: Thursday, 3 April 2003 18:05 | To: Struts Users List | Subject: Where to catch/throw Exceptions in Struts Tiered Architecture | | | Hi, | | Take a simple case. | |Action | Y | UserAction - User - Database | | | V | user.jsp | | Say, Database throws exception. What is best way to handle exception? | | 1. Catch in User class and return NULL / some ErrorObject to UserAction and | let UserAction decide how to handle it? | | 2. Let User class __pass on__ the Exception from Database to UserAction. | | 2a. As execute() is already throwing Exception so it will handle ALL so Set | global-exception handler that can send the user to some nice page? | 2b. Catch Exception in UserAction and then do some thing ... | | Which one do you guys follow in not-so-large scale web applications? | | would appreciate any comments. | -navjot singh | | | | | - | 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: checkbox
Thanks for clarrifying that. URL limitations are a micro$oft 'feature' eh? Why am I not surprised? ;- -Original Message- From: Gemes Tibor [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 19:16 To: Struts Users Mailing List Subject: Re: checkbox Andrew Hill írta: I was under the impression the max length of a get url was much lower (as far as the spec goes - although I believe IE and Mozilla both support longer ones than the minumum the spec mandates). Dont have the figures though :-( Ok I looked it up: The HTTP 1.1 (RFC2068) does not explicitly limit the length of the URL to anything. The length of a URL is unbounded. Most versions of Internet Explorer have a well defined hard limit of 2083 characters for the length of the URL. Tib - 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: [OT] RE: Struts London Square Mile Java Developers
I live in south London as well! Unfortunately I don't work in the city! (well not yet anyway) Kola -Original Message- From: PILGRIM, Peter, FM [mailto:[EMAIL PROTECTED] Sent: 02 April 2003 17:37 To: Struts-user-list Subject: [OT] RE: Struts London Square Mile Java Developers -Original Message- From: Marco Tedone [mailto:[EMAIL PROTECTED] I live in Leyton, when the central line will work again, is not that far from the SM. I live in the South london in the suburbs. I was hoping for response from other IT city workers, because it is easier to meet up after a hard working day in the centre of town ( or downtown for US readers). PS: This also applies to Expresso Frameworkers -- Peter Pilgrim, Struts/J2EE Consultant, RBoS FM, Risk IT Tel: +44 (0)207-375-4923 *** Visit our Internet site at http://www.rbsmarkets.com This e-mail is intended only for the addressee named above. As this e-mail may contain confidential or privileged information, if you are not the named addressee, you are not authorised to retain, read, copy or disseminate this message or any part of it. The Royal Bank of Scotland plc is registered in Scotland No 90312 Registered Office: 36 St Andrew Square, Edinburgh EH2 2YB Regulated by the Financial Services Authority *** - 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: Probelm with Tiles download...
Hi, The download from the cited site should run. The tutorial is in tiles-doc.war. It should run immediately, unless you have a configuration problem (missing jars, bad parser version, ...). The tutorial in this dist is based on a now old struts 1.1 pre beta version. If you want to use tiles with struts1.0.x, I advice to do the following: * get the tiles-documentation.war from struts distribution. Learn, do the tutorial and experiment with this war file. The files from the tutorial are in this version. * After you are comfortable with Tiles, experiment on a struts1.0 platform: get the dist from my website, locate tilesForStruts1-0.jar and use it with struts1.0. * You can start from the tiles-blank-struts1-0.war file to have a good starting point with struts1.0. Hope this help, Cedric [EMAIL PROTECTED] wrote: Hi All, I just downloaded Tiles.zip from the tiles home page(http://www.lifl.fr/%7Edumoulin/tiles/).I need to use it with struts 1.0. The readme.txt says that there is a tilies-tutorial.war which i cant find any where. Also there are 2 jar files(tiles.jar in /lib and tilesForStruts1-0.jar in /lib/struts1.0).SO which one i shoule be using? And when I deploy the tiles-documentation.war and access it,I get following exception org.apache.jasper.JasperException: Can't get definitions factory from context. at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:248) Where can I get a proper download of Tiles for struts 1.0. regards, Shirish - 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: Where to catch/throw Exceptions in Struts Tiered Architecture
thanks a ton. now, i need to spend some hours doing some arrangements in my code but anyway that's for my good ;-) -navjot singh - Original Message - From: Andrew Hill [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 5:02 PM Subject: RE: Where to catch/throw Exceptions in Struts Tiered Architecture | Generally, returning null when it should be an error is considered bad | practice. (If null is a valid return value of course thats a different | matter). | In this case you should throw an exception and catch it in the calling class | and branch or throw again appropriately. | You dont want your calling class to have to know about low level details | like specific sql exceptions though, so instead of just letting the sql | exception propogate upwards, you would catch it and throw a different more | abstract exception (probably one you create yourself) up to the caller - the | caller shouldnt have to know the details about your persistence mechanism - | it just needs to know it failed - and sometimes needs to know if the failure | is fatal and any other pertinent info. | The nested excpetion classes should also be able to keep a reference to the | exception they wrap so the stacktrace show all the exceptions in the chain - | useful when debugging. | | btw: If I recall rightly Ted Husted explains this 10 times better in one | tenth the words in his book (struts in action) | | Have a look at these articles: | http://developer.java.sun.com/developer/technicalArticles/Programming/except | ions/ | http://www-106.ibm.com/developerworks/java/library/j-ejb01283.html | http://www.javaworld.com/javatips/jw-javatip91_p.html | | There was another very good one too - but it doesnt seem to be in my | favourites list and I cant seem to find it now. | | | -Original Message- | From: Navjot Singh [mailto:[EMAIL PROTECTED] | Sent: Thursday, 3 April 2003 18:53 | To: Struts Users Mailing List; [EMAIL PROTECTED] | Subject: Re: Where to catch/throw Exceptions in Struts Tiered | Architecture | | | hi andrew, | | but surely these long stacktraces are not meant for users ;-) | | what i have got from your statement is something like this | | SQLException | |__DatabaseException | |ApplicationException | | finally, this ApplicationException is what is being thrown into execute() | call. | | May i am novice, but I still need to be convinced about throwing so many | exceptions in chain | | Can't the stuff be handled in a simple way -- | SAY | a. when you get SQLException, catch and return NULL | b. Calling Class __ifs__ for NULL instead of __catching__ and transfer the | control accordingly. | | Is there something i am ignoring? | | regards | Navjot Singh | | - Original Message - | From: Andrew Hill [EMAIL PROTECTED] | To: Struts Users Mailing List [EMAIL PROTECTED] | Sent: Thursday, April 03, 2003 3:49 PM | Subject: RE: Where to catch/throw Exceptions in Struts Tiered Architecture | | | | I use nested exceptions, and virtually all my methods (and thus layers) | | catch and wrap and throw... | | Makes for some impressively long stacktraces - and is marvellous for | | debugging! :-) | | | | | | -Original Message- | | From: Navjot Singh [mailto:[EMAIL PROTECTED] | | Sent: Thursday, 3 April 2003 18:05 | | To: Struts Users List | | Subject: Where to catch/throw Exceptions in Struts Tiered Architecture | | | | | | Hi, | | | | Take a simple case. | | | |Action | | Y | | UserAction - User - Database | | | | | V | | user.jsp | | | | Say, Database throws exception. What is best way to handle exception? | | | | 1. Catch in User class and return NULL / some ErrorObject to UserAction | and | | let UserAction decide how to handle it? | | | | 2. Let User class __pass on__ the Exception from Database to UserAction. | | | | 2a. As execute() is already throwing Exception so it will handle ALL so | Set | | global-exception handler that can send the user to some nice page? | | 2b. Catch Exception in UserAction and then do some thing ... | | | | Which one do you guys follow in not-so-large scale web applications? | | | | would appreciate any comments. | | -navjot singh | | | | | | | | | | - | | 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] | |
Struts and Crimson
I only get the below stack trace when crimson is rolled into the JRE ext/lib -- the struts-config.xml file is well formed. Administrating the JRE is out of my hands. Is there a way to tell the container to use it's own XML parser? Any help is greatly appreciated. root 20030317 183520.344 ERROR Parse Error at line 13 column -1: Element struts-config does not allow form-beans here. org.xml.sax.SAXParseException: Element struts-config does not allow form-beans here. at org.apache.crimson.parser.Parser2.error(Parser2.java:3013) at org.apache.crimson.parser.ValidatingParser$ChildrenValidator.consume(Validat ingParser.java:349) at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1303) at org.apache.crimson.parser.Parser2.content(Parser2.java:1700) at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1468) at org.apache.crimson.parser.Parser2.parseInternal(Parser2.java:499) at org.apache.crimson.parser.Parser2.parse(Parser2.java:304) at org.apache.crimson.parser.XMLReaderImpl.parse(XMLReaderImpl.java:433) at org.apache.commons.digester.Digester.parse(Digester.java:1543) at org.apache.struts.action.ActionServlet.initModuleConfig(ActionServlet.java:9 44) at org.apache.struts.action.ActionServlet.init(ActionServlet.java:468) at app.ActionServletTtpayAdmin.init(ActionServletTtpayAdmin.java:15) at javax.servlet.GenericServlet.init(GenericServlet.java:82) at com.caucho.server.http.Application.createServlet(Application.java:3109) at com.caucho.server.http.Application.loadServlet(Application.java:3060) at com.caucho.server.http.Application.initServlets(Application.java:1921) at com.caucho.server.http.Application.init(Application.java:1847) at com.caucho.server.http.VirtualHost.initWars(VirtualHost.java:837) at com.caucho.server.http.VirtualHost.restartWarDir(VirtualHost.java:744) at com.caucho.server.http.ServletServer.getInvocation(ServletServer.java:1215) at com.caucho.server.http.RunnerRequest.handleRequest(RunnerRequest.java:341) at com.caucho.server.http.RunnerRequest.handleConnection(RunnerRequest.java:274 ) at com.caucho.server.TcpConnection.run(TcpConnection.java:139) at java.lang.Thread.run(Thread.java:479) - 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: [OT] EXTREMELY URGENT: JBoss JAAS/Container Security issue
At 14:08 2003-04-03 +0200, you wrote: OK, that worked. Also, that seemed to remove the errors I had with the EJB's as well. I really appreciate your help! Great! I am sorry if this seemed trivial to you and others, but the documentation did _not_ seem to be telling me what you mentioned about 'Roles'. I assumed 'Roles' ment I could call the 'Roles' what I understand as 'Roles'. Not the literal 'Roles'. Anyway, thanks very much. The trivial questions are best because I can answer them :-) Seriously I can see how the descriptoin can be misread, the jboss docs are a bit terse sometimes. Regards - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Probelm with Tiles download...
Hi Cedric, Thanks for the advice...I will try the same.. But what you mean by Struts distribution?Do you mean Struts 1.0.x distribution or struts 1.1 distribution? Because as far as I know, struts 1.0.x dist does not contain tiles.SO if i need to get struts 1.1,then I will have to run the tiles tutorial with struts 1.1. regards, Shirish -Original Message- From: Cedric Dumoulin [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 1:57 PM To: Struts Users Mailing List Subject: Re: Probelm with Tiles download... Hi, The download from the cited site should run. The tutorial is in tiles-doc.war. It should run immediately, unless you have a configuration problem (missing jars, bad parser version, ...). The tutorial in this dist is based on a now old struts 1.1 pre beta version. If you want to use tiles with struts1.0.x, I advice to do the following: * get the tiles-documentation.war from struts distribution. Learn, do the tutorial and experiment with this war file. The files from the tutorial are in this version. * After you are comfortable with Tiles, experiment on a struts1.0 platform: get the dist from my website, locate tilesForStruts1-0.jar and use it with struts1.0. * You can start from the tiles-blank-struts1-0.war file to have a good starting point with struts1.0. Hope this help, Cedric [EMAIL PROTECTED] wrote: Hi All, I just downloaded Tiles.zip from the tiles home page(http://www.lifl.fr/%7Edumoulin/tiles/).I need to use it with struts 1.0. The readme.txt says that there is a tilies-tutorial.war which i cant find any where. Also there are 2 jar files(tiles.jar in /lib and tilesForStruts1-0.jar in /lib/struts1.0).SO which one i shoule be using? And when I deploy the tiles-documentation.war and access it,I get following exception org.apache.jasper.JasperException: Can't get definitions factory from context. at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:248) Where can I get a proper download of Tiles for struts 1.0. regards, Shirish - 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: Re: Which is the best Struts or Expresso ?
Hi, Since, Craig Mc Clanahan is the lead for JSF spec., so it is expected and he may have Struts as a reference to make smooth sailing for huge Struts user base, if they choose JSF after it has been released. regds, Gurumurthy R. Struts Users Mailing List wrote: gt;It is also going to be considered for JSF specification. Is it? I've not heard anything like that. Where did you get that information on JSF? David _ Protect your PC - get McAfee.com VirusScan Online http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Get Your Private, Free E-mail from Indiatimes at http://email.indiatimes.com Buy The Best In BOOKS at http://www.bestsellers.indiatimes.com Bid for Air Tickets @ Re.1 on Air Sahara Flights. Just log on to http://airsahara.indiatimes.com and Bid Now !
Problems loading images - tomcat 4.1.18 / struts 1.1-rc1
Folks, I am loosing what little mind I had: I've got html:base/ It renders base href=http://localhost:8080/MyApp/WEB-INF/pages/as_home.jsp; and html:img page=/WEB-INF/images/header.jpg alt=Header/ It renders img src=/MyApp/WEB-INF/images/header.jpg alt=Header All of which looks like I'd expect. However, I get no images - just the alt string. I have tried hard-coding the path in an html img tag with the same result. I got one suggestion that permissions on the image dir could be a problem - I set them to 0777 with chown tomcat4:tomcat4. Does anyone have a clue? 'cause I SURE don't. Les - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problems loading images - tomcat 4.1.18 / struts 1.1-rc1
Les Dunaway rta: html:img page=/WEB-INF/images/header.jpg alt=Header/ It renders img src=/MyApp/WEB-INF/images/header.jpg alt=Header You cannot store your images in WEB-INF. there can be jsps to which you forward, but no resource directly referenced from browser. Hth, Tib - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problems loading images - tomcat 4.1.18 / struts 1.1-rc1
The servlet container cannot serve content from under /WEB-INF. Put your static content (images, css, js, etc) outside of the /WEB-INFlike /images and /css. On Thu, 2003-04-03 at 08:28, Les Dunaway wrote: Folks, I am loosing what little mind I had: I've got html:base/ It renders base href=http://localhost:8080/MyApp/WEB-INF/pages/as_home.jsp; and html:img page=/WEB-INF/images/header.jpg alt=Header/ It renders img src=/MyApp/WEB-INF/images/header.jpg alt=Header All of which looks like I'd expect. However, I get no images - just the alt string. I have tried hard-coding the path in an html img tag with the same result. I got one suggestion that permissions on the image dir could be a problem - I set them to 0777 with chown tomcat4:tomcat4. Does anyone have a clue? 'cause I SURE don't. Les - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- James Mitchell Software Developer/Struts Evangelist http://www.open-tools.org - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Struts training
Hi, I am thinking about trying to convince management in my company to pay and let me attend to some training on struts. Anybody has already experienced trainings on that topic ? I would be very interested into knowing where they did it and wether they consider it was worth doing. I would be more interested by sessions based in Europe, but If I am obliged to go to polynesia or hawai, well I will suffer it ;) Thanks, Thomas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: html:select
Use the value attribute on the html:select tag. -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 1:47 PM To: [EMAIL PROTECTED] Subject:html:select I'm pretty new to the jsp tag stuff, and I need to do something that I would think is pretty common, but I can't seem to do it without resorting to scriptlets. I have an Address, which has a String state on it. I have a Collection of States which have an int id, and String name on them. How can I generate a select list that defaults to the value that matches the state on my Address? Seems like this would be pretty common, but I can't find it anywhere :( Thanks in advance, Jesse - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
STRUTS JAXP Properties?
Is there a way to configure the action servlet to use specific JAXP properties to parse struts-config.xml? For example is there a way to set the following for struts-config parsing: javax.xml.parsers.DocumentBuilderFactory=com.caucho.xml.parsers.XmlDocument BuilderFactory javax.xml.parsers.SAXParserFactory=com.caucho.xml.parsers.XmlSAXParserFacto ry javax.xml.transform.TransformerFactory=com.caucho.xsl.Xsl Any help is greatly appreciated. Thanks, --Mike -Original Message- From: Michael Marrotte [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 7:37 AM To: Struts Users Mailing List Subject: Struts and Crimson I only get the below stack trace when crimson is rolled into the JRE ext/lib -- the struts-config.xml file is well formed. Administrating the JRE is out of my hands. Is there a way to tell the container to use it's own XML parser? Any help is greatly appreciated. root 20030317 183520.344 ERROR Parse Error at line 13 column -1: Element struts-config does not allow form-beans here. org.xml.sax.SAXParseException: Element struts-config does not allow form-beans here. at org.apache.crimson.parser.Parser2.error(Parser2.java:3013) at org.apache.crimson.parser.ValidatingParser$ChildrenValidator.consume(Validat ingParser.java:349) at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1303) at org.apache.crimson.parser.Parser2.content(Parser2.java:1700) at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1468) at org.apache.crimson.parser.Parser2.parseInternal(Parser2.java:499) at org.apache.crimson.parser.Parser2.parse(Parser2.java:304) at org.apache.crimson.parser.XMLReaderImpl.parse(XMLReaderImpl.java:433) at org.apache.commons.digester.Digester.parse(Digester.java:1543) at org.apache.struts.action.ActionServlet.initModuleConfig(ActionServlet.java:9 44) at org.apache.struts.action.ActionServlet.init(ActionServlet.java:468) at app.ActionServletTtpayAdmin.init(ActionServletTtpayAdmin.java:15) at javax.servlet.GenericServlet.init(GenericServlet.java:82) at com.caucho.server.http.Application.createServlet(Application.java:3109) at com.caucho.server.http.Application.loadServlet(Application.java:3060) at com.caucho.server.http.Application.initServlets(Application.java:1921) at com.caucho.server.http.Application.init(Application.java:1847) at com.caucho.server.http.VirtualHost.initWars(VirtualHost.java:837) at com.caucho.server.http.VirtualHost.restartWarDir(VirtualHost.java:744) at com.caucho.server.http.ServletServer.getInvocation(ServletServer.java:1215) at com.caucho.server.http.RunnerRequest.handleRequest(RunnerRequest.java:341) at com.caucho.server.http.RunnerRequest.handleConnection(RunnerRequest.java:274 ) at com.caucho.server.TcpConnection.run(TcpConnection.java:139) at java.lang.Thread.run(Thread.java:479) - 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: Struts training
We had a trainning course from the consultants of aragost.com. in Zurich,Switzerland They are quite good i must say..But also it depends on the level of Trainees.I mean if all the traines are experienced java developers,then the course can be quite productive and u get quite indepth trainning... Try thier website... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 3:36 PM To: Struts Users Mailing List Subject: Struts training Hi, I am thinking about trying to convince management in my company to pay and let me attend to some training on struts. Anybody has already experienced trainings on that topic ? I would be very interested into knowing where they did it and wether they consider it was worth doing. I would be more interested by sessions based in Europe, but If I am obliged to go to polynesia or hawai, well I will suffer it ;) Thanks, Thomas - 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: Probelm with Tiles download...
Args ... I mean struts 1.1. Tiles framework has been integrated in struts 1.1. It can work with struts1.0, but you need the TilesForStruts.jar. Check http://jakarta.apache.org/struts/api/org/apache/struts/tiles/package-summary.html#package_description for installation. Cedric [EMAIL PROTECTED] wrote: Hi Cedric, Thanks for the advice...I will try the same.. But what you mean by Struts distribution?Do you mean Struts 1.0.x distribution or struts 1.1 distribution? Because as far as I know, struts 1.0.x dist does not contain tiles.SO if i need to get struts 1.1,then I will have to run the tiles tutorial with struts 1.1. regards, Shirish -Original Message- From: Cedric Dumoulin [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 1:57 PM To: Struts Users Mailing List Subject: Re: Probelm with Tiles download... Hi, The download from the cited site should run. The tutorial is in tiles-doc.war. It should run immediately, unless you have a configuration problem (missing jars, bad parser version, ...). The tutorial in this dist is based on a now old struts 1.1 pre beta version. If you want to use tiles with struts1.0.x, I advice to do the following: * get the tiles-documentation.war from struts distribution. Learn, do the tutorial and experiment with this war file. The files from the tutorial are in this version. * After you are comfortable with Tiles, experiment on a struts1.0 platform: get the dist from my website, locate tilesForStruts1-0.jar and use it with struts1.0. * You can start from the tiles-blank-struts1-0.war file to have a good starting point with struts1.0. Hope this help, Cedric [EMAIL PROTECTED] wrote: Hi All, I just downloaded Tiles.zip from the tiles home page(http://www.lifl.fr/%7Edumoulin/tiles/).I need to use it with struts 1.0. The readme.txt says that there is a tilies-tutorial.war which i cant find any where. Also there are 2 jar files(tiles.jar in /lib and tilesForStruts1-0.jar in /lib/struts1.0).SO which one i shoule be using? And when I deploy the tiles-documentation.war and access it,I get following exception org.apache.jasper.JasperException: Can't get definitions factory from context. at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:248) Where can I get a proper download of Tiles for struts 1.0. regards, Shirish - 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]
updates and dispatcher
Hi! That is the problem. I've got a alta.jsp and edita.jsp, the only difference between alta.jsp and edita.jsp is the path of the Dispatcher action, because i want the same action to be sent the form. html:form action=/Proyectos?method=alta ../html:form and in edita.jsp html:form action=/Proyectos?method=edita .../html:form I would like to have only a form instead of two. Is there any way to do that? thanks - Yahoo! Messenger Nueva versioacute;n: Super Webcam, voz, caritas animadas, y maacute;s #161;Gratis!
Using Nested Extension
Title: Message Hi All, Has anybody used Sruts Nested Extension with Struts 1.0.2. If yes, please let me know what all I need to configure to start using this nested extension. Regards Ritesh - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
HTTP response as XML
Hello everyone, I have been using STruts for a while and it has solved a lot of my previous problems for example having long .jsps that included all the logic. Now I have been asked to use struts, which will receive the requst and will generate .xml instead of html as a response. This .xml will be parsed by another application. First of all is this possible? Make an http requset which will be handled by struts which will return xml code? If yes how is this possible? Do I have to implement my own custom tags? Has anyone implemented something similar? An xml file that I might generate will have the following form: ipg width=600 height=480 img=background.jpg navigation left=20 top=20 width=200 height=300 button top=0 width=200 height=50 img=background.jpg txt=Live TV action=TVCatalog target=displayarea/ button top=100 width=200 height=50 img=background.jpg txt=E-mail action=showEmail target=displayarea/ button top=200 width=200 height=50 img=background.jpg txt=Music action=musicCatalog target=displayarea/ /navigation img left=400 align=right img=background.jpg/ banner top=400 width=640 font=verdana size=40pt color=white bgcolor=transparent href=http://www.news.com; /banner block left=250 top=200 width=260 height=200 name=displayareaThis is a test. /block /ipg I could use any available help! Thank U in advance! Konstantina
RE: Struts training
Are you in Zurich? This is where I am currently working at UBS. -Original Message- From: Sakhare, Shirishchandra Sent: Thursday, April 03, 2003 3:45 PM To: [EMAIL PROTECTED] Subject: RE: Struts training We had a trainning course from the consultants of aragost.com. in Zurich,Switzerland They are quite good i must say..But also it depends on the level of Trainees.I mean if all the traines are experienced java developers,then the course can be quite productive and u get quite indepth trainning... Try thier website... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 3:36 PM To: Struts Users Mailing List Subject: Struts training Hi, I am thinking about trying to convince management in my company to pay and let me attend to some training on struts. Anybody has already experienced trainings on that topic ? I would be very interested into knowing where they did it and wether they consider it was worth doing. I would be more interested by sessions based in Europe, but If I am obliged to go to polynesia or hawai, well I will suffer it ;) Thanks, Thomas - 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] Visit our website at http://www.ubswarburg.com This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Using Nested Extension
We have not used it But I know that the nested tags were originally developed as enhancement to struts1.0 .So the homepage http://www.keyboardmonkey.com/index.jsp should have info baout how to install it.. regards, Shirish -Original Message- From: Ritesh Singhal [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 4:05 PM To: Struts Users Mailing List Subject: Using Nested Extension Hi All, Has anybody used Sruts Nested Extension with Struts 1.0.2. If yes, please let me know what all I need to configure to start using this nested extension. Regards Ritesh - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Using Nested Extension
I have used it extensively with no problems. Simply get the necessary nested_tags_10.jar from http://www.keyboardmonkey.com/next/index.jsp, add it to your application's classpath and you are good to go. Sri -Original Message- From: Ritesh Singhal [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 9:05 AM To: Struts Users Mailing List Subject: Using Nested Extension Hi All, Has anybody used Sruts Nested Extension with Struts 1.0.2. If yes, please let me know what all I need to configure to start using this nested extension. Regards Ritesh
MVC and security
Hi everybody, I have checked the archives and I could not find the answer to my question, so here it comes :-) I have programmed an extension to the Struts 1.0.2 taglibs, allowing to change the look of the JSP pages according to the profile of the users. As I didn't know of struts-layout, I did it by hand. I would like to know if my implementation is J2EE compliant ? (I really really need it, plase) - some tags (html:html, html:text...) have now an additional property, componentCode. html:html componentCode=anId - the users have all a profile, stored in a database. ie. in the database, you have the list of the users of the application, linked to their profile. A user can be, for example, an admin, a standard... - in the database, I store the list of the componentCodes of my application. I link these codes to the profiles, in order to give rights to the user. For example, an admin user can be allowed to write into the component theTextArea. If theTextArea is an html:text, you would have in the JSP html:text componentCode=theTextArea If the user is an admin, let's say he has the write right for theTextArea; the tag will display itself as an input type=text If the user is a standard, let's say he has the readonly right for theTextArea; the tag will display itself as a static table. NB: according to what I have read in the threads, there may have been better to do that, the only thing I want to know is if I am J2EE compliant, and if I respect the MVC pattern. Thanks in advance, Marc. ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: checkbox
All this is fine and dandy but isn't form-submission typically a POST operation? If you use html:form the default is POST. Sri -Original Message- From: Andrew Hill [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 6:34 AM To: Struts Users Mailing List Subject: RE: checkbox Thanks for clarrifying that. URL limitations are a micro$oft 'feature' eh? Why am I not surprised? ;- -Original Message- From: Gemes Tibor [mailto:[EMAIL PROTECTED] Sent: Thursday, 3 April 2003 19:16 To: Struts Users Mailing List Subject: Re: checkbox Andrew Hill írta: I was under the impression the max length of a get url was much lower (as far as the spec goes - although I believe IE and Mozilla both support longer ones than the minumum the spec mandates). Dont have the figures though :-( Ok I looked it up: The HTTP 1.1 (RFC2068) does not explicitly limit the length of the URL to anything. The length of a URL is unbounded. Most versions of Internet Explorer have a well defined hard limit of 2083 characters for the length of the URL. Tib - 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: HTTP response as XML
It is possible. It's commonly referred to as XML over HTTP. HTTP is the protocol or language that clients and servers speak and XML, HTML, GIFs, JPEGs, etc. can be delivered over that protocol. HTTP responses set a Content-Type header like Content-Type: text/html or Content-Type: text/xml in your case. There are JSTL tags that generate XML in JSPs or you can generate the XML in an Action and send it back. David From: Konstantina Stamopoulou [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: HTTP response as XML Date: Thu, 3 Apr 2003 17:25:09 +0300 Hello everyone, I have been using STruts for a while and it has solved a lot of my previous problems for example having long .jsps that included all the logic. Now I have been asked to use struts, which will receive the requst and will generate .xml instead of html as a response. This .xml will be parsed by another application. First of all is this possible? Make an http requset which will be handled by struts which will return xml code? If yes how is this possible? Do I have to implement my own custom tags? Has anyone implemented something similar? An xml file that I might generate will have the following form: ipg width=600 height=480 img=background.jpg navigation left=20 top=20 width=200 height=300 button top=0 width=200 height=50 img=background.jpg txt=Live TV action=TVCatalog target=displayarea/ button top=100 width=200 height=50 img=background.jpg txt=E-mail action=showEmail target=displayarea/ button top=200 width=200 height=50 img=background.jpg txt=Music action=musicCatalog target=displayarea/ /navigation img left=400 align=right img=background.jpg/ banner top=400 width=640 font=verdana size=40pt color=white bgcolor=transparent href=http://www.news.com; /banner block left=250 top=200 width=260 height=200 name=displayareaThis is a test. /block /ipg I could use any available help! Thank U in advance! Konstantina _ STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
About the checkLogonTag of the example application
Hi everybody, The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? Thanks in advance, Marc. ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: About the checkLogonTag of the example application
IMO, it is *not* a good practice. The view layer should not perform authentication logic. This should be placed in a Filter or a base Action method that secured actions call before executing. It's there as an example of using application specific custom tags with Struts tags. David From: Eyrignoux Marc [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: About the checkLogonTag of the example application Date: Thu, 3 Apr 2003 17:08:52 +0200 (CEST) Hi everybody, The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? Thanks in advance, Marc. ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Tired of spam? Get advanced junk mail protection with MSN 8. http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Page Iteration
Hi Brian I am using this taglib in my project and have no problem what so ever till todate... Ashish --- Brian McSweeney [EMAIL PROTECTED] wrote: Thanks Ashish, looks good and simple. Have you found the taglib reliable? cheers, Brian - Original Message - From: Ashish Kulkarni [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 6:38 PM Subject: Re: Page Iteration Hi , I am using a pager taglib which can be used on any scrollable object like collection etc I have also written a small HOWTO u can visit http://kulkarni_ash.tripod.com/howto/jsptaglib-howto.html and try to use it Anyone else using this taglib can u please verify and let me know if i am missing some thing Ashish --- Brian McSweeney [EMAIL PROTECTED] wrote: Hi all, I want to iterate over a collection and display a certain amount of items per page and list all the further pages available (just like on google). I presume this is a feature that has been added a million times. Did a quick search on the list and I see that use of the iterator with parameter offset can be used. Is this the general approach people would recommend? Any good resources on showing how to do it? cheers, Brian __ Do you Yahoo!? Yahoo! Tax Center - File online, calculators, forms, and more http://tax.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] __ Do you Yahoo!? Yahoo! Tax Center - File online, calculators, forms, and more http://tax.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: About the checkLogonTag of the example application
The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? I think that right before you display a JSP is *way* too late to be checking to see if someone is logged in or not. I do it in a Filter and they never even get to the .do Action if they haven't logged in. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management
Re: About the checkLogonTag of the example application
Struts Users Mailing List [EMAIL PROTECTED] schrieb am 03.04.03 17:27:26: The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? I think that right before you display a JSP is *way* too late to be checking to see if someone is logged in or not. I do it in a Filter and they never even get to the .do Action if they haven't logged in. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management Could you please give an example for that? Stefan __ Mit der Multi-SMS von WEB.DE FreeMail koennen Sie 760 Zeichen versenden. Informationen unter http://freemail.web.de/features/?mc=021184 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[OT] Do you know of a taglib that can...
Do you know of a taglib that can build xml compliant elements and attributes. For example: I have an image tag that I need to assign attributes to conditionally. img src=my.jpg width=12 height=24/ The src, width and height are provided by data entered into the database. If the width or height is empty I want to remove the width attribute or the height attribute. I can do this with jstl, now, as follows: c:set var=form scope=page value=requestScope.myStrutsForm/ c:set var=imgString img src=c:out value=${form.image.src} / c:if test=${!empty form.image.width} width=c:out value=${form.image.width} / /c:if c:if test=${!empty form.image.height} height=c:out value=${form.image.height} / /c:if / /c:set shww! messy! My head is spinning and I hope I got all my quotes right :-D Now it would be nice to do something like: c:set var=form scope=page value=requestScope.myStrutsForm/ c:set var=imgString tag:element name=a tag:attribute name=src value=${form.image.src}/ c:if test=${!empty form.image.width} tag:attribute name=width value=${form.image.width}/ /c:if c:if test=${!empty form.image.height} tag:attribute name=height value=${form.image.height}/ /c:if /tag:element /c:set aaah! manageable. So, do you know of any tags like these. Wouldn't this be nice for building conditional markup on your page? Brandon Goodin Phase Web and Multimedia PO Box 85 Whitefish MT 59937 P (406) 862-2245 F (406) 862-0354 [EMAIL PROTECTED] http://www.phase.ws - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: About the checkLogonTag of the example application
This should get you started: http://www.javaworld.com/javaworld/jw-06-2001/jw-0622-filters.html David From: Stefan Krompaß [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: About the checkLogonTag of the example application Date: Thu, 3 Apr 2003 17:35:10 +0200 Struts Users Mailing List [EMAIL PROTECTED] schrieb am 03.04.03 17:27:26: The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? I think that right before you display a JSP is *way* too late to be checking to see if someone is logged in or not. I do it in a Filter and they never even get to the .do Action if they haven't logged in. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management Could you please give an example for that? Stefan __ Mit der Multi-SMS von WEB.DE FreeMail koennen Sie 760 Zeichen versenden. Informationen unter http://freemail.web.de/features/?mc=021184 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Add photos to your messages with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: About the checkLogonTag of the example application
But if you do not have access to filters, this might be a good way to do it. - Original Message - From: Stefan Krompaß [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 10:35 AM Subject: Re: About the checkLogonTag of the example application Struts Users Mailing List [EMAIL PROTECTED] schrieb am 03.04.03 17:27:26: The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? I think that right before you display a JSP is *way* too late to be checking to see if someone is logged in or not. I do it in a Filter and they never even get to the .do Action if they haven't logged in. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management Could you please give an example for that? Stefan __ Mit der Multi-SMS von WEB.DE FreeMail koennen Sie 760 Zeichen versenden. Informationen unter http://freemail.web.de/features/?mc=021184 - 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: Page Iteration
cool, thanks Ashish, I'll give it a try so. One thing, on your explanation website where you iterate over the cached row set, is it possible to use the struts:iterate tag for this? cheers, Brian - Original Message - From: Ashish Kulkarni [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 4:23 PM Subject: Re: Page Iteration Hi Brian I am using this taglib in my project and have no problem what so ever till todate... Ashish --- Brian McSweeney [EMAIL PROTECTED] wrote: Thanks Ashish, looks good and simple. Have you found the taglib reliable? cheers, Brian - Original Message - From: Ashish Kulkarni [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, April 02, 2003 6:38 PM Subject: Re: Page Iteration Hi , I am using a pager taglib which can be used on any scrollable object like collection etc I have also written a small HOWTO u can visit http://kulkarni_ash.tripod.com/howto/jsptaglib-howto.html and try to use it Anyone else using this taglib can u please verify and let me know if i am missing some thing Ashish --- Brian McSweeney [EMAIL PROTECTED] wrote: Hi all, I want to iterate over a collection and display a certain amount of items per page and list all the further pages available (just like on google). I presume this is a feature that has been added a million times. Did a quick search on the list and I see that use of the iterator with parameter offset can be used. Is this the general approach people would recommend? Any good resources on showing how to do it? cheers, Brian __ Do you Yahoo!? Yahoo! Tax Center - File online, calculators, forms, and more http://tax.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] __ Do you Yahoo!? Yahoo! Tax Center - File online, calculators, forms, and more http://tax.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]
If I use session.invalidate() in the an action class ...
Hi: In my web application, my action class get output data from EIS, put them into OutputActionForm and return an ActionFoward. But if I add a session.invalidate () statement before return mapping.findForward(Output), My Output JSP page can not get any output data though I put output data into ActionForm in action class. I want to know how to show output data on Output JSP when I invalidate session before an actionFforward is returned. Adam Dong - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
help with html:select andhtml:optionsCollection
I am completely new to the stuts and i am trying to display values from the database using the html:select tag. I have a method called getItems in a Form bean blah.java that returns a list of the items from the database. Item is a database table that has different fields in it. I am using Torque that generates the om classes for the database tables. I am trying to put the values of a particular field from the database into the html:select. Please help with this... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[OT] Scaffold:StorageBeanBase Use Cases???
Hi all, The Access class in commons-scaffold (http://cvs.apache.org/viewcvs/jakarta-commons-sandbox/scaffold/) that is referred to in the book Struts in Action is deprecated. StorageBean interface is recommended in the javadoc instead. There is a StorageBeanBase class that implements StorageBean, but it seemed to me that it was designed for SQL data access. Would you recommend me to subclass the StorageBeanBase class for data access other than SQL data, or is it better to completely re-write our own StorageBeanBase class that implements the StorageBean interface? Are there any users of the Scaffold package out there? Thanks, Mete - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
mapping in request attributes
Hi, When forwarding a request from an action to a jsp does is the mapping automatically placed in the request or response? If so under what key will I find this? What I'm trying to do is get the form object out of the request so I was thinking I could do something like request.getAttribute(mapping.getAttribute()); I could use the form name as it is set in the struts-config.xml but I don't want to hard-code the name of the form in my jsp? What's the proper way to do this? Thanks, Matt
RE: About the checkLogonTag of the example application
Daniel wrote: But if you do not have access to filters, this might be a good way to do it. Not IMO. By the time you get to the JSP, you have already done things that an unauthorized user should not do... read from the database, etc. If nothing else, it's a waste of resources to *do* those things when you're not going to present the results to the user. If you can't use a Filter, then you should do something at the top of your Action (or as David said, in a Base Action class that all of your Actions inheirit from) to make sure that nothing happens if the user isn't logged in. For the person who wanted the example... we use a proprietary cookie-based authentication scheme with a Java API. The Filter looks something like this: package edu.asu.vpia.webapp; public class WebAuthFilter implements Filter { /** * Looks for either the 'authenticator' request parameter or else * the 'WEBAUTH' cookie, and checks with the WebAuth server to * determine if this is an authorized user. * If not, redirects to the login page * If so, places a WebUser object in request scope */ public void doFilter( ServletRequest req, ServletResponse resp, FilterChain chain ) throws IOException, ServletException { //determine whether we've got an authorized user, if not: String url = http://authserver.institution.edu; response.sendRedirect( url ); } } HTH... -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management
validation working for login page but not others
I've got validation working fine for the login page that users see when they first hit my webapp, but it doesn't work for a change password form later on in the webapp and I don't have a clue why. I'm using the latest nightly of struts on tomcat on solaris (not that that seems to matter much) Relevant info: struts-config bean declarations: form-bean name=logonForm type=org.apache.struts.validator.DynaValidatorForm form-property name=uname type=java.lang.String/ form-property name=pass type=java.lang.String/ /form-bean form-bean name=changePasswordForm type=org.apache.struts.validator.DynaValidatorForm form-property name=old type=java.lang.String/ form-property name=new1 type=java.lang.String/ form-property name=new2 type=java.lang.String/ /form-bean action maps: // the form that works actionpath=/logon type=actions.LogonAction name=logonForm scope=request validate=true input=/logonForward.do forward name=success redirect=true path=/secure/summaryPage.do/ /action // the form that doesn't actionpath=/secure/util/changePasswordSubmit type=org.apache.struts.scaffold.ProcessAction parameter=collab.beans.secure.util.ChangePassword input=/secure/util/changePassword.do name=changePasswordForm scope=request validate=true forward name=success path=/secure/summaryPage.do / forward name=failure path=/secure/util/changePassword.do / /action validation.xml (trimmed to only show one field per form): -- form name=logonForm field property=uname depends=minlength,maxlength arg0 key=loginpage.usernameprompt/ arg1 key=${var:minlength} name=minlength resource=false/ arg2 key=${var:maxlength} name=maxlength resource=false/ var var-namemaxlength/var-name var-value16/var-value /var var var-nameminlength/var-name var-value1/var-value /var /field /form !-- add more forms here -- form name=changePasswordForm field property=old depends=minlength,maxlength arg0 key=changePassword.oldText/ arg1 key=${var:minlength} name=minlength resource=false/ arg2 key=${var:maxlength} name=maxlength resource=false/ var var-namemaxlength/var-name var-value16/var-value /var var var-nameminlength/var-name var-value1/var-value /var /field -- Since validation occurs before the Action bean is called, scaffolding shouldn't be getting in the way. Other than that, I'm just not seeing what the problem could be. It works for logon, but not for changePassword. Any help would be appreciated. Thanks, Kirby -- Kirby Vandivort Theoretical and Computational Biophysics Email: [EMAIL PROTECTED] 3051 Beckman Institute http://www.ks.uiuc.edu/~kvandivo/University of Illinois Phone: (217) 244-5711405 N. Mathews Ave Fax : (217) 244-6078Urbana, IL 61801, USA - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: About the checkLogonTag of the example application
I agree with David. The view layer should not perform authentication logic, IMO the view layer should not contain *any* logic [maybe I live in a fantasy world :-)]. -S - Original Message - From: David Graham [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 7:11 AM Subject: Re: About the checkLogonTag of the example application IMO, it is *not* a good practice. The view layer should not perform authentication logic. This should be placed in a Filter or a base Action method that secured actions call before executing. It's there as an example of using application specific custom tags with Struts tags. David From: Eyrignoux Marc [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: About the checkLogonTag of the example application Date: Thu, 3 Apr 2003 17:08:52 +0200 (CEST) Hi everybody, The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? Thanks in advance, Marc. ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Tired of spam? Get advanced junk mail protection with MSN 8. http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.463 / Virus Database: 262 - Release Date: 3/17/2003 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Validating user inputs
A couple minor points 1) If your validator-rules.xml validation definition has depends=required, then you don't need to have it in the validation.xml as well. 2) Where is the form definition from your struts-config.xml? -- Steve Stair - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: About the checkLogonTag of the example application
The view should not contain *business* logic but it's perfectly reasonable to contain view logic. Something like: if accounts 10 display them in green else display in red. David From: A Stephen [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: About the checkLogonTag of the example application Date: Thu, 3 Apr 2003 08:47:17 -0800 I agree with David. The view layer should not perform authentication logic, IMO the view layer should not contain *any* logic [maybe I live in a fantasy world :-)]. -S - Original Message - From: David Graham [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 7:11 AM Subject: Re: About the checkLogonTag of the example application IMO, it is *not* a good practice. The view layer should not perform authentication logic. This should be placed in a Filter or a base Action method that secured actions call before executing. It's there as an example of using application specific custom tags with Struts tags. David From: Eyrignoux Marc [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: About the checkLogonTag of the example application Date: Thu, 3 Apr 2003 17:08:52 +0200 (CEST) Hi everybody, The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? Thanks in advance, Marc. ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Tired of spam? Get advanced junk mail protection with MSN 8. http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.463 / Virus Database: 262 - Release Date: 3/17/2003 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Add photos to your messages with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Unwanted Filter
I hope it is a configuration issue. I run a filter in my app to convert ServletRequest to com.oreilly.servlet.MultipartWrapper. However, at the end, in my action I find the request is turn into org.apache.struts.upload.MultipartRequestWrapper instead. How can I prevent this unwanted filtering from happening? Someone would like shed light on how org.apache.struts.upload.MultipartRequestWrapper is configured to run? Thanks a lot! Robert Wei - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: About the checkLogonTag of the example application
Is it allowed to contain something like if the user has the rights to see some data, he can see it ? NB: I have extended the html:text, html:textarea and html:link tags to manage that kind of things. Marc. --- David Graham [EMAIL PROTECTED] a écrit : The view should not contain *business* logic but it's perfectly reasonable to contain view logic. Something like: if accounts 10 display them in green else display in red. David From: A Stephen [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: About the checkLogonTag of the example application Date: Thu, 3 Apr 2003 08:47:17 -0800 I agree with David. The view layer should not perform authentication logic, IMO the view layer should not contain *any* logic [maybe I live in a fantasy world :-)]. -S - Original Message - From: David Graham [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, April 03, 2003 7:11 AM Subject: Re: About the checkLogonTag of the example application IMO, it is *not* a good practice. The view layer should not perform authentication logic. This should be placed in a Filter or a base Action method that secured actions call before executing. It's there as an example of using application specific custom tags with Struts tags. David From: Eyrignoux Marc [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: About the checkLogonTag of the example application Date: Thu, 3 Apr 2003 17:08:52 +0200 (CEST) Hi everybody, The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? Thanks in advance, Marc. ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Tired of spam? Get advanced junk mail protection with MSN 8. http://join.msn.com/?page=features/junkmail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.463 / Virus Database: 262 - Release Date: 3/17/2003 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Add photos to your messages with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Re: Validating user inputs
2) Where is the form definition from your struts-config.xml? form-beans form-bean name=logonForm type=org.apache.struts.validator.DynaValidatorForm form-property name=username type=java.lang.String/ form-property name=password type=java.lang.String/ form-property name=remember type=java.lang.String/ /form-bean /form-beans Greetings, Stefan __ Jetzt 52 verschiedene Briefpapiere fur Ihre E-Mails bei WEB.DE FreeMail - http://freemail.web.de/features/?mc=021140 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Validation not displaying
The submit is returning to the input page so I'm pretty sure that validation is working but no messages are being displayed. --- //jsp html:errors/ html:messages id=msg message=true name=org.apache.struts.action.GLOBAL_MESSAGE c:out value=${msg} escapeXml=false/ /html:messages html:form action='/companySearch' html:text property='companyName'/ html:submit styleClass=smButtonbean:message key='button.search'//html:submit /html:form //struts-config.xml form-bean name=selectCompanyForm type=org.apache.struts.validator.DynaValidatorForm form-property name=companyName type=java.lang.String/ /form-bean plug-in className=org.apache.struts.validator.ValidatorPlugIn set-property property=pathnames value=/WEB-INF/validator-rules.xml,/WEB-INF/validation.xml,/WEB-INF/validat ion-dyna.xml/ /plug-in //validation-dyna.xml form name=selectCompanyForm field property=companyName depends=required arg0 key=prompt.company.name/ /field /form //ApplicationResources.properties prompt.company.name=A company name is required to search on -Tim - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Removing nested bean collections in session scope.......
Hi, Thanks for considering this... I'm really stumped. I have several layers of collections, ie, a nest of beans inside a nested bean in an actionForm with session scope. When I am finished with the collections, I call my own reset method and set the top level collection to null. I am not overriding the default reset. I assume that if I set the top level collection to null, that there is no longer a reference to the other nested collections and they are garbage collected. When I re-use the actionForm within the same session, the collections that were nested are still in session scope and reappear. But, the collection that I set to null is null. I am sure I am getting the correct session bean because I check for an attribute with a unique value before and after I call my reset. I would really appreciate any insight or suggestions. Thanks Al -- Al Willingham [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Custom validation method that returns multiple error messages
Hi all, I'm using a custom validation method to enforce three rules regarding passwords. I would like to be able to display up to three error messages, but at first glance, the format required for the validator tag in my custom-validator-rules.xml file only permits one error message: !-- Validator for ensuring a password does not contain all or part of user name -- validator name=enforceSecurePassword classname=gov.sec.lib.validation.Validation method=enforceSecurePassword methodParams=java.lang.Object, org.apache.commons.validator.ValidatorAction, org.apache.commons.validator.Field, org.apache.struts.action.ActionErrors, javax.servlet.http.HttpServletRequest, javax.servlet.ServletContext msg=errors.password/ Anybody know if there is a way around this? Or do I have to have separate custom validation methods to enforce each rule? Thanks, Scott Moore [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Validation not displaying
Please disregard this. I'm tired and I set up my validation without the required messages. *sigh* -Tim -Original Message- From: Chen, Gin [mailto:[EMAIL PROTECTED] Sent: Thursday, April 03, 2003 12:45 PM To: 'Struts Users Mailing List' Subject: Validation not displaying The submit is returning to the input page so I'm pretty sure that validation is working but no messages are being displayed. --- //jsp html:errors/ html:messages id=msg message=true name=org.apache.struts.action.GLOBAL_MESSAGE c:out value=${msg} escapeXml=false/ /html:messages html:form action='/companySearch' html:text property='companyName'/ html:submit styleClass=smButtonbean:message key='button.search'//html:submit /html:form //struts-config.xml form-bean name=selectCompanyForm type=org.apache.struts.validator.DynaValidatorForm form-property name=companyName type=java.lang.String/ /form-bean plug-in className=org.apache.struts.validator.ValidatorPlugIn set-property property=pathnames value=/WEB-INF/validator-rules.xml,/WEB-INF/validation.xml,/WEB-INF/validat ion-dyna.xml/ /plug-in //validation-dyna.xml form name=selectCompanyForm field property=companyName depends=required arg0 key=prompt.company.name/ /field /form //ApplicationResources.properties prompt.company.name=A company name is required to search on -Tim - 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: [OT] log4j file path issue
I use ${catalina.home} and now I can get rid of my extra log4j.unix.properties. Thx, Tim. -Original Message- From: Tim Shadel [mailto:[EMAIL PROTECTED] Sent: April 2, 2003 11:03 PM To: Struts Users Mailing List Subject: Re: [OT] log4j file path issue I think this works. A quick look at the Log4j list (like Craig suggested) turned up these threads: These seem to hit the suggestions already offered: http://www.mail-archive.com/[EMAIL PROTECTED]/msg08056.html http://www.mail-archive.com/[EMAIL PROTECTED]/msg06026.html This one seems to be the most interesting: http://www.mail-archive.com/[EMAIL PROTECTED]/msg05432.html It appears that you can use ${some-system-property} in your config files. We do something similar to you, so I just tried this on our setup and it worked: log4j.appender.A1=org.apache.log4j.DailyRollingFileAppender log4j.appender.A1.DatePattern='-'-MM-dd log4j.appender.A1.File=${catalina.base}/logs/my.log I took advantage of the -Dcatalina.base property already defined in the catalina.sh file used to start Tomcat. If you'd like to use a custom System property this URL http://jakarta.apache.org/log4j/docs/manual.html#defaultInit describes how to set log4j properties using the CATALINA_OPTS environment variable, though I'm sure there are sources that give more direct instructions for setting System properties for Tomcat. Hope that helps, Tim P.S. I suppose this should get posted to Log4j's list too; but I'm also too lazy to go through the signup process and setup mail filters. :-) Dan Allen wrote: *This message was transferred with a trial version of CommuniGate(tm) Pro* I am working with a jsp developer who uses windows, where I use linux. When he checks out a copy of the application in the revision system, the log4j.properties file is not playing fair. I have in it log4j.appender.default.File=/var/tomcat4/logs/struts.log But his path to tomcat is not the same. If I try to do log4j.appender.default.File=struts.log then in linux it tries to make the file in / and doesn't understand relative paths. (Note: I am initializing log4j.properties in a init servlet like suggested in the manual). How do I specify that I want the log file in the logs directory of the tomcat installation. Even if I have to set something in the init servlet, I will do that, but HOW HOW HOW??? argh...apart from having 2 log4j.properties files. Dan - 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: About the checkLogonTag of the example application
Hi, then how are you going to tell struts Action that this guy has not logged in? -Original Message- From: Wendy Smoak [mailto:[EMAIL PROTECTED] Sent: April 3, 2003 10:23 AM To: 'Struts Users Mailing List' Subject: RE: About the checkLogonTag of the example application The checkLogonTag of the Struts application checks if the user has logged in the application before displaying a JSP page. Therefore it manages a part of the security of the application. I would like to know if this tag is a good practice ? If it can be used in a real world J2EE application ? If it is J2EE compliant and MVC compliant ? I think that right before you display a JSP is *way* too late to be checking to see if someone is logged in or not. I do it in a Filter and they never even get to the .do Action if they haven't logged in. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University PA Information Resources Management - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Removing nested bean collections in session scope.......
I have had this issue before. In your next action, remove mapping to the ActionForm in your struts-config.xml. -Original Message- From: Al Willingham [mailto:[EMAIL PROTECTED] Sent: April 3, 2003 12:47 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Removing nested bean collections in session scope... Hi, Thanks for considering this... I'm really stumped. I have several layers of collections, ie, a nest of beans inside a nested bean in an actionForm with session scope. When I am finished with the collections, I call my own reset method and set the top level collection to null. I am not overriding the default reset. I assume that if I set the top level collection to null, that there is no longer a reference to the other nested collections and they are garbage collected. When I re-use the actionForm within the same session, the collections that were nested are still in session scope and reappear. But, the collection that I set to null is null. I am sure I am getting the correct session bean because I check for an attribute with a unique value before and after I call my reset. I would really appreciate any insight or suggestions. Thanks Al -- Al Willingham [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]
Struts and session cleanup
Hi, Can any one suggest what is the best practise for session clean up ? In my opinion, Struts makes session clean up a mess. I understand that I can use scope for session data. But, for global sessions, what is the good way to clean sessions ? Thanks, _ Catch the Oscar fever. See winners losers. http://server1.msn.co.in/MSNSpecials/oscar2003/index.asp Right here - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]