struts 2 + java 1.4 + maven

2008-11-06 Thread Andrei Ivanov
Hello, I'm forced to use java 1.4 and I was very happy to see there are jars that work with it. The thing is I also want to use maven for managing dependencies and I don't know how to specify in my pom that it has to use the translated jars... (I also have other projects that use struts/xwork with

Re: struts 2 + java 1.4 + maven

2008-11-06 Thread Antonio
2008/11/6 Antonio [EMAIL PROTECTED]: 2008/11/4 Andrei Ivanov [EMAIL PROTECTED]: I'm forced to use java 1.4 and I was very happy to see there are jars that work with it. The thing is I also want to use maven for managing dependencies and I don't know how to specify in my pom that it has to

Re: struts 2 + java 1.4 + maven

2008-11-06 Thread Nils-Helge Garli Hegvik
I couldn't find the backport-jars in any official repository, but you can install the backport files (semi)manually by using the 'mvn install:install-file' command. http://maven.apache.org/plugins/maven-install-plugin/index.html Nils-H On Thu, Nov 6, 2008 at 10:39 AM, Andrei Ivanov [EMAIL

Re: struts 2 + java 1.4 + maven

2008-11-06 Thread Antonio
2008/11/4 Andrei Ivanov [EMAIL PROTECTED]: I'm forced to use java 1.4 and I was very happy to see there are jars that work with it. The thing is I also want to use maven for managing dependencies and I don't know how to specify in my pom that it has to use the translated jars... It depends

Re: struts 2 + java 1.4 + maven

2008-11-06 Thread Andrei Ivanov
On Thu, Nov 6, 2008 at 11:53 AM, Antonio [EMAIL PROTECTED] wrote: 2008/11/4 Andrei Ivanov [EMAIL PROTECTED]: I'm forced to use java 1.4 and I was very happy to see there are jars that work with it. The thing is I also want to use maven for managing dependencies and I don't know how to specify

Unit Testing Advice

2008-11-06 Thread Gundersen, Richard
Hi Just after a bit of advice for the best way to unit test my Struts 2 app. I'm using a fairly standard Spring/Struts2/JPA/Junit architecture, and my tests need access to all my spring beans (which I'm doing using @Resource tags) The only sticking point is setting up all of the fake 'request'

struts

2008-11-06 Thread Seshagiri V
Hi All, I am working web application. I used auto testing with web test (canoo) .but also used jQuery. I want to writ test cases with jQuery.Please give me how write test cases with jQuery. Thank you, Seshagiri V [EMAIL PROTECTED] US Main: 877 KENSIUM (536.7486) US Fax:

RE: Unit Testing Advice

2008-11-06 Thread Gundersen, Richard
This is what I have so far. It works but I would appreciate a little peer review (particularly regarding how I set up my session and the logged in user) Thanks! @Resource private CardPaymentAction cardPaymentAction; ActionContext

Re: Unit Testing Advice

2008-11-06 Thread Nils-Helge Garli Hegvik
The complexity of the test setup often reflects how much of the framework itself you involve in your tests. Usually, I try to avoid mocking the context and http objects by implementing the *Aware interfaces and simply injecting simple Map objects, testing the action in isolation. I realize that

Re: struts

2008-11-06 Thread Dave Newton
--- On Thu, 11/6/08, Seshagiri V wrote: I am working web application. I used auto testing with web test (canoo) .but also used jQuery. I want to writ test cases with jQuery.Please give me how write test cases with jQuery. Do you mean you want to unit test your JavaScript code? There are

Re: struts

2008-11-06 Thread Nils-Helge Garli Hegvik
Google is your friend: http://www.google.com/search?q=jquery+unit+test http://www.google.com/search?q=javascript+unit+test Nils-H On Thu, Nov 6, 2008 at 1:28 PM, Seshagiri V [EMAIL PROTECTED] wrote: Hi All, I am working web application. I used auto testing with web test (canoo) .but also

RE: Unit Testing Advice

2008-11-06 Thread Gundersen, Richard
Thanks Nils-H I see what you mean. My action actually is implementing ServletRequestAware, so I just tried what you suggested and I can see how that's a bit neater actually. I'll adopt your approach. Thanks for the tip Richard Gundersen Java Developer Email: [EMAIL PROTECTED] Phone:

upgrading Eclipse problem with tiles

2008-11-06 Thread Gianluca Musella
Mmm... I've update my Eclipse to Web Tools Platform 3.4 to use with TPTP 4.5 (the profiler) and my tiles.xml doen's work anymore. 22 errors: The content of element type definition must match (icon?,display-name?,description?,put*,putList*) Any ideas? Thancs Gianluca

Re: upgrading Eclipse problem with tiles

2008-11-06 Thread Antonio
2008/11/6 Gianluca Musella [EMAIL PROTECTED]: Mmm... I've update my Eclipse to Web Tools Platform 3.4 to use with TPTP 4.5 (the profiler) and my tiles.xml doen's work anymore. 22 errors: The content of element type definition must match (icon?,display-name?,description?,put*,putList*) This

Problem with Ajax and s:text (i18n)

2008-11-06 Thread Shuk
Hi, I'm trying to add some Ajax functionality to my Struts2 project but unfortunately encountered a quite annoying problem with the lt;s:textgt; tag. For better understanding, here is the relevant code I'm using: Ajax div on main page: lt;s:div id=userInfo theme=ajax href=/Refresh.action

Re: Problem with Ajax and s:text (i18n)

2008-11-06 Thread Dave Newton
What happens if you call the action directly? Does the action in question extend ActionSupport at some point? Dave --- On Thu, 11/6/08, Shuk wrote: I'm trying to add some Ajax functionality to my Struts2 project but unfortunately encountered a quite annoying problem with the lt;s:textgt;

RE: Unit Testing Advice

2008-11-06 Thread Gundersen, Richard
Hi I just have one smallish question: for some reason my messages.properties isn't being loaded. It's configured in struts.xml constant name=struts.custom.i18n.resources value=messages / ...and I know that file is generally working because all the other Struts stuff is working. I'm getting this

How to Distinguish buttons in a JSP under Tabbed Pane

2008-11-06 Thread Sudheendra.N.Singh
Hi, I have a tabbed pane under which I display some JSP that has 2 buttons save and back. I use notifyTopics to notify the tabbed pane. I want to implement the back functionality but dont know how to distinguish if Back button was clicked (or Save button) as control alwasy come to execute().

Programming help for a print function

2008-11-06 Thread Guojun Zhu
Hi, I am new to struts and using Struts 1.2.9 (old version, but not my decision). I have a view page in jsp set up to display a report I generated on-fly. I have use setRequestAtrribute() to put report ( plain text string with only \n line-break) as a attribute in the action and get it from

RE: Programming help for a print function

2008-11-06 Thread Gundersen, Richard
I've just done the same thing - although it's nothing to do with Struts var a = window.open('','','width=500,height=400'); a.document.open(text/html); a.document.write(document.getElementById('receipt').innerHTML); a.document.close(); a.print(); a.close();

Re: Problem with Ajax and s:text (i18n) [SOLVED]

2008-11-06 Thread Shuk
Hi Dave, Thanks for your reply, you actually helped me to solve the problem! I feel like an idiot though... The problem was not the code itself but the fact that my action class was in a different package as my package.properties file. As a result, the latter could not be read by my action

RE: Problem with Ajax and s:text (i18n)

2008-11-06 Thread Martin Gainty
Shuk- your scoping can be modified to override the default scope interceptor e.g. scope=application another way would be to insert interceptor name=scope class=org.apache.struts2.interceptor.ScopeInterceptor/ on your Basic Stack and override the applicable params.. HTH Martin

Re: Programming help for a print function

2008-11-06 Thread Alberto Flores
Are you aware that you can control what is printed with CSS (media=print)?. This is a good trick (depending on what you are trying to do). Only food for thought! Guojun Zhu wrote: Hi, I am new to struts and using Struts 1.2.9 (old version, but not my decision). I have a view page in jsp

RE: Problem with Ajax and s:text (i18n)

2008-11-06 Thread Shuk
Hi Martin, I solved it by simply modifying my package structure. Basically I just added one main package that contains all other packages. This allows me to put the package.properties in the main package so that it can be accessed by all classes in sub-packages. I added a small example below.

RE: struts2 file (how to define files of type)

2008-11-06 Thread Sangeetha Rajagopal
Hi Nicole, I am also facing same issue, Have you solved the problem. ? Let me know. Thanks, SAngeetha Rajagopal Nicole Luneburg wrote: oh bummer that sucks :( I just read that comment from the link you sent me: Current browsers generally ignore the ACCEPT attribute. Grrr Thanks

Struts2 portlets

2008-11-06 Thread Pierre Goupil
Hello all, I'm currently evaluating Struts2 Vs. Wicket as a Web framework in a portlet environment. I'm using eXo WebOS as a portal. My question is : what's the status of portlet support in Struts2 ? I don't really care about portlet 1.0 or 2.0 but I'm looking for a fairly robust and easy-to-go

Re: Programming help for a print function

2008-11-06 Thread Guojun Zhu
Thank you very much. That works for me. I changed the media type to text/plain and forward what is in the textarea directly and it works fine in IE and firefox. (some format problems in Opera though, need to check safari later). Have a great day! sincerely Zhu, Guojun On Thu, Nov 6, 2008 at

[OT] Re: How to open a file with struts

2008-11-06 Thread Dave Newton
--- On Thu, 11/6/08, Ariel wrote: I want to open a file from an action Servlet to use it in the web aplication, this file is located in the site root but I donĀ“t know how to referenced, when I open the file I do this: File file = new File(MyFile.txt) But an Exception is thrown because the

[s2.0.12]Client validation not working

2008-11-06 Thread esemba
I've a problem with struts client validation. When i try to attach javascript validation to my simple form, it seems, that struts doesn't include necessary files js files. validate=true attribute generates this line of html code: script type=text/javascript

What are Pros and Cons for Struts 2?

2008-11-06 Thread ryan webb
Can anyone share to me some of the things you like about Struts 2 as well some of the things you don't like about struts 2? Thanks!

Re: What are Pros and Cons for Struts 2?

2008-11-06 Thread Mead Lai
don't like the theme. On Fri, Nov 7, 2008 at 11:48 AM, ryan webb [EMAIL PROTECTED] wrote: Can anyone share to me some of the things you like about Struts 2 as well some of the things you don't like about struts 2? Thanks! -- BestRegards, Mead http://yayisoft.com J. Paul Getty - The

Re: What are Pros and Cons for Struts 2?

2008-11-06 Thread ryan webb
a oks.. thanks for the reply =) On Fri, Nov 7, 2008 at 2:03 PM, Mead Lai [EMAIL PROTECTED] wrote: don't like the theme. On Fri, Nov 7, 2008 at 11:48 AM, ryan webb [EMAIL PROTECTED] wrote: Can anyone share to me some of the things you like about Struts 2 as well some of the things you

Re: What are Pros and Cons for Struts 2?

2008-11-06 Thread Wes Wannemacher
Pros - Easy integration with just about anything - Spring Freemarker JS Frameworks like JQuery, YUI Sitemesh Tiles Very easy to write actions Easy to understand workflow Ability to configure with almost 0 XML Good abstraction away from Servlet/JSP

Re: Struts2 portlets

2008-11-06 Thread Nils-Helge Garli Hegvik
I can't give you an unbiased answer, but I can tell you that there has been significant efforts making the portlet framework behave as similar to regular web application with Struts 2 as possible, and yet expose the more advanced portlet concepts in a sensible manner. So basically, if you like