Re: Populate two fields with one value

2007-05-18 Thread Ed Griebel
You should probably be doing this in your action class, not your JSP. If it should always be set to acc.firstName, then you could just hardcode a hidden field: On 5/18/07, Mansour <[EMAIL PROTECTED]> wrote: how to populate 2 fields in my action with one value ? for example I need to populate th

Re: IDE for struts-enabled web application

2007-03-30 Thread Ed Griebel
I agree with Dave, MyEclipse is a decent/good IDE, and unbeatable for the price, if you're paid by the hour you'll make back the $50 quickly. You might also want to take a look at the Eclipse WTP, I have not used it personally but I believe it has tools for JSP editing. Also, you can probably get

Re: Book recommendations for performance tuning

2007-03-22 Thread Ed Griebel
I'd second that book recommendation. I've read it and there's a lot of good tips in there. On 3/22/07, Karr, David <[EMAIL PROTECTED]> wrote: One I like is "Pro Java EE 5 Performance Management and Optimization", by Steven Haines. Note that Steven Haines is associated with Quest Software and Jp

Re: Time of displaying data on the page

2007-03-20 Thread Ed Griebel
Hi- Do you mean to say that the time difference is much less than the time from when you click the mouse, to when page is rendered in browser? In your code below, since you are using <%=scriptlets%> you are only going to measure the time that the Java servlet itself takes. This will not take int

Re: Please help: Struts tags don't evaluate any expressions

2007-03-16 Thread Ed Griebel
I've done EL expressions like you want to do. Try using the -el version of the html tag: On 3/16/07, irene <[EMAIL PROTECTED]> wrote: Hi, I have a problem with Struts tags. I can't use any expression (EL, runtime) in the tag attributes : The result is an error: Invalid argument l

Re: Need Help -Urgent

2007-03-14 Thread Ed Griebel
Textarea doesn't support the maxlength attribute: http://www.w3.org/TR/html4/interact/forms.html#h-17.7 On 3/14/07, Sachin <[EMAIL PROTECTED]> wrote: > > Hi , i am using below snippet and i am getting the following error : CP Description Error: [3/14/07 14:57:52:094 EST] 715b61a

Re: Two Struts validation problems

2007-03-03 Thread Ed Griebel
Chris is right, the zero occurs in the java.lang.Integer(String) constructor when it is passed a non-numeric string value. You would see this happen in your ActionForm and action class if you weren't using the validator. The same thing happens with a non-numeric in a java.lang.Double(String) const

Re: DynaValidatorForm and BigDecimal problem

2007-03-01 Thread Ed Griebel
It has nothing to do with Struts, the error message is saying that commons BeanUtils cannot convert the string from the form submit into a BigDecimal. Turns out that your issue is BigDecimal is not as permissive as Double when it converts a non-numeric string to a BigDecimal. If a string is not a

Re: Validation Framework and DispatchAction

2006-12-28 Thread Ed Griebel
Use a "page" field in your form (set this in your action class before you call form.validate()) and set page="x" in your validation.xml file. The example below shows using a HTML hidden field "page", which is a different way to set this page variable. http://struts.apache.org/1.x/struts-extras/di

Re: Preprocessing of request

2006-12-15 Thread Ed Griebel
:) Frank -- Frank W. Zammetti Founder and Chief Software Architect Omnytex Technologies http://www.omnytex.com AIM/Yahoo: fzammetti MSN: [EMAIL PROTECTED] Author of "Practical Ajax Projects With Java Technology" (2006, Apress, ISBN 1-59059-695-1) Java Web Parts - http://javawebparts.sourceforge.

Re: Preprocessing of request

2006-12-14 Thread Ed Griebel
You would define a base action that extends org.apache.struts.action.Action and includes a method execute() or maybe a helper method doSetup(). Your action classes would then extend this BaseAction class and then one of the first things you would do in execute() would be to call super.execute() o

Re: log4j configurations?

2006-12-13 Thread Ed Griebel
I've never used Exadel, but you can try to look for a WEB-INF/classes or WEB-INF/lib directory in your project, they are usually included in IDE-based execution. HTH, -ed On 12/13/06, Mallik <[EMAIL PROTECTED]> wrote: Hi friends i am working on struts in Exadel studio i am getting the error: -

Re: Displaying a JSP in a pop-up window

2006-12-05 Thread Ed Griebel
The trick is to use the target="xx" parameter in the generated tag. Try something like this: In your jsp you will have . In your struts-config you will have http://struts.apache.org/1.2.7/userGuide/struts-html.html#link http://www.onjava.com/pub/a/onjava/2002/10/30/jakarta.html?page=3 -ed On

Re: Query

2006-12-05 Thread Ed Griebel
Start here, it doesn't get much clearer than this, and google for unfamiliar terms: http://www.learntechnology.net/struts-lesson-1.do On 12/5/06, Jagaran Bubai Das <[EMAIL PROTECTED]> wrote: I hav done that... but how to install and run the sample application i am not clear.. it would be gre

Re: How to get a dynaform in the Action class ?

2006-12-01 Thread Ed Griebel
I prefer dynaforms as I don't need *any* explicit formbean classes. With a good-sized application there's 30 classes I don't need to maintain. For a further reduction, use Lazy-flavor Dyna beans, then no changes to XML are required, just change the action class and JSP. -ed On 12/1/06, Thomas Th

Re: VALIDATION

2006-11-30 Thread Ed Griebel
Sorry, I assumed you were using S1, I don't know how for s2. On 11/30/06, Juan Espinosa <[EMAIL PROTECTED]> wrote: Im using struts2, doing in this way works in struts2 In struts2 i have the object mapping and form?? -Mensaje original----- De: Ed Griebel [mailto:[EMAI

Re: VALIDATION

2006-11-30 Thread Ed Griebel
The easiest way to do this is to turn off automatic validation in your struts-config.xml and manually call validation in your desired methods. Something like: ActionMessages errors = form.validate(mapping, request); if ( errors != null && errors.size() > 0 ) { LOG.warn("Errors detected!!"); r

Re: Validation XMl entity

2006-11-24 Thread Ed Griebel
Struts validation is generally used only for validations of fields from HTTP submissions, check out http://struts.apache.org/1.x/faqs/validator.html If you need to validate an XML file, you may be able to use the Apache Digester classes (http://jakarta.apache.org/commons/digester/) or some of the

Re: need help in Tag-lib

2006-11-24 Thread Ed Griebel
Propertiesid is probably a java.lang.Long, and at some point datain is this URL above, and the URL cannot be converted to a Long to be assigned to propertesid. To figure out which one it is, you could iterate thru the collection and log each element inside your action before the JSP is called. As

Re: html form

2006-11-22 Thread Ed Griebel
In short, no. You should create hidden fields for each of the params you want to pass. On 11/22/06, temp temp <[EMAIL PROTECTED]> wrote: I have a html form Display OptionsShow 10 Show 20 Show 50 Show 100 Show 200 When I receive request posted

Re: can not reach the jsp file

2006-11-17 Thread Ed Griebel
Does Welcome.do work correctly? I would first try to get that working because then you will know that your jsp's are in the correct directory and you are calling the do from the correct directory. If Welcome.do doesn't work, check out: - check that you have defined that *.do is mapped to Struts s

Re: Dynamically adding row!

2006-11-15 Thread Ed Griebel
will then do the populate. That's why I suggested the ajax call to add the record to the server side struts form so that the subsequent post will populate the fields. -Original Message- From: Ed Griebel [mailto:[EMAIL PROTECTED] Sent: 14 November 2006 14:24 To: Struts Users Mai

Re: setting an an html:text value with another html:text

2006-11-14 Thread Ed Griebel
This general approach would work, but if you can use JSTL, it could be written much cleaner as: ... You may be able to get away with not even having the statement and using just ${editable} On 11/14/06, Puneet Lakhina <[EMAIL PROTECTED]> wrote: On 11/14/06, Adam K <[EMAIL PROTECTED]> wrote:

Re: Struts 1.3.5 and Eclipse 3.2

2006-11-14 Thread Ed Griebel
7; comment correctly, it might just be a question of a simple rebuild. bruno -Original Message- From: Ed Griebel [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 14, 2006 9:54 AM To: Struts Users Mailing List Subject: Re: Struts 1.3.5 and Eclipse 3.2 YOu don't need to (and never s

Re: Dynamically adding row!

2006-11-14 Thread Ed Griebel
You can have a form auto-populate from the javascript-generated fields, you just need to be careful what you call the generated field names. It will be hard-coded and none too attractive, but it will work. Look at the rendered HTML to see what format the field names are as an example. HTH, -ed O

Re: Validation + multiple Submit buttons

2006-11-14 Thread Ed Griebel
You could turn off automatic validation in struts-config.xml and call it manually in the action method when you need validation. If you are using a recent version of Struts you can use LookupDispatchAction that will call a given method based on which button was pressed. http://struts.apache.org/

Re: Struts 1.3.5 and Eclipse 3.2

2006-11-14 Thread Ed Griebel
YOu don't need to (and never should) extract TLD files from jars and put them into a WEB-INF directory in your war. Web app servers that follow servlet version 2.3 and up have been able to extract TLDs from jars. See for more information: http://struts.apache.org/1.2.9/userGuide/configuration.html

Re: DispatchAction help?

2006-11-13 Thread Ed Griebel
You should do validation manually in your action. Set "validation='false'" in your struts-config.xml and call form.validate in the action methods that need to be validated on. For example, do something like this in a method: ActionMessages errors = form.validate(mapping,request); if ( errors != n

Re: html messages tag

2006-11-13 Thread Ed Griebel
The error message is not related to the tag. This error is caused by having an html:xxx form field tag (checkbox, file, text, textarea, password, etc.) that is not inside an tag. Look at the erroring jsp's to see where this is the case. Often exception traces (if the JSP is compiled with debugg

Re: logging initialization order

2006-11-12 Thread Ed Griebel
On 11/10/06, Ping Yu <[EMAIL PROTECTED]> wrote: Nov 9, 2006 2:35:23 PM org.apache.catalina.startup.HostConfig deployWAR INFO: Deploying web application archive test.war log4j:WARN No appenders could be found for logger (org.apache.commons.digester.Digester). log4j:WARN Please initialize the

Re: object[] to string[]

2006-11-10 Thread Ed Griebel
On 11/10/06, Martin Gainty <[EMAIL PROTECTED]> wrote: I dont know 'pendantic' so I would suggest System.arrayCopy as in (Sorry for being pedantic...) LOL, TGI Friday! :-) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additi

Re: iterate through two collections

2006-11-10 Thread Ed Griebel
Try using . indexId should be replaced with 0, 1, 2, ... as it iterates and the underlying BeanUtils will extract the n-th element from the collection. I don't think this will if you are using an unsorted collection (set, map) because they don't support get(int) On 11/10/06, Van Nguyen <[EMAIL P

Re: object[] to string[]

2006-11-10 Thread Ed Griebel
Maybe I'm just being pendantic, but this isn't really related to Struts at all. java.util.Arrays and java.util.Collections provide a lot of methods to transform between arrays and collections. You will find your answer after some reading and some experimentation. On 11/10/06, temp temp <[EMAIL P

Re: problem with moving jsp pages under web-inf/ folder

2006-11-09 Thread Ed Griebel
y Adjuvant Chemo Hormonal Biologic Agents Clinical Trial <%-- Images --%> <%-- robin: Check with M if this is required here. --%> Pathologies Biopsies Clinical Evaluation/Follow-ups <%--View Images--%> View Images Mammograms X-Rays Bone Scans CT Scans Ultrasound Scans MRI Stu

Re: problem with moving jsp pages under web-inf/ folder

2006-11-09 Thread Ed Griebel
What happens when the JSP is converted to HTML, it is sent to the browser. The browser then tries to access the css and js files from the webserver, but since the HTML points to web-inf, it won't serve them. One way to do it is to create an action mapping that is just defined as a ForwardAction,

Re: Struts problem, random properties after every restart of server

2006-11-08 Thread Ed Griebel
I have never experienced this problem, so this is a guess. Since it always comes up in German, it seems like the German locale is set somewhere either in the app server or operating system configuration. Did you check the locale setting on your client's machine and for the user that Orion is runni

Re: how recover a map of a bean in a "select list" of the jsp and to post the data ?

2006-11-06 Thread Ed Griebel
You need to use either or to iterate over your beans. This deals with arrays but is useful for how to use the iterator and how to populate a select list: http://husted.com/struts/tips/006.html HTH, -ed On 11/6/06, nalimoussa <[EMAIL PROTECTED]> wrote: Hi everybody, I have to create a map i

Re: DynaActionForm indexed properties

2006-11-02 Thread Ed Griebel
If you are using basic arrays you need to create an array for the item before the JSP is displayed. You might want to use a java.util.List instead, you don't need to pre-allocate when using Dyna forms. HTH, -ed On 11/2/06, Puneet Lakhina <[EMAIL PROTECTED]> wrote: Hi, This is the first time I

Re: logging system initialization

2006-10-30 Thread Ed Griebel
logging), use a javax.servlet.ServletContextListener and process the contextInitialized() event. It gets called before anything else in the context gets initialized. (*Chris*) On 10/30/06, Ed Griebel <[EMAIL PROTECTED]> wrote: > > For a WAR file you are going to deploy: create a log4j.properties or a > log4j.xml fi

Re: logging system initialization

2006-10-30 Thread Ed Griebel
For a WAR file you are going to deploy: create a log4j.properties or a log4j.xml file and get it into your warfile under WEB-INF/classes. The actual process of doing this differs if you are using Maven, an IDE deployer (e.g. JDeveloper or WSAD), or Ant to generate and deploy a WAR. For a webapp r

Re: Session tracking in struts?

2006-10-28 Thread Ed Griebel
To answer your question: 1) create a filter that does your tests for a "valid" session but only check it if the "isNewSession" flag in a session is not set. When you find a bad session, call session.invalidate() and forward to an for the login page. You should add redirect="true" to the action-fo

Re: Tags nested

2006-10-27 Thread Ed Griebel
Or in a JSP 1.0 environment, use the EL Struts libraries: wrote: Juanjo Cuadrado wrote: > > > I think that JSP spec firbids this. The inner ${dataQueries.name} -- Mikolaj Rydzewski <[EMAIL PROTECTED]> - To unsubscr

Re: new line char in xml

2006-10-26 Thread Ed Griebel
To generate a blank line I've used HTH, -ed On 10/26/06, Chris Pratt <[EMAIL PROTECTED]> wrote: You can't specify a newline character in XML. XML specifically normalizes all whitespace out of the data. If you need to handle data that contains specific formatting, you need to apply that forma

Re: Drag-and-drop struts-aware IDE?

2006-10-25 Thread Ed Griebel
Yes, this is the "issue" with Struts, it's hard for an OSS product to compete with the .Net marketing juggernaut. MS seems to be happy trotting out their dog-and-pony show to anyone who will look at it. The source control, code checking, etc. components in Eclipse match closely to what VisualStudi

Re: How to show downloadable link using FormFile class .

2006-10-25 Thread Ed Griebel
nation, But the problem is DownloadAction came with struts 1.2 and i am using 1.1 :( And i am saving the file in databse as blob. I can get content using resultset.getblob("file") but what after that ? How can i transfer this to my formbean's file field ?? On 10/25/06, Ed Griebel

Re: How to show downloadable link using FormFile class .

2006-10-25 Thread Ed Griebel
What I have done in this situation is - obtain a list of valid files and create an identifier or "token" for each one (usually as simple as the name of the file) corresponding with the identifier expected in the action described below - throw the list of files into a List in the request/session/fo

Re: Debugging struts applications with eclipse

2006-10-24 Thread Ed Griebel
This should answer all your questions: http://tomcat.apache.org/faq/development.html Google is your friend, this is the first link for "tomcat eclipse debugging" search. -ed On 10/24/06, Joe Yuen <[EMAIL PROTECTED]> wrote: Can anyone tell me how to debug an application running under tomcat? I

Re: Performance of my code

2006-10-24 Thread Ed Griebel
On 10/24/06, Daniel Chacón Sánchez <[EMAIL PROTECTED]> wrote: Hi all, this is not a question about struts, but is a question about java, Well then it probably shouldn't be asked here :-) Is there a tool that let me check performance issues in my code, like example the variables that I declar

Re: Forward Action to Action

2006-10-23 Thread Ed Griebel
The easiest is to put your data as attributes in the request scope with request.setAttribute( name, value), and then extract them in the second action with 'MyClass value = (MyClass) request.getAttribute(name)'. You can also put the attributes in the session scope, but you need to remember to remo

Re: Struts Validation DTD

2006-10-23 Thread Ed Griebel
(Redirecting response to user list where this type of question belongs...) You can swap in the new validator version without any changes to the rest of your application; the commons-validator team run a regression test at the binary level. This page has a complete list of what jars need to be upd

Re: render trademark symbol

2006-10-11 Thread Ed Griebel
ge- From: Van Nguyen Sent: Tuesday, October 10, 2006 11:59 AM To: Struts Users Mailing List Subject: RE: render trademark symbol Ok... setting the filter to false works. Thanks! -Original Message- From: Ed Griebel [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 10, 2006 11:26 AM To:

Re: html form instantiating form bean

2006-10-11 Thread Ed Griebel
You should not instantiate manually your own formbean nor put it into the request scope, you must use the formbean passed into your action class via the ActionForm object. When you get the handle to the formbean you can either cast the formbean to it's real class or you can use BeanUtils.populate

Re: render trademark symbol

2006-10-10 Thread Ed Griebel
EMAIL PROTECTED]> To: "Struts Users Mailing List" Sent: Tuesday, October 10, 2006 6:14 PM Subject: RE: render trademark symbol Is escapeXml an attribute for the bean:write tag? I do not see that in the Struts 1.2.9 API. -Original Message- From: Ed Griebel [mailto:[EMAIL PROTEC

Re: render trademark symbol

2006-10-10 Thread Ed Griebel
bean:write may be escaping the & so maybe you could try adding escapeXml="false" inside the bean:write tag. -ed On 10/10/06, Van Nguyen <[EMAIL PROTECTED]> wrote: That displays: (r) We need it to display: (tm) -Original Message- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: Tue

Re: content management system

2006-10-10 Thread Ed Griebel
http://opensourcecms.com will tell you all you need to know, it even has demos set up for every CMS. Now, as this has absolutely nothing to do about Struts, can further conversations occur offline? Thanks. -ed On 10/10/06, Stein Erik Berget <[EMAIL PROTECTED]> wrote: On Tue, 10 Oct 2006 14:12:

Re: jsession id in url

2006-10-04 Thread Ed Griebel
http://www.junlu.com/msg/287317.html As stated in above response to (your) similar question, the first request that is returned will have jsessionid= appended. To get rid of it you can try having the first page of the application be a "dummy" page that merely redirects to the real page. The reas

Re: session management

2006-10-04 Thread Ed Griebel
It is not clear what you are asking. Is the problem that - the session is not being maintained even when setting the timeout to 30 minutes - even after 1/2 hour the session does not timeout An observation, "pinging" the server every 10 seconds will create a lot of unnecessary work on the server.

Re: Avoiding multiple validation messages

2006-10-03 Thread Ed Griebel
t;bean" %> Username: Password: Submit Priya On 10/3/06, Ed Griebel <[EMAIL PROTECTED]> wrote: > In your form's onclick="validate()" method (or whatev

Re: Avoiding multiple validation messages

2006-10-03 Thread Ed Griebel
In your form's onclick="validate()" method (or whatever it may be called in your case), it may work to add "return" to the javascript method call. The validate method will return false if validation fails, and the form will not be submitted back to the server. HTH, -ed On 10/3/06, priya <[EMAIL

Re: Session Timeout

2006-08-30 Thread Ed Griebel
[moving to struts-user list] A new session is created when you request a new session somewhere, it's not created automatically. However, there could be a filter, request processor, action, or JSP somewhere that does a request.getSession() or .getSession(true) (or '... session="true"...' in JSP),

Re: Has anyone had this problem? Getting 3 question marks ??? at top of HTML page using action class and rendering JSP in browser

2006-08-02 Thread Ed Griebel
There's not much to go on, but check to see that all keys referenced in are defined in the appropriate message properties files. Look at in your struts-config.xml file to see what properties files are included. -ed On 8/2/06, Patterson, Marie E [CPB] <[EMAIL PROTECTED]> wrote: Has anyone had

Re: Can you use a LinkedList or similar as the type for a FormElement?

2006-08-01 Thread Ed Griebel
Lists is where you want to be headed, see answer to previous question as to how to do it on JSP. The key is that the Jakarta BeanUtils/PropertyUtils classes treat arrays and collections the same way so both can use brackets for element indexing. The key is to predefine the instance, I think struts

Re: Some JSP Taglib help needed

2006-08-01 Thread Ed Griebel
You could try something like: or create student_name as a java.util.List if using a POJO for an ActionForm - Create a setup action that is called before the JSP is initially rendered which does a '((MyFormType)form).student_name = new java.util.ArrayList();' - In the JSP form: ... -ed On 8

Re: dynamic casting in Action class

2006-07-26 Thread Ed Griebel
If you only need to get predefined variables, you can use Jakarta BeanUtils or PropertyUtils on the object. For instance, with a form bean ActionForm form: String val = BeanUtils.getProperty("someProperty"); Object valAsOriginalClass = PropertyUtils.getProperty("someProperty"); BeanUtils.setPrope

Re: problems using validation framework in struts

2006-07-11 Thread Ed Griebel
I haven't seen this error, but my guess is that you have referenced a form bean in your validation.xml that is not defined in struts-config.xml. Look for a typo in the name. -ed On 7/11/06, Anil Kumar Pippalapalli <[EMAIL PROTECTED]> wrote: hi all, iam new to struts and iam tryin out a simpl

Re: Eclipse plugin

2006-06-29 Thread Ed Griebel
I've used MyEclipse also, it works pretty well. It can be a little rough around the edges, but you can't beat the price, $50 w/UML support, $30 without. I'm currently using NitroX v2, since bought by BEA and rebranded BEA Workbench or something like that. It's a lot more expensive, but it is bett

Re: html-el:checkbox No Longer Works If Preceded by html-el:form

2006-06-29 Thread Ed Griebel
The reason is that your checkbox really is no longer in the form, so the framework doesn't know where to pull the value from. All of the and tags which create form 'widgets' must be between and . What you probably need to do is to create a second form on the page by adding before the and cha

Re: Validate just certain fields

2006-06-27 Thread Ed Griebel
You can use the "page" attribute on the validations, with the "page" attribute. Look at http://struts.apache.org/struts-doc-1.2.9/userGuide/dev_validator.html under "Multi page forms" for an extremely brief overview. Basically, create a java.lang.Integer variable in your form called "page" and b

Re: handle to form w/i jsp?

2006-06-23 Thread Ed Griebel
If you know the formbean it's a simple as If you don't konw the formbean name or want to make it generic you can get the current action's form bean name and then populate it something like below. Modify requestScope/sessionScope as appropriate. HTH, -ed On 6/23/06, Brian Long <[EMAIL PROTEC

Re: Why My JSTL Tag Cannot Do What Struts Tag Does?

2006-06-22 Thread Ed Griebel
You don't need to do the intermediate assignment to user, it should be sufficient to do: --- --- Al

Re: how to download a file

2006-06-22 Thread Ed Griebel
Take a look at org.apache.struts.actions.DownloadAction, I created an action that extended it (and implemented the internal StreamInfo) and was able to create an action that downloaded a PDF doc in less than an hour. For creating a new file to stream, one approach is to create the temp file using

Re: seeking quick start struts tutorial

2006-06-21 Thread Ed Griebel
There's too many to mention; here are some of my favorites: http://struts.apache.org/struts-action/index.html http://struts.apache.org/struts-action/userGuide/index.html http://www.learntechnology.net/ Look at Struts Lessons in left menu http://courses.coreservlets.com/Course-Materials/struts.htm

Re: need urgent help

2006-06-20 Thread Ed Griebel
This exception is caused by outputting a message without specifying a message resource in your struts-config.xml file. You can learn some more about Struts starting at these links: http://struts.apache.org/struts-action/index.html http://struts.apache.org/struts-action/userGuide/index.html -ed

Re: web.xml specifications from 2.4 to 2.3

2006-06-14 Thread Ed Griebel
You can't do it without changing your JSPs. It isn't as simple as wrapping everything with as JSP tags cannot be nested within attributes. Also, to my knowledge there is no way to just include some jar file to enable EL exprs. A suggestion too, your code: can be rewritten as: HTH, -ed On 6

Re: struts-config xml file throws a java exception

2006-06-07 Thread Ed Griebel
Hi Oliver- I'm going to guess that you have defined a form bean and properties in your form bean, and one of these properties is called "loginRequired". I'm also going to guess that you don't have a setter method for this property with the method signature of 'public void setLoginRequired(String

Re: Object size in App Server

2006-05-25 Thread Ed Griebel
For interactive session viewing look at http://messadmin.sourceforge.net/. It's not something I'd put on a production server, but it is useful for testing. -ed On 5/25/06, Chaudhary, Harsh <[EMAIL PROTECTED]> wrote: I just wrote the object to a file as a bit blob and looked at the file size. Bu

Re: Getting a list of fields in a form along with their values

2006-05-24 Thread Ed Griebel
Take a look at jakarta BeanUtils.describe() -ed On 5/24/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: Hello, The DynaActionForm class has a method called getMap which "Returns the Map containing the property values" We've found this quite useful for some of the things we need to do. I am l

Re: How to disallow opening a page directly from URL

2006-05-17 Thread Ed Griebel
Put your JSPs unde WEB-INF and forward to the JSP in struts-config.xml: http://www.onjava.com/pub/a/onjava/2002/10/30/jakarta.html?page=3 For roles, use declarative roles: http://wiki.apache.org/struts/ApplicationSecurity http://www.onjava.com/pub/a/onjava/2004/02/18/strutssecurity.html -ed On

Re: How to dertermine the url from which a request is made ?

2006-05-15 Thread Ed Griebel
You can check the "referer" field in the request, notice that the actual field name is misspelled. Also, the field is optional and browser-dependent if it's sent (but most/all modern browsers will send it), and a user could spoof this field as well. You may be better off putting the current URL i

Re: how to display a message for every request

2006-05-08 Thread Ed Griebel
You can create a base action class which extends Action and implements execute(). In execute you would call your preferred logging method as described below. Then, every action you create would extend your BaseAction class and the first line of every execute() method would call super.execute() -e

Re: page validation in wizzard app

2006-05-07 Thread Ed Griebel
On 5/7/06, Jakub Milkiewicz <[EMAIL PROTECTED]> wrote: Hi I do not catch it: > name="validation_failed" action="RepopulateAction"/> > I do not think this synax is ok. The is inside of a block in your struts-config.xml, the syntax is approximate and should be enough to give you the idea. T

Re: page validation in wizzard app

2006-05-07 Thread Ed Griebel
ion. Moreover if i disable autovalidation i do not have to make those tricks to decrement page in validate if errors are found. 2006/5/6, Ed Griebel <[EMAIL PROTECTED]>: > > Hi Jakub- > > I'm not sure if I fully understand your pageflow, but here goes. I > would turn of

Re: page validation in wizzard app

2006-05-06 Thread Ed Griebel
Hi Jakub- I'm not sure if I fully understand your pageflow, but here goes. I would turn off automatic validation in struts_config.xml. In each action, one of the first things I would do is call form.setPage(pageNo) and then call form.validate(...), and if there are any errors I'd return an Action

Re: Struts filter help

2006-05-05 Thread Ed Griebel
Depending on what you mean by "Java file starts", there's 3 things you can do. - Once on creation of a session, implement HttpSessionListener and specify the listener in web.xml - Once for every request, create a filter by extending AbstractHttpFilter or implementing HttpFilter and specify the fi

Re: How to create a Waiting Page for long requests?

2006-05-03 Thread Ed Griebel
PROTECTED]>: > > Ed Griebel wrote: > > The tricky part is that you can't create a new thread in your action > > as it violates the servlet spec (as you don't know what thread will > > get subsequent requests from the same session, so you've lost the > > ha

Re: How to create a Waiting Page for long requests?

2006-05-03 Thread Ed Griebel
I've done exactly this in another app with both a meta-tag to resubmit and a button to do same. It would check a "status flag" somewhere (db, session var, whatever) and when set it will jump to a "done" action. The tricky part is that you can't create a new thread in your action as it violates th

Re: jsessionid problem fix for weblogic servers

2006-05-02 Thread Ed Griebel
I don't have a copy of SIA, so I'm not sure what it says, but as I understand URL rewriting, it is always used on the struts URLs on the first page returned after a session is initiated, and for links in subsequent pages when the browser doesn't return a cookie with the session ID. By turning this

Re: Validator rules not loaded

2006-05-02 Thread Ed Griebel
You probably have some kind of typo in your DTD specification in validation.xml or validator-rules.xml, as most modern appservers will pull DTDs out of jars. Ensure that commons-validator.jar is included in your war/ear file. Also, if validator rules are so critical to security, you should probab

Re: StrutsTestCases

2006-04-27 Thread Ed Griebel
There was a question about this a couple of days ago where web.xml was not being found. Also, it looks like you have a leading slash before the "D:" in setConfigFile(), that could be the problem. HTH -ed On 4/27/06, Chaitanya Parkhi <[EMAIL PROTECTED]> wrote: > hi friends i m working on Struts

Re: Synchronization of dispatch Action

2006-03-21 Thread Ed Griebel
To answer your question, in general, its a very bad idea to synchronize action methods as that will bring your webapp to a screeching halt because Struts only creates a single instance of a given action class. What you will be doing is essentially handling a single request at a time, very bad. Now

Re: Java (O/T) thing

2006-03-14 Thread Ed Griebel
I wrestled with this exact thing this week. For the benefit of people searching the archives, to force a 1.4-compatible JDK to be used by a 1.5 compiler you can use "-target 1.4 -source 1.4" on the javac command line, or for ant, "target='1.4' source='1.4' " in your javac task. -ed On 3/14/06, W

Re: remove ActionForm from session

2006-03-12 Thread Ed Griebel
If you don't need to access it in your JSP page, you can do 'request.getSession().removeAttribute("myFormBean");' If your JSP needs the form, at the end of the JSP page you can put ''. You will have to include the proper taglib as well, google "c:set" for more information. -ed On 3/11/06, Markus

Re: How To Use Existing Tags to Test and Write Out the Value of the Size of a Collection?

2006-03-07 Thread Ed Griebel
If you're using a JSP 2.0 container you can use fn:length(), see http://www.onjava.com/pub/a/onjava/2003/11/05/jsp.html?page=last and http://java.sun.com/products/jsp/jstl/1.1/docs/tlddocs/fn/length.fn.html If you're not using a JSP 2.0 container, you can use a taglib in the Jakarta Taglibs sandbo

Re: [FRIDAY] You might be a pointy-haired-boss if ...

2006-01-30 Thread Ed Griebel
- When PHB asks for weekly progress report on a project and you begin to describe tasks a, b, and c completion status, he interrupts with "I just need to know a percentage", and then gets visibly annoyed when you take last week's progress and just add 5% to it. - When PHB tries to relate his mainf

Re: constant strings in the tags

2006-01-24 Thread Ed Griebel
I've just started using the taglib "unstandard" in the Jakarta Sandbox which has a JSP tag that does exactly what you want. Say you have a class called org.myorg.Constants, this tag creates an associative array of the members like so: <%@ taglib uri="http://jakarta.apache.org/taglibs/unstandard-1.0

Re: What JDK version are you using?

2006-01-23 Thread Ed Griebel
1.4 (+ Struts 1.2 ) We're locked into this for at least a couple of years, corporate decision. -ed On 1/23/06, Niall Pemberton <[EMAIL PROTECTED]> wrote: > What JDK version are you using? > > - > [ ] JDK 1.2 > [ ] JDK 1.3 > [ ] JDK 1.4 > [ ] JDK 1.5 (or JDK 5) > -

Re: struts and JSTL

2006-01-23 Thread Ed Griebel
The problem is that you're putting the 'amount' field into a hidden field and then trying to use that hidden field as a value, but your amt bean will actually contain the value of the form field: "" Try this instead. First, in your action save this amount value to the request scope: request.set

Re: downloading a file using struts action class

2006-01-17 Thread Ed Griebel
On the thread today called "gone MAD with servlet / xls download on winXP", someone suggested that sending the no-cache directive will cause IE to download the file and then remove it before starting the associated application. This sounds like what is happening in your case as well. -ed On 1/17/

Re: gone MAD with servlet / xls download on winXP

2006-01-17 Thread Ed Griebel
I agree, it sounds like a configuration issue on your PC. Have you tried it on a different PC? Possibly one not set up by the same Corporate IT department? -ed On 1/17/06, Thomas Joseph <[EMAIL PROTECTED]> wrote: > Try any/all of these: > 1. WinXP + Firefox. > 2. reinstalling Excel > 3. save file

Re: more on wicket

2006-01-16 Thread Ed Griebel
On 1/16/06, Nick Heudecker <[EMAIL PROTECTED]> wrote: > You can create aliases in the current version to provide shorthand names for > pages. Wicket 1.2 will allow you to mount pages at specified URLs, which > should get around this problem. ...which are currently configured by what, XML? Doesn't

  1   2   >