• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: What a bunch of characters
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: What a bunch of characters


  • Subject: Re: What a bunch of characters
  • From: Miguel Arroz <email@hidden>
  • Date: Fri, 2 Nov 2007 15:48:11 +0000

Hi!

Maybe you have a problem with the encodings on the DB. I never used Oracle, but do you have to define the encoding when you create the DB? Did you do it for UTF-8? Oracle must have a way to tell you the current encoding of the DB, check that.

  Yours

Miguel Arroz

On 2007/11/02, at 15:05, Calven Eggert wrote:

The suggestion below worked for the display of the characters. "≤≥β√αγδ"

However, once I reloaded the record from the database the text now looks like this "de²±³´". This is also what it looks like directly in the database. Oracle

Do I need to do something with the data before/after sending/ receiving to/from the database?


On 2-Nov-07, at 10:44 AM, Miguel Arroz wrote:

Hi

I would recommend to change de meta http charset to UTF 8 and add this to your Application class:

public void appendToResponse(WOResponse response, WOContext context) {
super.appendToResponse(response, context);
if( _NSUtilities.UTF8StringEncoding.equals (response.contentEncoding()) && response.headerForKey("Content- Type").equals("text/html") )
response.setHeader("text/html; charset=UTF-8", "Content-Type");


    }

public WOResponse createResponseInContext( WOContext wocontext ) {
WOResponse woresponse = super.createResponseInContext (wocontext);
woresponse.setContentEncoding ( _NSUtilities.UTF8StringEncoding);
return woresponse;
}


public void takeValuesFromRequest(WORequest aRequest, WOContext aContext) {
aRequest.setDefaultFormValueEncoding ( _NSUtilities.UTF8StringEncoding );
super.takeValuesFromRequest(aRequest, aContext);
}


Unless you really want iso-8859-1, but I don't find any reason to do so.

  Yours

Miguel Arroz

On 2007/11/02, at 14:32, Calven Eggert wrote:

Ok, so I'm about to release a new version of a WO application and one of the testers says "Hey, when I type the following characters into a text box, they don't show up correctly after I save the record. "≤≥β√αγδ"

So I do the same on the Macintosh. I paste the characters and they look fine. I save the record, exit and reenter the page and behold, they show up as "???????" where on Windows they show up like this "&#8804&#8805&#946&#8730&#945&#947&#948".

What's a lonely WO programmer to do, after doing some google searches and searching the WO dev list and still hasn't a clue what to do? I do know that in the html this appears <META HTTP- EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">


Calven




_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40guiamac.com


This email sent to email@hidden

Miguel Arroz http://www.terminalapp.net http://www.ipragma.com






Calven





Miguel Arroz http://www.terminalapp.net http://www.ipragma.com



Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >What a bunch of characters (From: Calven Eggert <email@hidden>)
 >Re: What a bunch of characters (From: Miguel Arroz <email@hidden>)
 >Re: What a bunch of characters (From: Calven Eggert <email@hidden>)

  • Prev by Date: Re: WOLips question vis a vis Eclipse versions
  • Next by Date: Re: WOLips question vis a vis Eclipse versions
  • Previous by thread: Re: What a bunch of characters
  • Next by thread: Re: What a bunch of characters
  • Index(es):
    • Date
    • Thread