Then compare system output with Ruby's output - if they have no
differences - the problem is somewhere in your code. In that case please
post your code to www.pastebin.com and give a link there.
I checked both of the code you guys suggested and it worked fine.
However there is still a problem.
I am developing an application for a ruby class I am in, and I would
like to edit some of that .erb file in an HTML textarea. I am using
Ruby/Sinatra, and here is what happens:
If I print the data into a <div>, it will show everything including the
doctype, body, etc.
Yet when I do this:
<textarea cols="93" rows="32" name="contents">
<% File.open("views/layoutAdmin.erb") do |file| %>
<% file.each_line do |line| %>
<%= line %>
<% end %>
<% end %>
</textarea>
The textarea will take away all of the aforementioned tags. Like I said
before, if I replace the <textarea> tags with <div> tags, it works fine,
but I of course can't edit that content.
Is there some reason why textareas do not display this data?
Thanks again for the comment, it led me to test some stuff out and found
it was TinyMCE javascript plugin that was removing the header and such.
I tried testing if that was the case earlier but a refresh of the page
didn't refresh the code, I had to actually reload the page for it to
reset.