Index: openacs-4/packages/acs-subsite/www/file.vuh =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/www/file.vuh,v diff -u --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ openacs-4/packages/acs-subsite/www/file.vuh 31 Aug 2006 15:41:48 -0000 1.1 @@ -0,0 +1,26 @@ +# packages/acs-subsite/www/image.vuh +# +# Subsite handler for images +# +# @author Dave Bauer (dave@thedesignexperience.org) +# @creation-date 2006-08-01 +# @cvs-id $Id: file.vuh,v 1.1 2006/08/31 15:41:48 daveb Exp $ + +if {![regexp {^/([0-9]{1,8})(/(.+))?$} [ad_conn path_info] match object_id dummy anchor]} { + ad_return_warning "Invalid object id" [subst { + The identifier given for this object is invalid. Please check your url + or contact the webmaster if you think it should work. + }] + return +} + +# check permissions! + +permission::require_permission \ + -privilege "read" \ + -object_id $object_id \ + -party_id [ad_conn user_id] + +# find a cr_item and serve it + +cr_write_content -item_id $object_id \ No newline at end of file