I’ve been using mod_ruby for months and now i have to write a script
that redirects my users to another location.
I use the following:
print “Location: http://www…com/index.html\r\n\r\n”
Well, this script doesn’t work for me. It just prints as plain text the
Location statement and no redirection is done.
Now, if i change the extension of the script from “.rb” to “.cgi” it
I did a telnet research to my server, and the .cgi returned a 302
status, but the “.rb” returned a 200 OK and two content-type statements,
as if the server is ignoring them or something.
What can i do?