Help with <<-EOF

Hi,

I have a piece of code like:
xmlData=<<-EOF
xml code
EOF

I need to change it into:
xmlData="
xml code
"

but I don’t know why… it doesn’t work when I change it into a normal
string.

Any idea?

On 11 May 2009, at 17:37, Mario R. wrote:

"

but I don’t know why… it doesn’t work when I change it into a normal
string.

Any idea?

Are you escaping all double quotes in the string?
Also, why do you need to make the change?

Ellie

Eleanor McHugh
Games With Brains
http://slides.games-with-brains.net

raise ArgumentError unless @reality.responds_to? :reason

Ok… I did it.
I think the problem was a special character at the beginning of the
string.
Thanks for your time.

Mario R. wrote:

There are no double quotes…

There are no double quotes…

I need to do it because is a requirement from the client :frowning:
(all string should be assigned by ")

Eleanor McHugh wrote:

On 11 May 2009, at 17:37, Mario R. wrote:

"

On 11 May 2009, at 18:19, Mario R. wrote:

There are no double quotes…

I need to do it because is a requirement from the client :frowning:
(all string should be assigned by ")

Well I guess there’s no accounting for clients lol

Ellie

Eleanor McHugh
Games With Brains
http://slides.games-with-brains.net

raise ArgumentError unless @reality.responds_to? :reason

On 11.05.2009 19:26, Eleanor McHugh wrote:

On 11 May 2009, at 18:19, Mario R. wrote:

There are no double quotes…

I need to do it because is a requirement from the client :frowning:
(all string should be assigned by ")

Well I guess there’s no accounting for clients lol

I’d be curios to hear the reason for this requirement.

Cheers

robert

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs