Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4146652

java.net.URLEncoder.java needs to support more forms of encode method

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Duplicate
    • Icon: P5 P5
    • None
    • 1.2.0
    • core-libs
    • generic
    • generic

      Currently in both JDK1.1.x and JDK1.2, URLEncoder only has one method URLEncode.encode(String data) which encodes the data by using default charater encoding type set by system property "file.encoding". However there are cases a browser needs to handle more than one encoding types at same time, so supporting more forms of encode method is necessary.

      Request to add encode(String data, String charEncType) method.

      [above by original submitter]

      Note that this supports the convention that's been pushed by Netscape:

       http://people.netscape.com/ftang/paper/unicode11paper/t005.html

      as well as the more recent (March 1998) approach presented at the IETF:

       ftp://ietf.org/internet-drafts/draft-masinter-url-i18n-01.txt

      Both require encoding into bytes, then URL-encoding.

      NOTE that whatever solution is adopted should be mirrored in the
      new java.net.URLDecoder class too.
       
      david.brownell@Eng 1998-07-06

            mupadhyasunw Mayank Upadhyay (Inactive)
            mmma Marvin Ma (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: