How to compare a string ?
I have the following codes passed form a selection page(radiobutton). Value of first radio button is
'Stringent' while value of second radio button is 'Loose'.
<%
if(request.getParameter("match")!=null)
{
String matchopt = (String)request.getParameter("match");
if(matchopt=="Stringent")
{
out.println("Stringent Match");
}
else
{
out.println("Loose Match");
}
}
else
{
out.println("No option selected");
}
%>
--
The result is I always get the answer of Loose Match either I select Stringent Match or Loose Match
radio button. I have tried to print out the value pass over and it is correct.
Anyone know how to compare the string?

