Hi there I''ve got following strange problem. Follwing code: send_data(originalString, :filename => "foo.bar", :type => ''text/plain; charset=utf-8'' ) I send the file "foo.bar" to the browser. If I save it, the charset isn''t utf-8, its "ansi" What must I change, when I want utf-8? Greets -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On 28 Mar 2008, at 16:57, Christoph Thommen wrote:> > Hi there > > I''ve got following strange problem. > Follwing code: > send_data(originalString, :filename => "foo.bar", :type => > ''text/plain; charset=utf-8'' ) > > > I send the file "foo.bar" to the browser. If I save it, the charset > isn''t utf-8, its "ansi" > > What must I change, when I want utf-8?Is the problem that the browser thinks it''s ansi or are the actual bytes going over the wire ''ansi'' ? Fred --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
I don''t know. But the problem appears with FF (OSX & Vista), Safari and IE7 any idea? -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On 28 Mar 2008, at 18:05, Christoph Thommen wrote:> > I don''t know. But the problem appears with FF (OSX & Vista), Safari > and > IE7 >My point was that the content_type you pass to send_data won''t change the data, so if what you''re pulling out of the database isn''t utf8 then the browsers won''t see utf8 either. Fred> any idea? > > -- > Posted via http://www.ruby-forum.com/. > > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Frederick Cheung wrote:> On 28 Mar 2008, at 18:05, Christoph Thommen wrote: > >> >> I don''t know. But the problem appears with FF (OSX & Vista), Safari >> and >> IE7 >> > My point was that the content_type you pass to send_data won''t change > the data, so if what you''re pulling out of the database isn''t utf8 > then the browsers won''t see utf8 either. > > FredI think I''ve to tell the hole story... i must generate a spezial datafile (encrypted xml) for a 3rd party application. the contend is utf-8,but the file itself not... I think it could be a problem with the header-informations? Any idea? Greets -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---