subsite::upload_allowed (public)

 subsite::upload_allowed

Defined in packages/acs-subsite/tcl/subsite-procs.tcl

Verifies SolicitPortraitP parameter to ensure upload portrait security.

Author:
Hector Amado <hr_amado@galileo.edu>
Created:
2004-06-16

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/www/user/portrait/upload.tcl packages/acs-subsite/ www/user/portrait/upload.tcl subsite::upload_allowed subsite::upload_allowed packages/acs-subsite/www/user/portrait/upload.tcl->subsite::upload_allowed acs_user::site_wide_admin_p acs_user::site_wide_admin_p (public) subsite::upload_allowed->acs_user::site_wide_admin_p ad_conn ad_conn (public) subsite::upload_allowed->ad_conn ad_return_forbidden ad_return_forbidden (public) subsite::upload_allowed->ad_return_forbidden ad_script_abort ad_script_abort (public) subsite::upload_allowed->ad_script_abort parameter::get parameter::get (public) subsite::upload_allowed->parameter::get

Testcases:
No testcase defined.
Source code:

    set package_id [ad_conn subsite_id]

    if { ![parameter::get -package_id $package_id -parameter SolicitPortraitP -default 1]  } {
        if { ![acs_user::site_wide_admin_p] } {
            ns_log notice "user is tried to see user/portrait/upload without permission"
            ad_return_forbidden  "Permission Denied"  "<blockquote>You don't have permission to see this page.</blockquote>"
            ad_script_abort
        }
    }
XQL Not present:
Generic
PostgreSQL XQL file:
packages/acs-subsite/tcl/subsite-procs-postgresql.xql

Oracle XQL file:
packages/acs-subsite/tcl/subsite-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: