[Radiant] Haml and textareas in custom extension

Gert Jørgensen gert at gert.dk
Sun Jul 13 10:58:45 CDT 2008


Hi and first - thank you for making radiant, I've used many many cms'es
and this is by far the best I have used yet!

I have made a custom extension and created an admin area for the models
where I have a problem with a textarea. I have never used Haml so my
views are all html.erb files.

The problem is that the admin-area seems to parse my templates as haml
files and thus adds spaces after each line break in my textareas.

Example output (less-than and greater-than replaced with {}:

{textarea class="textarea" cols="40" id="collection_body"
name="collection[body]" rows="20">This is the best brand ever.

          Look how cool this text is.

          {a href="http://gert.dk"}gert.dk{/a}{/textarea}

Is there anyway to either use the find_and_preserve method in a html.erb
view or turn off haml-parsing for my custom part of the admin area?

Thanks in advance!
-- 
Posted via http://www.ruby-forum.com/.


More information about the Radiant mailing list