[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ic] File Manager


On Mon, 17 Oct 2005, maillists wrote:

I am working on building a "file manager" within Interchange for
non-admin users.  I am stuck trying to set up a way to "delete" files.
I have a simple tag that I can't seem to make work, and I get nothing in
the error log.

Here is the tag:

-------------------------------
UserTag delete-file Routine <<EOR
sub {

my ($row) = @_;
my $file = $row->{deletefile};
unlink($file);

}
EOR
-----------------------------

I call it with a form link setting the value of deletefile to the whole
path of the file that I want to delete.

i.e. [value deletefile] returns:
/var/www/www.website.com/catalog/pathtofiles/filename.dia

and on a success page I just call the tag like so:

[deletefile]

It looks to me like you're calling the deletefile usertag, but you defined the delete-file usertag. One has a hyphen, the other doesn't. You don't get anything in the error log because delete-file was never called.

Jon

--
Jon Jensen
End Point Corporation
http://www.endpoint.com/
_______________________________________________
interchange-users mailing list
suppressed
http://www.icdevgroup.org/mailman/listinfo/interchange-users


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.