From: Sam Waller Date: 2006-12-20T23:55:07+09:00 Subject: apache2 + eruby problem I can get Apache2 on Ubuntu Edgy to execute ruby (.rb) files. But I'm having trouble getting it to recognize .rhtml files. Here is the sites-available file. /etc/apache2/sites-available/www.site.local: ServerAdmin webmaster@site.local ServerName www.site.local ServerAlias site.local AddHandler cgi-script .rb AddType application/x-httpd-eruby .rhtml DirectoryIndex index.php DocumentRoot /var/www/site ScriptAlias /cgi-bin/ /var/www/site/ Options +ExecCGI ErrorLog /var/www/site/logs/error.log CustomLog /var/www/site/logs/access.log combined I installed eruby and have /usr/sbin/eruby in my path. I'm trying to get a ruby hit counter embedded in html format files, so I think that I'd need eruby to do that. If I try opening test.rhtml the browser wants to open it as text or download it. Here is test.rhtml: eruby test

eruby test

<% print "hello world" %>

Can someone explain how to get .rhtml files working with Apache2? thanks, Sam