Index: openacs-4/packages/dotlrn/www/dotlrn-master.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/dotlrn-master.tcl,v diff -u -N -r1.49 -r1.49.2.1 --- openacs-4/packages/dotlrn/www/dotlrn-master.tcl 11 Jul 2018 20:45:30 -0000 1.49 +++ openacs-4/packages/dotlrn/www/dotlrn-master.tcl 27 Sep 2019 13:02:23 -0000 1.49.2.1 @@ -14,36 +14,39 @@ # details. # # -# /www/dotlrn-master.tcl -# -# This is the "default-master" template for dotlrn sites. -# -# Instructions: -# -# 1. Put this file and it's .adp file into the server's /www directory. -# That's the one with the "default-master" Tcl and adp files. You don't -# have to edit or remove the "default-master" files, since they will be -# ignored by the next step. -# -# 2. Change the "Main Site"'s "DefaultMaster" parameter -# from "/www/default-master" to "/www/dotlrn-master" -# at http://yoursite.com/admin/site-map -# -# This tells OpenACS to use these files instead of the "default-master" -# -# 3. Edit these files to change the look of the site including the banner -# at the top of the page, the title of the pages, the fonts of the portlets, etc. -# -# WARNING: All current portlet themes (table, deco, nada, etc) depend on some -# of the CSS defined below. Be careful when you edit the CSS below, -# and check how themes use it. -# -# -# Author: Arjun Sanyal (arjun@openforce.net), yon@openforce.net -# -# $Id$ -set user_id [ad_conn user_id] +ad_page_contract { + /www/dotlrn-master.tcl + + This is the "default-master" template for dotlrn sites. + + Instructions: + + 1. Put this file and it's .adp file into the server's /www directory. + That's the one with the "default-master" Tcl and adp files. You don't + have to edit or remove the "default-master" files, since they will be + ignored by the next step. + + 2. Change the "Main Site"'s "DefaultMaster" parameter + from "/www/default-master" to "/www/dotlrn-master" + at http://yoursite.com/admin/site-map + + This tells OpenACS to use these files instead of the "default-master" + + 3. Edit these files to change the look of the site including the banner + at the top of the page, the title of the pages, the fonts of the portlets, etc. + + WARNING: All current portlet themes (table, deco, nada, etc) depend on some + of the CSS defined below. Be careful when you edit the CSS below, + and check how themes use it. + + + Author: Arjun Sanyal (arjun@openforce.net), yon@openforce.net + + $Id$ +} + +set user_id [ad_conn user_id] set community_id [dotlrn_community::get_community_id] set dotlrn_url [dotlrn::get_url] @@ -62,7 +65,7 @@ set header_font_size "medium" set header_font_color "black" set header_logo_item_id "" -set header_img_url "/resources/dotlrn/logo" +set header_img_url "/resources/dotlrn/logo" set header_img_file "[acs_root_dir]/packages/dotlrn/www/resources/logo" set header_img_alt_text "Header Logo" @@ -82,9 +85,9 @@ set show_navbar_p 1 if {[info exists no_navbar_p] && $no_navbar_p} { set show_navbar_p 0 -} +} -if { $community_id eq "" && +if { $community_id eq "" && [parameter::get \ -parameter hide_personal_portal_p \ -package_id [dotlrn::get_package_id] \ @@ -109,19 +112,19 @@ } if { [ad_conn package_key] ne [dotlrn::package_key] } { - # Peter M: We are in a package (an application) that may or may not be under a dotlrn instance + # Peter M: We are in a package (an application) that may or may not be under a dotlrn instance # (i.e. in a news instance of a class) # and we want all links in the navbar to be active so the user can return easily to the class homepage # or to the My Space page set link_all 1 } if {$have_comm_id_p} { - # in a community or just under one in a mounted package like /calendar + # in a community or just under one in a mounted package like /calendar # get this comm's info set control_panel_text "Administer" - set text [dotlrn_community::get_community_header_name $community_id] + set text [dotlrn_community::get_community_header_name $community_id] set link [dotlrn_community::get_community_url $community_id] set admin_p [dotlrn::user_can_admin_community_p -user_id $user_id -community_id $community_id] @@ -140,7 +143,7 @@ # in a community type set text \ [dotlrn_community::get_community_type_name [dotlrn_community::get_community_type]] - + if {$show_navbar_p} { set make_navbar_p 1 } else { @@ -183,7 +186,7 @@ set control_panel_text [_ "dotlrn.control_panel"] if {$community_id ne ""} { - # in a community or just under one in a mounted package like /calendar + # in a community or just under one in a mounted package like /calendar set comm_type [dotlrn_community::get_community_type_from_community_id $community_id] set control_panel_text [_ acs-subsite.Admin] @@ -216,7 +219,7 @@ set scope_z_light "#ECF3F0" } } - + # DRB: default logo for dotlrn is a JPEG provided by Collaboraid. This can # be replaced by custom gifs if preferred (as is done by SloanSpace) @@ -225,7 +228,7 @@ } elseif { [file exists "$header_img_file-$scope_name.gif"] } { set header_img_url "$header_img_url-$scope_name.gif" } - + # set header_img_url "$header_img_url-$scope_name.gif" # font hack @@ -249,7 +252,7 @@ -attribute_name header_font_color ] - # logo hack + # logo hack set header_logo_item_id [dotlrn_community::get_attribute \ -community_id $community_id \ -attribute_name header_logo_item_id @@ -260,16 +263,16 @@ set item_id [content::revision::item_id -revision_id $header_logo_item_id] set header_img_url "[subsite::get_url]image/$item_id" } - - + + set header_logo_alt_text [dotlrn_community::get_attribute \ -community_id $community_id \ -attribute_name header_logo_alt_text ] if {$header_logo_alt_text ne ""} { set header_img_alt_text $header_logo_alt_text - } + } set text [dotlrn::user_context_bar -community_id $community_id] @@ -302,7 +305,7 @@ } else { set link_control_panel 0 } - set extra_spaces "" + set extra_spaces "" set navbar [dotlrn::portal_navbar \ -user_id $user_id \ -link_control_panel $link_control_panel \ @@ -473,7 +476,7 @@ color: #${color3}; border-top: 1px solid #${color3}; border-bottom: 1px solid #${color3}; - } + } .portlet ul ul li { color: #${color3}; @@ -542,7 +545,7 @@ set recolor_css "" } } - + template::head::add_style -style " $recolor_css