code: public static String urlFormEncode(final String s)
          {
          if (StringUtils.isBlank(s))
              {
              LOG.warn("Could not encode blank string");
              throw new IllegalArgumentException("Blank string");
              }
          try
              {
              return URLEncoder.encode(s, "UTF-8");
              }
          catch (final UnsupportedEncodingException e)
              {
              LOG.error ("Could not encode: " + s, e);            
              return s;
              }
          }
docs: Returns a string that has been encoded for use in a URL.
  
  @param s The string to encode.
  
  @return The given string encoded for use in a URL.