Henry, I captured the traces. The file 'goodone.txt' is the one that was sent by the proxied version, and the file 'badone.txt' is the one sent by the solo version. What is happening is that the proxied version used UTF-8 encoding while the solo version used 8859_1 encoding. When we run the solo version, the entire application is a swf file that is loaded by the tag <object>. It appears that we need to instruct the <object> tag to pass on the encoding (UTF-8) to the swf file. We tried a few possibilities, but none of them work.
Thanks! Chen Ding On Thu, Dec 24, 2009 at 1:58 PM, Henry Minsky <[email protected]>wrote: > Please send me the HTTP headers and content if you can get it from Firefox > using Firebug or HTTPFox > > > On Thu, Dec 24, 2009 at 12:13 AM, Chen Ding <[email protected]>wrote: > >> Henry, >> >> Both use POST, but the messages are different. I am trying to figure out >> the differences. >> >> Chen Ding >> >> >> On Thu, Dec 24, 2009 at 12:42 PM, Henry Minsky <[email protected] >> > wrote: >> >>> Sorry I meant to say that proxied mode always uses a POST request, >>> whereas SOLO mode >>> can make a GET or a POST request, depending on how you set the querytype >>> attribute of the dataset. >>> >>> 2009/12/23 hminsky <[email protected]> >>> >>> Can you use a tool like HTTPFox or Firebug to see what the headers are >>>> when the data is posted to the server? One difference is that SOLO mode >>>> always uses a POST request, whereas SOLO can use a GET request. Might be a >>>> different handling by your server of those cases? >>>> >>>> On Wed, Dec 23, 2009 at 11:36 PM, Chen Ding <[email protected]>wrote: >>>> >>>>> Henry, >>>>> >>>>> The problem is on the client side. In the website, there is an edittext >>>>> field that collects data (Chinese characters) that are sent to the server. >>>>> In the non-deployed version, the data received by the server are correct. >>>>> In >>>>> the deployed version, however, the data received by the server are >>>>> incorrect. >>>>> >>>>> Thanks! >>>>> >>>>> Chen Ding >>>>> >>>>> >>>>> On Thu, Dec 24, 2009 at 12:24 PM, Henry Minsky < >>>>> [email protected]> wrote: >>>>> >>>>>> Is the issue with encoding of character data in datasets that you are >>>>>> fetching? >>>>>> >>>>>> >>>>>> The issue may be not in the client, but at the server end. The LPS >>>>>> server not only proxies data requests, but does character set encoding >>>>>> conversion for you as well when it parses the XML. Are you sure that the >>>>>> data you are requesting is coming in UTF-8 format from your back-end data >>>>>> source? >>>>>> >>>>>> Flash's XML parser in the Flash player has a very limited repertoire >>>>>> of character set encodings >>>>>> that it can deal with, so it is best to always send UTF-8 data from >>>>>> your server. >>>>>> >>>>>> >>>>>> On Wed, Dec 23, 2009 at 9:46 PM, Chen Ding <[email protected]>wrote: >>>>>> >>>>>>> Hi There, >>>>>>> >>>>>>> Merry Christmas! >>>>>>> >>>>>>> We have a website that works ok. But when we deploy it as solo, it >>>>>>> does not support Chinese anymore. We are using the HTML wrapper as below >>>>>>> (generated by OpenLaszlo's facility). As I said above, if we run the lzx >>>>>>> directly (i.e., USTC.lzx), it works just fine. Is there something we >>>>>>> need to >>>>>>> specify when convert it to the solo deployment? >>>>>>> >>>>>>> Thanks! >>>>>>> >>>>>>> Chen Ding >>>>>>> >>>>>>> >>>>>>> 1 <!DOCTYPE html >>>>>>> 2 PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" " >>>>>>> http://www.w3.org/TR/html4/loose.dtd"> >>>>>>> 3 <html> >>>>>>> 4 <head> >>>>>>> 5 <meta http-equiv="Content-Type" content="text/html; >>>>>>> charset=utf-8"> >>>>>>> 6 <link rel="SHORTCUT ICON" href=" >>>>>>> http://www.laszlosystems.com/favicon.ico"> >>>>>>> 7 <title>Zykie Application</title> >>>>>>> 8 <style type="text/css"> >>>>>>> 9 html, body { margin: 0; padding: 0; height: >>>>>>> 100%; } >>>>>>> 10 body { background-color: #eaeaea; } >>>>>>> 11 </style> >>>>>>> 12 </head> >>>>>>> 13 >>>>>>> 14 <body> >>>>>>> 15 <object type="application/x-shockwave-flash" >>>>>>> 16 data=" >>>>>>> http://192.168.99.99:8080/lps-4.6.1/prod/Homepages/USTC.lzx.swf8.swf?lzproxied=false >>>>>>> " >>>>>>> 17 width="100%" height="1500"> >>>>>>> 18 <param name="movie" >>>>>>> 19 value=" >>>>>>> http://192.168.99.99/lps-4.6.1/prod/Homepages/USTC.lzx.swf8.swf?lzproxied=false >>>>>>> "/> >>>>>>> 20 <param name="quality" value="high"/> >>>>>>> 21 <param name="scale" value="noscale"/> >>>>>>> 22 <param name="salign" value="LT"/> >>>>>>> 23 <param name="menu" value="false"/> >>>>>>> 24 <param name="allowFullScreen" value="true"/> >>>>>>> 25 </object> >>>>>>> 26 </body> >>>>>>> 27 </html> >>>>>>> >>>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> Henry Minsky >>>>>> Software Architect >>>>>> [email protected] >>>>>> >>>>>> >>>>>> >>>>> >>>> >>>> >>>> -- >>>> Henry Minsky >>>> Software Architect >>>> [email protected] >>>> >>>> >>>> >>> >>> >>> -- >>> Henry Minsky >>> Software Architect >>> [email protected] >>> >>> >>> >> > > > -- > Henry Minsky > Software Architect > [email protected] > > >
Bad One ====== Host 192.168.99.99:8080 User-Agent Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-CN; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5 Accept text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language zh-cn,zh;q=0.5 Accept-Encoding gzip,deflate Accept-Charset GB2312,utf-8;q=0.7,*;q=0.7 Keep-Alive 300 Connection keep-alive Cookie JSESSIONID=F879FAD9D72B1EABAF6FFC1F1674FCBC Referer: http://192.168.99.99:8080/lps-4.6.1/prod/Homepages/USTC.lzx.swf8.swf?lzproxied=false Content-type: application/x-www-form-urlencoded Content-length: 451 trans%5Fid=16&operation=serverCmd&username=dingchen&command=%3Coperation%20container%3D%22objtable%5Fa000003HN%22%20evpd%3D%22vpd%5Fsmseditor%22%20vvpd%3D%22vpd%5Fsmseditor%22%20ctnid%3D%22objtable%22%20opr%3D%22createcobj%22%2F%3E&objdef=%3Cembedobj%20zky%5Fsms%3D%22%E4%B8%81%E9%99%88%22%20%5F%5Fname%3D%22%E4%B8%81%E9%99%88%22%20container%3D%22objtable%5Fa000001PD%22%20password%3D%22ustc796%22%20username%3D%22dingchen%22%20opr%3D%22login%22%2F%3E The one that contains the Chinese is: embedobj%20zky%5Fsms%3D%22%E4%B8%81%E9%99%88%22%20%5F The data should be: "embedobj zky_sms="%E4%B8%81%E9%99%88"
Good One Host 192.168.99.99:8080 User-Agent Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-CN; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5 Accept text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language zh-cn,zh;q=0.5 Accept-Encoding gzip,deflate Accept-Charset GB2312,utf-8;q=0.7,*;q=0.7 Keep-Alive 300 Connection keep-alive Cookie JSESSIONID=F879FAD9D72B1EABAF6FFC1F1674FCBC Referer: http://192.168.99.99:8080/lps-4.6.1/prod/Homepages/USTC.lzx?lzt=swf Content-type: application/x-www-form-urlencoded Content-length: 878 lzr=swf8&lzpostbody=trans%5Fid%3D16%26operation%3DserverCmd%26username%3Ddingchen%26command%3D%253Coperation%2520container%253D%2522objtable%255Fa000003HN%2522%2520evpd%253D%2522vpd%255Fsmseditor%2522%2520vvpd%253D%2522vpd%255Fsmseditor%2522%2520ctnid%253D%2522objtable%2522%2520opr%253D%2522createcobj%2522%252F%253E%26objdef%3D%253Cembedobj%2520zky%255Fsms%253D%2522%25E4%25B8%2581%25E9%2599%2588%2522%2520%255F%255Fname%253D%2522%25E4%25B8%2581%25E9%2599%2588%2522%2520container%253D%2522objtable%255Fa000001PD%2522%2520password%253D%2522ustc796%2522%2520username%253D%2522dingchen%2522%2520opr%253D%2522login%2522%252F%253E&url=http%3A%2F%2F192%2E168%2E99%2E99%3A8080%2Flps%2D4%2E6%2E1%2Fprod%2Fjsp%2Fserver%5Fproxy%2Ejsp&lzt=xmldata&reqtype=POST&sendheaders=false&trimwhitespace=false&nsprefix=false&timeout=30000&cache=undefined&ccache=false&%5F%5Flzbc%5F%5F=1261636324120
