Index: openacs-4/packages/xowiki/tcl/form-field-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/form-field-procs.tcl,v diff -u -r1.284.2.226 -r1.284.2.227 --- openacs-4/packages/xowiki/tcl/form-field-procs.tcl 19 Oct 2022 18:29:39 -0000 1.284.2.226 +++ openacs-4/packages/xowiki/tcl/form-field-procs.tcl 24 Oct 2022 09:00:42 -0000 1.284.2.227 @@ -4586,8 +4586,18 @@ if {$with_pie_charts} { if {![info exists ::__xotcl_highcharts_pie]} { - template::add_body_script -src "//code.highcharts.com/highcharts.js" - security::csp::require script-src code.highcharts.com + if {[template::head::can_resolve_urn urn:ad:js:highcharts]} { + # + # The highcharts package is available + # + template::add_body_script -src urn:ad:js:highcharts + } else { + # + # The highcharts package is not available, go straight to the CDN. + # + template::add_body_script -src "//code.highcharts.com/highcharts.js" + security::csp::require script-src code.highcharts.com + } } set graphID pie-[incr ::__xotcl_highcharts_pie] }