ad_scope_admin_context_bar

one of the documented procedures in this installation of the ACS
Usage:
ad_scope_admin_context_bar   args
What it does:
if scope is not set in the topmost environment then public scope is assumed. if scope=group, it assumes that ug_admin_context_bar_list are set in the topmost environment. returns a Yahoo-style hierarchical contextbar for appropriate scope, starting with links to workspace and admin home. Suitable for use in pages underneath /admin.
Defined in: /web/philip/tcl/ad-scope.tcl

Source code:


    set choices [list "<a href=\"[ad_pvt_home]\">Your Workspace</a>" "<a href=\"/admin/\">Admin Home</a>"]
    set all_args [list]

    if { [uplevel [ad_scope_upvar_level] {info exists scope}] } {
	upvar [ad_scope_upvar_level] scope scope
    } else {
	set scope public
    }

    switch $scope {
	public {
	    set all_args $args
	}
	group {
	    upvar [ad_scope_upvar_level] group_vars_set group_vars_set
	    set group_context_bar_list [ns_set get $group_vars_set group_context_bar_list]
	    eval "lappend all_args $group_context_bar_list"
	    foreach arg $args {
		lappend all_args $arg
	    }
	}
	user {
	    # this may be later modified if we allow users to customize the display of their pages	    
	    set all_args $args
	}
    }

    set index 0
    foreach arg $all_args {
	incr index
	if { $index == [llength $all_args] } {
	    lappend choices $arg
	} else {
	    lappend choices "<a href=\"[lindex $arg 0]\">[lindex $arg 1]</a>"
	}
    }
    return [join $choices " : "]


philg@mit.edu