public static String urlEncode( String string )
    {
        return URLEncoder.encode( string, StandardCharsets.UTF_8);
    }
Translates a string into {@code application/x-www-form-urlencoded} format using a specific encoding scheme. This
method uses the UTF-8 encoding scheme to obtain the bytes for unsafe characters.

@param string the URL to encode
@return the encoded URL

@see URLEncoder
xmppserver/src/main/java/org/jivesoftware/admin/JSTLFunctions.java