File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes Shopping cart JSP, ActionForm example Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of JavaScript Promises Essentials this week in the JavaScript forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Shopping cart JSP, ActionForm example" Watch "Shopping cart JSP, ActionForm example" New topic
Author

Shopping cart JSP, ActionForm example

Warren Bell
Greenhorn

Joined: Oct 03, 2005
Posts: 12
I am looking for an example of a shopping cart form where a user can change the qty ordered. This is a common feature, but I can not find any examples.

It would have one form with one submit button and several rows, each representing an item. Which strut tags would I use and how would the ActionForm look? It would be nice to get a List of line item objects where each object would represent an item with an id and a qty.

Thanks,


Warren
Junilu Lacar
Bartender

Joined: Feb 26, 2001
Posts: 4991
    
    8

This link looks promising:
http://www.oracle.com/technology/sample_code/tutorials/vsm1.3/files/over.pdf

BTW, there's a bunch of other possibles if you google for "struts shopping cart example". I would look for examples from Ted Husted and/or Matt Raible.


Junilu - [How to Ask Questions] [How to Answer Questions]
alan do
Ranch Hand

Joined: Apr 14, 2005
Posts: 354
you want to use indexed properties for this. if you understand how indexed properties works, you don't need example.


-/a<br />certified slacker...yes, my last name is 'do' - <a href="http://www.luckycouple.com" target="_blank" rel="nofollow">luckycouple.com</a>
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Shopping cart JSP, ActionForm example