ruby on rails - How to write "<%" in a erb file -


I have a .erb file, where I would like to return the following text:

The name & lt ;% R>

When I present this file, ARB interprets & lt;% as Ruby code and% does not render the signal.

I have a method like this, putting% signals in the string like this:

  name & lt; & Lt;% = "%"% & gt; R & gt;  

But this is very ugly.

I believe that you are looking for double percents

  & lt; %% R% & gt;  

It is used extensively using ARB templates to generate an ARB template.

Update

  & lt; %% R & gt;  

Comments

Popular posts from this blog

asp.net - Javascript/DOM Why is does my form not support submit()? -

sockets - Delphi: TTcpServer, connection reset when reading -

javascript - Classic ASP "ExecuteGlobal" statement acting differently on two servers -