Forum .LRN Q&A: Student administration

Collapse
Posted by Vamshi Krishna Kaniganti on
hi
i am having a simple doubt, regarding the administration of a user, i have created a user and made him a student and given all  the privileges,
i have created a simple package with just only one page of html text just printing out the HELLO.
i had set the permissions to this package using the UI of site map, to the only users of the students, if i am not a student & typed the whole path in the browser accessing this page, i am redircting to a login page, where i shuld login as a user inorder to access the page.

i want to know how the OPENACS is redirecting the page to the login page internally.

also i ban the user it will say that the user has banned, here also one doubt how the user is redirecting it

i would be very grateful if anybody could be help me out, if there is any documentation regarding this will also help me out
thanks
vamshi

Collapse
2: Re: Student administration (response to 1)
Posted by Peter Marklund on
Vamshi,
looking at the code quickly here is how the redirection seems to work. On every request to an OpenACS server the proc rp_filter will run (see acs-tcl/tcl/request-processor-procs.tcl). In that proc

permission::require_permission -object_id [ad_conn object_id] read

will be invoked if we are in a user page and the same command with privilege admin is invoked if a page under package-uri/admin is requested.

The proc permission::require_permission will redirect the user to the login page if he doesn't have permission and isn't already logged in. If the user is logged in and doesn't have permission a permission denied page will be displayed instead.

Collapse
3: Re: Student administration (response to 2)
Posted by Vamshi Krishna Kaniganti on
hi peter
thanks for the reply,
i am working on dotlrn and created some students, and a another table,with the start date and end date, if want to block the students to access their pages after the expiration of the end date.
do i need to modify the user-login page which is under the acs-subsite/www/register/ in order to check the end date and doen't login them is this is the correct way of approach i want some guidance regarding this.

thank you
vamshi