Index: openacs-4/www/blank-compat.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/www/blank-compat.tcl,v diff -u -r1.3 -r1.4 --- openacs-4/www/blank-compat.tcl 30 Aug 2007 07:23:04 -0000 1.3 +++ openacs-4/www/blank-compat.tcl 3 Dec 2007 20:29:30 -0000 1.4 @@ -32,15 +32,6 @@ } } -if { ![template::util::is_nil focus] } { - ns_log warning "blank-compat: property focus is deprecated in blank-master - focus should be handled in site-master." - - # Handle elements where the name contains a dot - if { [regexp {^([^.]*)\.(.*)$} $focus match form_name element_name] } { - lappend body(onload) "acs_Focus('${form_name}', '${element_name}');" - } -} - if {[exists_and_not_null body_attributes]} { foreach body_attribute $body_attributes { if {[lsearch { Index: openacs-4/www/blank-master.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/www/blank-master.tcl,v diff -u -r1.31 -r1.32 --- openacs-4/www/blank-master.tcl 3 Dec 2007 20:18:05 -0000 1.31 +++ openacs-4/www/blank-master.tcl 3 Dec 2007 20:29:30 -0000 1.32 @@ -170,6 +170,16 @@ unset body_scripts } +if {[info exists focus] && $focus ne ""} { + # Handle elements where the name contains a dot + if { [regexp {^([^.]*)\.(.*)$} $focus match form_name element_name] } { + template::head::add_body_handler \ + -event onload \ + -script "acs_Focus('${form_name}', '${element_name}');" + -identifier "focus" + } +} + # Concatenate the javascript event handlers for the body tag variable ::template::body_handlers if {[array exists body_handlers]} { Index: openacs-4/www/site-master.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/www/site-master.adp,v diff -u -r1.29 -r1.30 --- openacs-4/www/site-master.adp 15 Sep 2007 07:22:40 -0000 1.29 +++ openacs-4/www/site-master.adp 3 Dec 2007 20:29:30 -0000 1.30 @@ -2,5 +2,5 @@ doc body @head;noquote@ - +@focus;noquote@ \ No newline at end of file