vals.add(s);
vals.add(s.trim());
    private List getRepeatedParameter(HttpServletRequest request,        String param)    {        List vals = new LinkedList();        int i = 0;        boolean foundLast = false;        // Iterate through the values in the form.        while (!foundLast)        {            String s = request.getParameter(param + "_" + i);            // We're only going to add non-empty values            if (s != null)            {                vals.add(s);            }            else            {                // If the value was null (as opposed to present,                // but empty) we've reached the last name                foundLast = true;            }            i++;        }        return vals;    }