As you probably know, to do a PHP script, you could just do..
<?php
Code..
?>
..and it would run the PHP code, as long as you have the PHP module loaded.
Is there a module that would allow you to do something similar with Ruby? Something like this would be nice:
<?ruby
Code..
?>
Ruby’s equivalent would be one of
Erb,ErubisorHAML.Erb comes with Ruby. Erubis is a compiled interpreter for Erb templates. They use
<%= ... >to mark where Ruby variables should be inserted. You can also include Ruby control structures easily using<%- ... >, to allow looping, creating of variables, etc.HAML is similar to those, but acts much like a HTML-shorthand. I prefer HAML for my own projects.