Index: openacs-4/packages/acs-tcl/tcl/tcl-documentation-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/tcl-documentation-procs.tcl,v diff -u -r1.30.2.19 -r1.30.2.20 --- openacs-4/packages/acs-tcl/tcl/tcl-documentation-procs.tcl 24 Jun 2015 09:23:10 -0000 1.30.2.19 +++ openacs-4/packages/acs-tcl/tcl/tcl-documentation-procs.tcl 2 Jul 2015 19:16:02 -0000 1.30.2.20 @@ -1138,7 +1138,7 @@ foreach elm [ad_complaints_get_list] { template::multirow append complaints $elm } - ns_return 200 text/html [ad_parse_template -params [list complaints] "/packages/acs-tcl/lib/complain"] + ns_return 422 text/html [ad_parse_template -params [list complaints] "/packages/acs-tcl/lib/complain"] ad_script_abort } } @@ -2006,7 +2006,7 @@ @creation-date 24 June 2015 } { - if {[regexp {^[\w,-]+$} $value]} { + if {[regexp {^[\w,:-]+$} $value]} { return 1 } ad_complain [_ acs-tcl.lt_name_contains_invalid] Index: openacs-4/packages/acs-templating/tcl/parse-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-templating/tcl/parse-procs.tcl,v diff -u -r1.48.2.10 -r1.48.2.11 --- openacs-4/packages/acs-templating/tcl/parse-procs.tcl 9 Sep 2014 08:32:01 -0000 1.48.2.10 +++ openacs-4/packages/acs-templating/tcl/parse-procs.tcl 2 Jul 2015 19:12:57 -0000 1.48.2.11 @@ -518,6 +518,8 @@ # the parse list now contains the code set code [join $parse_list "\n"] + #ns_log notice "CODE before i18n\n$code\n" + # Substitute #foo# message keys with values from the message catalog # Since messages may read the variables of the adp page they go trough @@ -532,6 +534,7 @@ # substitute array variable references while {[regsub -all [template::adp_array_variable_regexp_noquote] $code {\1[lang::util::localize $\2(\3)]} code]} {} + while {[regsub -all [template::adp_array_variable_regexp_noi18n] $code {\1$[ns_quotehtml \2(\3)]} code]} {} while {[regsub -all [template::adp_array_variable_regexp_literal] $code {\1$\2(\3)} code]} {} # # Some aolservers have broken implementations of ns_quotehtml @@ -549,6 +552,7 @@ # substitute simple variable references while {[regsub -all [template::adp_variable_regexp_noquote] $code {\1[lang::util::localize ${\2}]} code]} {} + while {[regsub -all [template::adp_variable_regexp_noi18n] $code {\1[ns_quotehtml ${\2}]} code]} {} while {[regsub -all [template::adp_variable_regexp_literal] $code {\1${\2}} code]} {} if {[ns_quotehtml ""] eq ""} { while {[regsub -all [template::adp_variable_regexp] $code {\1[ns_quotehtml [lang::util::localize ${\2}]]} code]} {} @@ -592,6 +596,15 @@ return {(^|[^\\])@([a-zA-Z0-9_:]+)\.([a-zA-Z0-9_:\.]+);literal@} } +ad_proc -public template::adp_array_variable_regexp_noi18n {} { + adp_array_variable_regexp's pattern augmented by "literal" + + @author Gustaf Neumann + @creation-date June 2015 +} { + return {(^|[^\\])@([a-zA-Z0-9_:]+)\.([a-zA-Z0-9_:\.]+);noi18n@} +} + ad_proc -public template::adp_variable_regexp {} { The regexp pattern used to find adp variables in a piece of text, i.e. occurenceis of @variable_name@. @@ -622,6 +635,15 @@ return {(^|[^\\])@([a-zA-Z0-9_:]+);literal@} } +ad_proc -public template::adp_variable_regexp_noi18n {} { + adp_variable_regexp augmented by "literal" + + @author Gustaf Neumann + @creation-date June 2015 +} { + return {(^|[^\\])@([a-zA-Z0-9_:]+);noi18n@} +} + # Naviserver requires for disambiguation of flags and values at the # end of the argument processing a terminating "--" (like for other # commands). AOLserver does not allow the "--".