From: Daniel Lucraft Date: 2007-06-14T16:05:23+09:00 Subject: Re: Mail Using SMTP Problem Dhiraj Girdhar wrote: > > msgstr = < From: Your Name > > This is a test message. > END_OF_MESSAGE > > testmail.rb:16: can't find string "END_OF_MESSAGE" anywhere before EOF > testmail.rb:1: syntax error, unexpected $end, expecting tSTRING_CONTENT > or tSTRI > NG_DBEG or tSTRING_DVAR or tSTRING_END > Remove the spaces from in front of the second 'END_OF_MESSAGE'. The end of a heredoc string has to be right at the start of the line. Alternatively at the start of the heredoc do: msgstr = <<-END_OF_MESSAGE which allows the end of the heredoc to be indented. best, Dan -- Posted via http://www.ruby-forum.com/.