what should I do if I want to run ruby on apache ( windows ) ?
I saw the online document it says need eruby
I downloaded and it seems not for windows
could anyone teach me ?
Thank you
what should I do if I want to run ruby on apache ( windows ) ?
I saw the online document it says need eruby
I downloaded and it seems not for windows
could anyone teach me ?
Thank you
what should I do if I want to run ruby on apache ( windows ) ?
I saw the online document it says need eruby
I downloaded and it seems not for windows
You don’t have to have eruby. Check out
http://www.rubycentral.com/book/lib_network.html#S3
You should be able to copy/paste the CGI example there to a file – change
the extension to .cgi, put it in the cgi-bin folder of your Apache
hierarchy – and a shebang line like:
#! c:/ruby/bin/ruby.exe
(of course, putting the path to your ruby.exe, and yes, use forward slashes
even on Windows, Apache will take care of interpreting it correctly)
as the first line in your file and you’re set.
I’ve not messed with any of the other Ruby web/cgi libs (mod_ruby, eruby,
etc…), so I can’t help you there.
Chris
http://clabs.org
what should I do if I want to run ruby on apache ( windows ) ?
I saw the online document it says need eruby
I downloaded and it seems not for windowsYou don’t have to have eruby. Check out
http://www.rubycentral.com/book/lib_network.html#S3You should be able to copy/paste the CGI example there to a file – change
the extension to .cgi, put it in the cgi-bin folder of your Apache
hierarchy – and a shebang line like:#! c:/ruby/bin/ruby.exe
(of course, putting the path to your ruby.exe, and yes, use forward slashes
even on Windows, Apache will take care of interpreting it correctly)as the first line in your file and you’re set.
I’ve not messed with any of the other Ruby web/cgi libs (mod_ruby, eruby,
etc…), so I can’t help you there.
Thanks : )
let me try later
You should be able to copy/paste the CGI example there to a file – change
the extension to .cgi, put it in the cgi-bin folder of your Apache
hierarchy – and a shebang line like:#! c:/ruby/bin/ruby.exe
(of course, putting the path to your ruby.exe, and yes, use forward slashes
even on Windows, Apache will take care of interpreting it correctly)as the first line in your file and you’re set.
BTW, Apache-on-Windows allows you to tell Apache (via some line in http.conf; read the in-file comments) to use the Windows registry
to determine where to find the ruby interpreter (i.e., based on file type association).
This is handy if, for example, you’re trying to develop cross-platform code and don’t want to have to keep changing the shebang
line.
James
BTW, Apache-on-Windows allows you to tell Apache (via some line in
http.conf; read the in-file comments) to use the Windows registry
to determine where to find the ruby interpreter (i.e., based on file type
association).
Cool, didn’t know that. Is that an addition to Apache 2? Or has that always
been there?
Chris
http://clabs.org
Cool, didn’t know that. Is that an addition to Apache 2? Or has that always
been there?
I’m running some version of 1.3 on Win2K. Don’t know when that feature came about.
James
Chris
http://clabs.org