Index: openacs-4/contrib/packages/bcms/tcl/bcms-widget-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/contrib/packages/bcms/tcl/bcms-widget-procs.tcl,v diff -u -r1.9 -r1.10 --- openacs-4/contrib/packages/bcms/tcl/bcms-widget-procs.tcl 13 Nov 2003 15:12:38 -0000 1.9 +++ openacs-4/contrib/packages/bcms/tcl/bcms-widget-procs.tcl 9 Feb 2004 14:51:27 -0000 1.10 @@ -144,16 +144,19 @@ ad_proc -public bcms::widget::item_context { {-item_id:required} {-root_id} + {-root_url ""} } { creates a list based the folder it resides that can be used as context or trail. @param item_id id of which item to get a context @param root_id start from which id - + @param root_url @returns a list in {{url label} {url label}} format } { - set root_url [ad_conn package_url] + if {[empty_string_p $root_url]} { + set root_url [ad_conn package_url] + } if {![info exists root_id]} { set root_id [bcms::folder::get_bcms_root_folder] } @@ -167,6 +170,7 @@ ad_proc -public bcms::widget::category_context { {-category_id:required} {-root_id} + {-root_url ""} } { creates a list category listing from the root_id to the category_id @@ -175,7 +179,9 @@ @returns a list in {{url label} {url label}} format } { - + if {[empty_string_p $root_url]} { + set root_url [ad_conn package_url] + } if {![info exists root_id]} { # if the root_id does not exists then start from the root array set root [bcms::category::get_root -category_id $category_id]