Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

I have one Shopping cart application, i that i have
selected some items, while clicking submit button by
mistake i have clicked twice or trice, that time items are
selected twice or trice. Actually i want only one copy of
items but its selected twice or trice. So how can we avoid
this problem?

Answer Posted / veera

If this question in core (jave Collection): if you are
using list,it will take the duplicate values. so pass
through this list into set it will remove the duplicate
values.

if this question in J2EE servlets: use post method, it it
is not idempotent. once you add item to cart, it will give
the acknowledge before changing in server.

Is This Answer Correct ?    12 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is byte data type?

999


Why do we use bufferedreader?

1002


Which variables are stored in heap?

1027


This abstract class is correct ? abstract class A { public abstract void Disp(); public abstract void B() { } public absract virtual C() { } }

987


What are streams?

1121


What is implicit object in java?

1075


Why are the methods of the math class static?

1075


What does the “final” keyword mean in front of a variable? A method? A class?

994


Can you override a final method?

1034


What are the default and parameterized constructors?

1055


Is java still relevant?

977


Is singleton class thread safe?

996


What is the difference between keyword and identifier?

1023


Why chararray() is preferred over string to store the password?

1026


How to reverse string in java?

1202