Re: How to display message from resource bundle using Struts EL tags

2007-07-13 Thread Nuwan Chandrasoma
bean-el:message key=${stringvar}/http://struts.apache.org/1.3.8/struts-el/index.html- Original Message - From: semaj.najraham [EMAIL PROTECTED] To: user@struts.apache.org Sent: Friday, July 13, 2007 5:49 AM Subject: Re: How to display message from resource bundle using Struts EL tags

Re: [ANN] Struts Downloads Skyrocket in 2007

2007-07-13 Thread mirimoglu
Li-3 wrote: Great job. On 7/9/07, James Carr [EMAIL PROTECTED] wrote: congrats guys! On 7/8/07, Ted Husted [EMAIL PROTECTED] wrote: [Apache Struts Group] Since its release in June 2001, Apache Struts (struts.apache.org) has become the most popular web framework for Java. Six

Re: [S2] autocompleter, predefining initial value

2007-07-13 Thread Toni Lyytikäinen
I used a JSON action which outputs an array of arrays like this: [ [VALUE, KEY], [VALUE2, KEY2], ... ] I build the list beforehand in the Action with an iterator over a ListObjectType. I don't know about ftl since I've never used it. And now I'm in the process of migrating the app to use YUI,

Re: s2: Logging

2007-07-13 Thread Dave Newton
Perhaps more importantly, do you have a log4j xml or properties configuration file on the classpath? (IIRC you do not need to explicitly initialize.) --- Gary Feidt [EMAIL PROTECTED] wrote: What did you use for an Initialization procedure? [EMAIL PROTECTED] 7/12/2007 3:21:42 PM Hi, How

Re: s2: Logging

2007-07-13 Thread Gary Feidt
What did you use for an Initialization procedure? [EMAIL PROTECTED] 7/12/2007 3:21:42 PM Hi, How to enable logging in S2? I added log4j.jar and isDebug statements in my actions, but do not see any messages. Leena ___ Confidentiality

Re: [S2] autocompleter, predefining initial value

2007-07-13 Thread Toni Lyytikäinen
No, so far I have been programming with the YUI api directly using Javascript, as I need all kinds of widgets, not just the autocompleter and calendar. I may take a look at the YUI plugin and possibly try to add new widgets to it, if I manage to find the time. On 7/13/07, Pedro Herrera [EMAIL

Migrate Struts 1 EventDispatchAction to Struts 2

2007-07-13 Thread Boon Leng
May I know what is the best way to migrate Struts 1 EventDispatchAction to Struts 2? The following is my struts-config.xml where displaying form and submitting form is using the same action name but execute different methods in the action. action path=/*_add

Rendering an image into s:div from ajax

2007-07-13 Thread travers
Hi is it possible to specify href in s:div to render content as an image ? I have a struts2 action returning a JfreeChart chart as png. Without ajax, image src=/chart/ViewChart.action/ shows the chart correctly, but the following renders it as text (well actually the binary stuff inside the

Re: Rendering an image into s:div from ajax

2007-07-13 Thread Frank W. Zammetti
In general with AJAX this isn't possible... there's no way at present to insert binary data, be it an image, PDF, whatever, into the page, and have the browser render it. What you would have to do is return HTML instead, which includes an img tag pointing to the image on the server, which in this

Re: [s2] formatting in textfield

2007-07-13 Thread yitzle
I would image you would need some on_change JavaScript. I found this off Google: http://javascript.internet.com/forms/currency-format.html You might be able to adapt it somehow. - To unsubscribe, e-mail: [EMAIL PROTECTED] For

Re: Struts 2 performance

2007-07-13 Thread Ted Husted
On 7/13/07, Aram Mkhitaryan [EMAIL PROTECTED] wrote: Does someone know how to switch on the enhancement for ognl 2.7??? It's not a matter of throwing a switch. Some code would have to be rewritten in XWork 2 and Struts 2, which some people (James Holmes) are volunteering to do. -Ted.

Re: [S2] autocompleter, predefining initial value

2007-07-13 Thread Pedro Herrera
I agree , autocompleter is too slow... Are you using the http://cwiki.apache.org/confluence/display/S2PLUGINS/YUI+Plugin ? Herrera Toni Lyytikäinen wrote: I used a JSON action which outputs an array of arrays like this: [ [VALUE, KEY], [VALUE2, KEY2], ... ] I build the list

Re: [S2] UTF-8

2007-07-13 Thread Morten
Hi Perssy What do you mean by Page Header? Just curious. Working with some of the same things. Best regards, Morten Perssy Llamosas [EMAIL PROTECTED] skrev i en meddelelse news:[EMAIL PROTECTED] Solved it on my own. The page header requires to be in utf-8 too, it is not enough to have the

Re: Struts design best practice issue

2007-07-13 Thread Yoge
Write an interface with all the methods in your actionform. Your DTO bean class and actionform class should implement the interface. Now you dont need to do any type casting in your action class. Sorry if my understanding is wrong. --Yoge On 7/13/07, Viplav Kallepu [EMAIL PROTECTED] wrote:

Re: Struts 2 + Spring 2 + JPA + AJAX Tutorial

2007-07-13 Thread LucaLuca
Hi, I read that tutorial too and i've follewed all the steps. My problem is that i don't know which are the Jar requested. I was not able to find the strtus2-api.jar. Where i can find it? I've tried to add all the Hibernate 3.2, Spring 2.0.6, Struts 2.0.8 jar, but it did not work. It gives the

Re: [S2] autocompleter, predefining initial value

2007-07-13 Thread Pedro Herrera
Hi Toni. How do you assemble your list ? In my case I´m using a jsp result that is made from AjaxUtil . Is it possible to use flt for this case ?. In the showcase example, uses a option.flt(value only), but I need two, key and value instead. Thanks Herrera Toni Lyytikäinen wrote:

Struts 2 Spring IOC problem

2007-07-13 Thread alex xander
i have some problem with Spring IOC i use struts 2.x, hibernate 3.x and spring 2.x my problem is the destroy-method in my class don't respon anything it's looks like spring doesn't recognize my destroy method bean id=persistenceManager

Re: Rendering an image into s:div from ajax

2007-07-13 Thread travers
Makes sense. I was hoping to do dashboard type implementation with Jfreecharts where the ajax call to get the new chart based on a timer thats why I did not want to persist the chart somewhere. Frank W. Zammetti wrote: In general with AJAX this isn't possible... there's no way at present to

Re: Struts design best practice issue

2007-07-13 Thread Viplav Kallepu
Thanks for the reply.. but the variables in the actionform's datatype will be string and DTO's will be corresponding oracle dataType. I am not able to understand the advantage of writing the interface. May be I am missing the concept. Actually my doubt is whether I can write type conversion codes

File upload messages problem

2007-07-13 Thread Dean Pullen
I have a similar problem to a previous post that didn't get any replies. I'll relist it for quick reference: The documentation on the page File Upload Interceptor (http://struts.apache.org/2.x/docs/file-upload-interceptor.html) indicates that the error messages are currently set to

Diagnosing A Redirect Error

2007-07-13 Thread Ferguson, Jason M TSgt 375 CSPTS/SCE
I am attempting to run a brank-new webapp, and finally managed to kill enough code bugs that no odd exceptions are showing up in the application logs. However, attempting to hit the main page, login.jsp, causes Firefox to tell me The page isn't redirecting properly: Firefox has detected that the

Re: [S2] UTF-8

2007-07-13 Thread Perssy Llamosas
This is more a jsp/servlets/tomcat problem. There is a variable that controls character encoding in Struts2, it defaults to UTF-8 but I am not sure of when it is used by struts, I think it's for .properties reading. In struts.properties: struts.i18n.encoding=UTF-8 First you need to tell the

Autocompleter onchange

2007-07-13 Thread rrecoba
Hi, I can´t capture the onChange event of an autocompleter. Now I have the autocompleter working, but i need to fill a div from an ajax call when one item is selected in the autocompleter. How can I do this? Thanks a lot.- -- View this message in context:

RE: File upload messages problem

2007-07-13 Thread Dean Pullen
The person who had the original problem was kind enough to help. Added struts.custom.i18n.resources=struts-messages into struts.properties and added a struts-messages.properties file, placed the key/value pairs in there. Works fine. -Original Message- From: Dean Pullen [mailto:[EMAIL

Struts2 - Tab Panel

2007-07-13 Thread Marco Carnevale
We have an application using the s:tabbedPanel with multiple tabs loading dynamically. We are using struts 2.0.6 with tiles. What we are seeing is that the action that loads the tab content that is currently displayed is always called two times all the other tab actions are only called once.

Re: Struts 2 Spring IOC problem

2007-07-13 Thread Chris Pratt
I'm definitely no expert, but I think you're mixing new syntax with old. If I remember correctly singleton=false was replaced with scope=prototype. So maybe it was treating your beans as singletons, which is why they were never getting destroyed. (*Chris*) On 7/13/07, alex xander [EMAIL

Struts 2 and Tomcat 5.0.27 filter start error

2007-07-13 Thread Phillip Blevins
Greetings, I am trying to use a struts 2 application on Tomcat 5.0.27. I originally had it working on 5.5 but i had to downgrade to 5.0.27 because thats the version my web service has. I am getting the error SEVERE: Error filterStart when i try and start Tomcat. Thinking this might have to do

Struts2 + Eclipse

2007-07-13 Thread spaquet
Hi, I'm trying to setting-up a Dynamic Web project under Eclipse 3.3 (Europa). The project is OK and using Tomcat 6.0.13 but when editing jsp pages I have the following error: Invalid character used in text string (%@ taglib prefix=s uri=/struts-tags %). Welcome.jsp line 2 Invalid text

Re: How to display message from resource bundle using Struts EL tags

2007-07-13 Thread semaj.najraham
If I change as you mention, I get the following error: [ERROR] - Servlet.service() for servlet jsp threw exception javax.servlet.jsp.JspException: Missing message for key in bundle (default bundle) for locale en_US Any idea? Thanks, semaj nuwan chandrasoma-2 wrote: bean-el:message

Re: s2: Logging

2007-07-13 Thread Leena Borle
Hi, I did not add log4J.xml in the classpath. I am following mailreader tutorial and did not see any in that application too. Do I have to add it explicitly ? Leena On 7/13/07, Dave Newton [EMAIL PROTECTED] wrote: Perhaps more importantly, do you have a log4j xml or properties configuration

scope attribute must be declared.

2007-07-13 Thread Ryan
Hello, I'm new to struts and I'm using struts 2.0.6. I'm trying to persist some variables so they can be used across multiple forms. I've read a number of posts that say you can persist data across a session by adding the scope=session attribute to the action tag. e.g... action

Re: How to display message from resource bundle using Struts EL tags

2007-07-13 Thread Laurie Harper
That indicates that the expression you're passing in the 'key' attribute is evaluating to null or the empty string. Check how you're specifying the key, and feel free to post a sample of the JSP markup you're using if you still can't figure it out. L. semaj.najraham wrote: If I change as

Re: s2: Logging

2007-07-13 Thread Laurie Harper
Yes, you need to configure Log4J; just dropping the JAR in isn't enough for it to 'magically' know what you want it to do with log messages. See the Log4J documentation for details on configuration. As a quick start, you can create a WEB-INF/classes/log4j.properties with the following content:

Re: Struts design best practice issue

2007-07-13 Thread Laurie Harper
Struts2 provides automatic type conversion facilities, which makes life much easier in these cases. With Struts1, however, you need to handle the type conversion yourself. You can make this less painful by using the validation framework (so that by the time you get to doing the type

Re: How to display xml data in struts list box

2007-07-13 Thread Laurie Harper
Asir Jeeva wrote: Please give me an example to display *xml data in struts html:select box.* That would depend on what the data was and how you wanted to display it. You'll need to provide a more complete description of what you're trying to do for anyone to offer much help. L.

Re: [S2] UTF-8

2007-07-13 Thread Laurie Harper
Perssy Llamosas wrote: ... %@ page contentType=text/html; charset=UTF-8 pageEncoding=UTF-8 % ... The files (.java .jsp .???) MUST be saved as UTF-8 or the characters won't display correctly. To clarify, page encoding of JSPs is a separate issue. The only requirement here is that the

Re: Migrate Struts 1 EventDispatchAction to Struts 2

2007-07-13 Thread Laurie Harper
Boon Leng wrote: May I know what is the best way to migrate Struts 1 EventDispatchAction to Struts 2? The following is my struts-config.xml where displaying form and submitting form is using the same action name but execute different methods in the action. action path=/*_add

Re: Diagnosing A Redirect Error

2007-07-13 Thread Laurie Harper
Ferguson, Jason M TSgt 375 CSPTS/SCE wrote: I am attempting to run a brank-new webapp, and finally managed to kill enough code bugs that no odd exceptions are showing up in the application logs. However, attempting to hit the main page, login.jsp, causes Firefox to tell me The page isn't

Re: Struts 2 + Spring 2 + JPA + AJAX Tutorial

2007-07-13 Thread Ted Husted
The Struts2-api.jar is obsolete. The error seems to be related to hibernate. It looks like the class needed to instantiate entityManagerFactory is missing. Like as not, the only JARs you need for Struts are commons-logging-api, freemarker, ognl, struts2-core, and xwork, plus the stuts2-spring

Re: Struts 2 and Tomcat 5.0.27 filter start error

2007-07-13 Thread Roger Varley
On Friday 13 July 2007 18:08, Phillip Blevins wrote: Greetings, I am trying to use a struts 2 application on Tomcat 5.0.27. I originally had it working on 5.5 but i had to downgrade to 5.0.27 because thats the version my web service has. I am getting the error SEVERE: Error filterStart

Re: How to display message from resource bundle using Struts EL tags

2007-07-13 Thread semaj.najraham
Laurie, This is what I did %@ taglib uri=http://struts.apache.org/tags-bean-el; prefix=bean-el% %@ page import=com.messages.Constants % bean:message key=${Constants.SECTION_TITLE } / where Constants.java contains the following contants public static final String SECTION_TITLE =

Re: Autocompleter onchange

2007-07-13 Thread Musachy Barroso
Use the notifyTopics attribute. musachy On 7/13/07, rrecoba [EMAIL PROTECTED] wrote: Hi, I can´t capture the onChange event of an autocompleter. Now I have the autocompleter working, but i need to fill a div from an ajax call when one item is selected in the autocompleter. How can I do this?

Re: Struts2 - Tab Panel

2007-07-13 Thread Musachy Barroso
That was fixed on 2.0.8 I think musachy On 7/13/07, Marco Carnevale [EMAIL PROTECTED] wrote: We have an application using the s:tabbedPanel with multiple tabs loading dynamically. We are using struts 2.0.6 with tiles. What we are seeing is that the action that loads the tab content that is

How to keep users from accessing to *.jsp strightforword?

2007-07-13 Thread M.Liang Liu
I just would like to block users to get to the login.jsp through the url:http://somedomain.com/login.jsp. Instead,users can login with the url :http://somedomain.com/login.action--- actually the login.jsp page. With the help of code-in-behind-plugin,users can just login with the

RE: How to keep users from accessing to *.jsp strightforword?

2007-07-13 Thread Neil Aggarwal
M.Liang: Add this to your web.xml: !-- Do not allow users to load jsps directly -- security-constraint web-resource-collection web-resource-nameno_access/web-resource-name url-pattern*.jsp/url-pattern /web-resource-collection auth-constraint/ /security-constraint

Re: Migrate Struts 1 EventDispatchAction to Struts 2

2007-07-13 Thread Boon Leng
Hi, I would like to know is there any class in struts 2 which is equivalent to EventDispatchAction? So that I can convert the following: action path=/sample_add parameter=insert, default=showForm ... to something like this: action name=sample_add method=insert, default=showForm ... and

Re: How to display message from resource bundle using Struts EL tags

2007-07-13 Thread Nuwan Chandrasoma
Hi, I think it should be like this. bean-el:message key=${Constants.SECTION_TITLE } / Thanks, Nuwan - Original Message - From: semaj.najraham [EMAIL PROTECTED] To: user@struts.apache.org Sent: Saturday, July 14, 2007 2:02 AM Subject: Re: How to display message from resource bundle

Re: Migrate Struts 1 EventDispatchAction to Struts 2

2007-07-13 Thread Nuwan Chandrasoma
Hi, you can have a action mapping like this. action name=sample_{*} method={1} ... and in your action class have 2 method according to you example public String add1() { // your logic return SUCCESS; } public String add2() { // your logic return SUCCESS; } if a call like

Re: How to keep users from accessing to *.jsp strightforword?

2007-07-13 Thread M.Liang Liu
to Neil, Thanks for ur help,I noticed that with the help of error-page,I can redirect the *.jsp to the index.html. By the way,when I tryed to redirect to a url like /login.action,it does NOT work. However,this can meet my need all the way. Any comment? thx. On 7/14/07, Neil Aggarwal [EMAIL