aspose file tools*
The moose likes Websphere and the fly likes Struts with WSAD 5.0???????? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Products » Websphere
Bookmark "Struts with WSAD 5.0????????" Watch "Struts with WSAD 5.0????????" New topic
Author

Struts with WSAD 5.0????????

Thirumaran Somasundaram
Greenhorn

Joined: Oct 29, 2002
Posts: 8
Does anyone have any idea about this topic....if so, please get back to me in detail approach.....i would appreciate that.....
JeanLouis Marechaux
Ranch Hand

Joined: Nov 12, 2001
Posts: 906
Struts works fine with WSAD 4, just like any other jar utilities.
I can't see any reason why it could be different with version 5


/ JeanLouis<br /><i>"software development has been, is, and will remain fundamentally hard" (Grady Booch)</i><br /> <br />Take a look at <a href="http://www.epfwiki.net/wikis/openup/" target="_blank" rel="nofollow">Agile OpenUP</a> in the Eclipse community
Mark Sowiak
Greenhorn

Joined: Nov 01, 2002
Posts: 1
I was able to run my Struts apps fine within WSAD 5.0 as long as I used the WebSphere 4.0 test environment. But they stopped working as a result of migrating to J2EE 1.3 and to the WebSphere 5.0 Test Environment!!! I'm getting a "VerifyError" when the Struts Action gets executed.... via other forums.. sounds like it is a XML parser issue... maybe. Still need help.....
Dave Holtz
Greenhorn

Joined: Jan 12, 2003
Posts: 4
I have experienced similar problems as well. One of the most annoying things i've discovered in WSAD is the example apps. I've been trying to come up to speed with Tiles and thought it would be logical to start with the Tiles documentation example app. Once I had the app installed into the IDE and running I thought I would take a look at some of the config files. My experience was that if you modify any of those files (even just typing a space) and save, the xml files are no longer valid. I'm wondering if it's WSAD or the fact that the projects in question are based on the beta2 of Struts 1.1.
Kyle Brown
author
Ranch Hand

Joined: Aug 10, 2001
Posts: 3892
    
    5
OK, rather than give you a detailed reponse -- let's start with some basics -- the detailed response will be best handled by an article that's coming out later this month in WSDD about the WSAD 5.0 struts support.
The major thing to keep in mind is that Struts is now built in. When you create a Web Project you can (and should) enable it to use struts -- in fact there's a drop-down that allows you to select struts 1.1b2 or struts 1.02. Unless you do so, we give no guarantees about your code working.
Kyle


Kyle Brown, Author of Persistence in the Enterprise and Enterprise Java Programming with IBM Websphere, 2nd Edition
See my homepage at http://www.kyle-brown.com/ for other WebSphere information.
Dave Holtz
Greenhorn

Joined: Jan 12, 2003
Posts: 4
Are you saying it's not necessary to include the following line in the struts-config.xml file since WSAD has built in support for it?
plug-in className="org.apache.struts.tiles.TilesPlugin" >
<set-property property="definitions-config" >
value="/WEB-INF/tiles-defs.xml
/plug-in
[ January 17, 2003: Message edited by: Dave Holtz ]
Kyle Brown
author
Ranch Hand

Joined: Aug 10, 2001
Posts: 3892
    
    5
No, but I am telling you that the Web Application wizard will insert the line for you automatically when you enable struts and tell it to include Tiles.
Kyle
Dave Holtz
Greenhorn

Joined: Jan 12, 2003
Posts: 4
I apologize for beating a dead moose here, but I'm not seeing anywhere in the version of WSAD that I am using:
(Version: 5.0.0
Build id: 20021125_2118)
anything about enabling Tiles.
If I do the following
--> File -->New -->Project
--> Choose Web from the left side of the New Project Dialog, and Web Project on the Right, and click next
-->Give the Project Name, select J2EE Web Project, and check Add Struts Support in the Web Project Features section
-->Give the Project Name and J2EE level info
-->I have attempted not 'overriding the default settings', as well as overriding the default settings and choosing 1.1b2
Now, if I examine the struts-config.xml file, I see now reference to the Tiles config stuff that I had mentioned in my previous post.
Can you please educate me?
Thanks
Kyle Brown
author
Ranch Hand

Joined: Aug 10, 2001
Posts: 3892
    
    5
Hmmmmm... you're right. I managed to get it to automatically insert the tiles TLD file, and to reference it correctly in a JSP page without having to type it in, but the plugin registration doesn't seem automatic -- this seems like a bug -- I'll look into it.
Kyle
Jan van Doorn
Greenhorn

Joined: Feb 12, 2003
Posts: 21
Kyle mentioned the article a few posts earlier... here it is...
http://www7b.software.ibm.com/wsdd/techjournal/0302_fung/fung.html
... and it works !
Kyle Brown
author
Ranch Hand

Joined: Aug 10, 2001
Posts: 3892
    
    5
Yes, but after it went to press I realized I had forgotten to ask them to cover another cool feature. In the diagram, pick an existing ActionForm. Pop up the context menu and add a JSP from there. In the wizard it will ask you if it want to "populate" the JSP (or something like that -- I'm working from memory). If you say yes, your JSP will come with a Struts FORM tag pre-filled in with appropriate Struts HTML tags for each of the fields in the ActionForm... Major shortcut.
Kyle
 
Don't get me started about those stupid light bulbs.
 
subject: Struts with WSAD 5.0????????