Gonzalo wrote the following on 09.09.2006 13:14 :
hello
I'm looking for something similar to the "echo" PHP function for ruby. in some situation I don't like to write code like this:
<% if condition %> <%= "<p>this is an example</p>" %> <% end %>
I prefer write this:
<% if condition echo "<p>this is an example</p>" end %>
<% if condition %> <p>this is an example</p> <% end %>
Does the same... You only have to use <%= %> for dynamic content.
But you can use concat IIRC:
<% if condition concat "<p>this is an example</p>" end %>
Then you can replace the static HTML above by dynamic content.
Lionel.