Re: Content encoding in AJAX responses and Safari
Ricardo, Have you tried to set the encoding at the application constructor? public Application() { /* The following line solved my encoding problems: */ setDefaultEncoding(UTF-8); /* There is also this method that was suggested: */ ERXMessageEncoding.setDefaultEncodingForAllLanguages(UTF-8); } Cheers, Bueno On Feb 1, 2008 1:31 AM, Ricardo Parada [EMAIL PROTECTED] wrote: Hi All, I'm still testing my ajax stuff and I ran into this problem. My main component has the following inside the head.../head tags: meta http-equiv=Content-type content=text/html; charset=utf-8 I also have eclipse preferences General Workspace Text file encoding set to UTF-8. My Main.woo is as follows: { WebObjects Release = WebObjects 5.0; encoding = NSUTF8StringEncoding; } Then my application object overrides createRequest() to tell the request as soon as possible that our form values are encoded in UTF8 : public WORequest createRequest() { WORequest request = super.createRequest(...); request.setDefaultFormValueEncoding(UTF8); return request; } The application appendToResponse also does UTF8 for the content encoding before generating the response: public void appendToResponse(WOResponse response, WOContext context) { response.setContentEncoding(UTF8); super.appendToResponse(response, context); } I can type in accentuated characters into the html file and the page displays in the browser fine. Also, in the text fields inside a form, I can type in these characters, submit by clicking the submit button and the application receives the characters and redisplays the page. Everything displays correctly. The problem comes in when I submit the values using AJAX. Again the application receives the characters correctly. I check by printing the values to the console. Then the application generates an ajax response. I make sure to response.setContentEncoding(UTF8) for my ajax response. The response contains html. It's just an html fragment so it doesn't have a meta ... tag in there. On firefox the response displays correctly. However, on Safari my ñ character turns into ñ Then my é character turns into Ã(c) Any ideas why my ajax response doesn't display correctly in Safari? Any ideas what I may be missing? Thanks, Ricardo ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/bueno.dev%40gmail.com This email sent to [EMAIL PROTECTED] -- - Oswaldo V. C. Bueno - http://bueno.carpintaria.com Carpintaria do Software - http://www.carpintaria.com ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
FetchSpecification failed because the qualifier variable '$xxxxx' is unbound.
Hi, I'm getting the following error: sqlStringForKeyValueQualifier: attempt to generate SQL for com.webobjects.eocontrol.EOKeyValueQualifier (modLevel = $) failed because the qualifier variable '$' is unbound. But this fetchspecification have the Require all variable bindings checkbox disabled. Shouldn't WO ignore qualifiers with unbound variables? That is what I remember happening with WO 5.2. I'm using: WO 5.4 WOLips 3.3.4777 Wonder Cheers, Bueno -- - Oswaldo V. C. Bueno - http://bueno.carpintaria.com Carpintaria do Software - http://www.carpintaria.com ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: WOLips: 80 character width gutter?
Gaastra, I agree with everyone else that a 80 char limit is really annoying. But if you want to show gutter, in eclipse go to: Eclipse Preferences General Editors Text Editors Show Print Margin Or in the search box of preference, type margin. You can also use the code formatter with this limit. Cheers, Bueno On Jan 21, 2008 8:31 PM, Gaastra Dennis - WO Lists [EMAIL PROTECTED] wrote: Dear List, How does one show a vertical line toward the right side of a java editor - indicating 80 character width. In XCode, one could select show gutter at 80 characters. Poll: How many WO developers still enforce 80 character width for their java code? With Kind Regards, Dennis Gaastra, M.B.A.[sfu.ca], B.Sc.[ubc.ca] Chief Technology Officer, WEBAPPZ Systems, Inc. ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/bueno.dev%40gmail.com This email sent to [EMAIL PROTECTED] -- - Oswaldo V. C. Bueno - http://bueno.carpintaria.com Carpintaria do Software - http://www.carpintaria.com ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: [JavaEOGenerator] Bug when generating fetchSpecification methods
Hi Art, Thanks for your reply. Non visible attribute - An attribute(database column) included in the eomodel, but not marked as a class property. I have already tested EOEntity._propertyForPath(), and it returns null for attributes not marked as class property. Cheers, Bueno On Dec 20, 2007 7:54 PM, Art Isbell [EMAIL PROTECTED] wrote: On Dec 20, 2007, at 11:43 AM, Oswaldo Bueno wrote: I'm using JavaEOGenerator http://developer.apple.com/samplecode/JavaEOGenerator to auto-generate my entity classes. When it generates methods to access EOFetchSpecifications on the eomodeld, it suppresses bindings associated with a non-visible attribute. What's a non-visible attribute? Do you mean a database column that's not modeled in your eomodel? If so, why not include it in your eomodel but don't make it a class property? That would prevent EOF from including it in any SQL it generates. But I don't know whether EOEntity._propertyForPath() would also ignore it. It would be quick and easy to test. Aloha, Art ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/bueno.dev%40gmail.com This email sent to [EMAIL PROTECTED] ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
[JavaEOGenerator] Bug when generating fetchSpecification methods
Hi, I'm using JavaEOGenerator http://developer.apple.com/samplecode/JavaEOGenerator to auto-generate my entity classes. When it generates methods to access EOFetchSpecifications on the eomodeld, it suppresses bindings associated with a non-visible attribute. Trying to debug I identified the following line of com.webobjects.entitygenerator.EOFetchSpecificationProxy:69 EOProperty bindingAttribute = entity()._propertyForPath(qualifier.keyPathForBindingKey(bindingName)); The method _propertyForPath() returns null when the binding is associated with a non-visible attribute. Any one knows how can I fix it? I'm using WO 5.4 and Eclipse/WOLips Thanks, Bueno ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
WO 5.4 new parser (inline bindings) removing DOCTYPE and XML declaration
Hi, I'm staring a new project on WO 5.4 and decided to use the new inline bindings. I have a component with the following first lines: ?xml version=1.0 encoding=UTF-8? !DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.1//EN http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd; html xmlns=http://www.w3.org/1999/xhtml; xml:lang=en When WO parses and renders this component, it only outputs: html The new inline bindings parser also converts p/p to p/ automaticaly, resulting on a poorly rendered page on a web browser if it doesn't find the doctype instruction. It only happens when using the new inline bindings, if I use the old style on .wo file, the old parser doesn't screws the html. How can I output DOCTYPE and XML instructions with the new parser? Should I give up on WO5.4 inline bindings and start using Wonder's WOOGNL? Thanks, Bueno ___ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]