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

Plugin PARAM tag NAME attribute should not use local char regional settings

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P4
    • 1.3.1_08
    • 1.3.0, 1.3.1_04
    • deploy
    • 08
    • x86
    • windows_nt

    Description



      Name: gm110360 Date: 08/09/2002


      FULL PRODUCT VERSION :
      java version "1.3.1_04"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_04-b02)
      Java HotSpot(TM) Client VM (build 1.3.1_04-b02, mixed mode)

      Java(TM) Plug-in: Version 1.3.1_04
      Using JRE version 1.3.1_04 Java HotSpot(TM) Client VM

      FULL OPERATING SYSTEM VERSION :
      Windows NT Version 4.0
      SP6a

      EXTRA RELEVANT SYSTEM CONFIGURATION :
        Bug can be reproduced on IE 5.01 SP2 & 5.5 SP2

      A DESCRIPTION OF THE PROBLEM :
      Under the Windows operating system, setting regional
      setting to Turkish and running the test applet & html
      provided works incorrectly.

      In the previous plugin version, 1.3.0, it used to work.

      The thing is, it looks like the plugin does a
      String.lowerCase() on the parameter names and this causes
      the Turkish character 'I' to translate to lower Turkish
      equivalent rather than 'i' because of the VM regional
      settings.

      Is it possible to have i18n names in the parameter names?
      If so, then this works correctly as expected but then
      Applet.getParameter works incorrectly.


      REGRESSION. Last worked in version 1.3

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      1. Set Windows regional setting to Turkish
      2. Compile test applet
      3. Run the test applet with the test HTML
      4. View that the parameter for "pIncome" is not display
      5. Change the parameter name to "pincome"
      6. Run again to view the expected result

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      Expected: The parameter value to display in the applet
      screen.

      Actual: The parameter will not have any value to display
      from within the applet because it was null, as if not there!

      ERROR MESSAGES/STACK TRACES THAT OCCUR :
      No error messages, just that the parameter has NULL value as if it did not
      exist in the parameters.

      REPRODUCIBILITY :
      This bug can be reproduced always.

      ---------- BEGIN SOURCE ----------
      TestAppletTR.java
      //------------------------------------------------------
      import javax.swing.*;

      public class TestAppletTR extends JApplet
      {
      public void init()
      {
      System.out.println("got into test applet...");

      getContentPane().setLayout(null);
      setSize(483,374);

      DataPanel.setLayout(null);
      DataPanel.setBorder(new javax.swing.border.BevelBorder
      (javax.swing.border.BevelBorder.RAISED));
      DataPanel.setBounds(0,0,414,304);
      getContentPane().add(DataPanel);
      UserKodText.setBounds(8,8,96,20);
      DataPanel.add(UserKodText);

      UserKodText.setText(getParameter("pIncome"));
      } // init

      protected javax.swing.JPanel DataPanel = new javax.swing.JPanel();
      protected javax.swing.JTextField UserKodText = new
      javax.swing.JTextField();

      } // TestAppletTR

      //---------------------------------------------------
      //--------------------------------------------------
      //------------------------------------------------------


      TestAppletTR.html
      //--------------------------------------------------
      <html>
      <head>
      <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-9">
      </head>
      <body>
      <p><b>TEST TR CHARS: ??????I - ??i????</b></p>
      <br>
      <OBJECT name="TestAppletObj" WIDTH="300" HEIGHT="100" classid="clsid:8AD9C840-
      044E-11D1-B3E9-00805F499D93" codebase="j2re-1_3_1_04-win-i.exe#Version=1,3,1,4">
      <PARAM NAME="code" VALUE="TestAppletTR"/>
      <PARAM NAME="type" VALUE="application/x-java-applet;version=1.3.1"/>
      <PARAM NAME="mayscript" VALUE="true"/>
      <PARAM NAME="scriptable" VALUE="true"/>

      <PARAM NAME="pIncome" VALUE="123456"/>
      <!--
      <PARAM NAME="pincome" VALUE="123456"/>
      -->
      <p>
      <font face='Arial, Helvetica, sans-serif' size="2" color='#ff0000'>
      <b><i>*** STOP! ***</i><br>Your current browser does not have Java Plug-
      in installed.</b>
      </font>
      </p>
      </OBJECT>
      </body>
      </html>

      //-------------------------------------------------
      ---------- END SOURCE ----------

      CUSTOMER WORKAROUND :
      Use lower case for 'I' as:

      <PARAM NAME="pincome" VALUE="123456"/>
      (Review ID: 160409)
      ======================================================================

      I tried the above test case on Windows NT Japanese edition by the
      same reproducible process.

      That can be reproduced.

      When the parameter name is "pIncome", the parameter, "123456" does
      not show up in the textfield.
      When "pincome", the value shows up.

      Configration:

       - OS: WindowsNT4.0(SP5, Japanese Edition)
             Windows2000(SP2, Japanese Edition)
       - Browser: IE 5.5(SP2)
       - Locale : Turkish


      Note:
       - This issue does not happens in 1.4.1_b21.

      2002-09-09
      ================================================================================

      Attachments

        Activity

          People

            poonam Poonam Bajaj Parhar
            gmanwanisunw Girish Manwani (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: