From: Phil Cooper-king Date: 2010-01-08T19:20:06+09:00 Subject: Re: Stopping String Escaping. > Hopefully it's clear from the above yes, thanks you. > So try your test case again: > (1) Use the DATA.read / __END__ to get the test source in > (2) Use 'puts' and not 'dump' to see clearly what you have [code] require 'rubygems' require 'redcloth' data_read = DATA.read string = "\\" puts RedCloth.new(string).to_html puts RedCloth.new(data_read).to_html __END__ \\ [/code] yeilds

\

\\

although I have no idea how to treat a string as a file. is all this to do with encoding? (sorry if that was a dense question) erb results are similar, which I would have though was be happening in rails anyway >> ERB.new("\\").src => "_erbout = ''; _erbout.concat \"\\\\\"; _erbout" -- Posted via http://www.ruby-forum.com/.