On Sat, December 6, 2003 1:17 Mark J. Reed wrote:
>
> On Sat, Dec 06, 2003 at 07:05:08AM +0900, Jesper Olsen wrote:
>> From a mod_ruby cgi_script I try to use
>>
>> Dir.mkdir("mydir")
>>
>> to create a new directory via a web application.
>
>> For some reason this fails
>
> How is it failing?  What is the error being reported or exception
> being thrown?  Is it possible that you're trying
> to create the directory underneath a directory that doesn't exist?
> As long as the argument is untainted, Dir.mkdir should be allowed at
> $SAFE == 1.
>
> -Mark
>
>
Ahm...I forgot that the cgi process did not have my usual file permissions.

That's the problem with ruby cgi scripts - they give you no feedback when
they fail.

The python cgi module has a very useful "debug" mode, which can tell you
exactly where your script fails. Of course you only enable this while
developing - you don't want the script to be viewable otherwise.
I don't think there is anything like that for ruby?

Cheers
Jesper


--
http://JesperOlsen.Net