How do I use Erubis?

J

Jonathan Denni

I have been using eruby for embedded ruby in html, and I am moving to a
new server and am interested in using erubis instead - how do I do that?
Do I just install the rubygem and my .rhtml files should work the same
way as with eruby?
 
B

Brian Candler

Jonathan said:
I have been using eruby for embedded ruby in html, and I am moving to a
new server and am interested in using erubis instead - how do I do that?

To paraphrase: you are asking "how to I get my webserver to use erubis
instead of erb"?

This question can't be answered without knowing what webserver you're
using.

If you show how you've got your current webserver set up to use eruby,
then it may be clear how to change it to use erubis.

If you're using Apache with mod_ruby, the erubis documentation explains
how to do it here:
http://www.kuwata-lab.com/erubis/users-guide.06.html#topcs-modruby
Do I just install the rubygem and my .rhtml files should work the same
way as with eruby?

Well, why not just try it. If it fails then you can show a specific
problem:

"I have been using eruby successfully with config X. I changed this to
config Y to try to use erubis, but then I got error message Z" - showing
all of X, Y and Z.

Having narrowed down your problem like this, and provided all the
context, it makes it much easier for someone to help you.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,770
Messages
2,569,584
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top