Question 1:
  I save some Chinese character code in database, and grab the code(foreign 
characters) from the database, the result is that most part of the Chinese code is OK, 
but all the codes behind the codes: "\u5200" and "\u4e00" are lost.
  The servlet server is JRUN, and the OS is win95, and some of my code is:
"
        ByteArrayOutputStream   bytes;
        PrintStream             out;
        bytes = new ByteArrayOutputStream (4096);
        out = new PrintStream (bytes);
        out.println ("<HTML><HEAD>");
        ...
        // fetch Chinese codes from database , and output to out.
        out.flush ();
        res.setContentType("text/html");
        res.setContentLength (bytes.size ());
        bytes.writeTo (res.getOutputStream ());
"

Question 2:
  I can not output Chinese character code to html. the code is:
"
    ServletOutputStream out = res.getOutputStream();
    res.setContentType("text/html");
    out.println ("<HTML><HEAD>");
    out.println ("<TITLE>Test servlet html page</TITLE>");
    ...
    out.println (here is some Chinese character codes);
    ...
    out.println ("</BODY></HTML>");
    out.close();
"
I will be glad to hear from you, and any help would be greatly appreciated.


__________________________________________________
欢迎使用首都在线免费电子邮箱http://freemail.263.net

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
  • ... Venkat R apsumarthi
  • ... Rajesh Thota
    • ... Julie Baldwin
  • ... Θεόδωρος Κυριμαλής
    • ... Danny Ayers
  • ... Gilad Tiram
  • ... akashmaheshwari
    • ... Daniel Montero
  • ... Beatriz Hernandez Espinosa
  • ... SUBSCRIBE SERVLET-INTEREST jack-wang
  • ... SUBSCRIBE SERVLET-INTEREST jack-wang
  • ... Daniel Liu
    • ... Danny Ayers
      • ... maurice munoz
        • ... S.Ramaswamy
  • ... Daniel Liu
    • ... James Duncan Davidson
  • ... #YANG YUE XIANG#
  • ... Beatriz Hernandez Espinosa
    • ... Chris Pratt
  • ... Alex P Deller

Reply via email to