Index: openacs-4/packages/acs-api-browser/tcl/acs-api-documentation-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-api-browser/tcl/acs-api-documentation-procs.tcl,v diff -u -r1.27.8.9 -r1.27.8.10 --- openacs-4/packages/acs-api-browser/tcl/acs-api-documentation-procs.tcl 2 Oct 2013 08:56:25 -0000 1.27.8.9 +++ openacs-4/packages/acs-api-browser/tcl/acs-api-documentation-procs.tcl 16 Oct 2013 20:08:07 -0000 1.27.8.10 @@ -41,11 +41,11 @@ # line begins with the string "ad_page_contract". set has_contract_p 0 - if { ![file exists "[acs_root_dir]/$path"] } { + if { ![file exists "$::acs::rootdir/$path"] } { return -code error "File $path does not exist" } - set file [open "[acs_root_dir]/$path" "r"] + set file [open "$::acs::rootdir/$path" "r"] while { [gets $file line] >= 0 } { # Eliminate any comment characters. regsub -all {#.*$} $line "" line @@ -62,7 +62,7 @@ } doc_set_page_documentation_mode 1 - set errno [catch { source "[acs_root_dir]/$path" } error] + set errno [catch { source "$::acs::rootdir/$path" } error] doc_set_page_documentation_mode 0 if { $errno == 1 } { global errorInfo @@ -270,7 +270,7 @@ || [util_url_valid_p $see]} { return "$see" } - if {[file exists "[get_server_root]${see}"]} { + if {[file exists "$::acs::rootdir${see}"]} { return "$see" } return ${see} @@ -522,7 +522,9 @@ append out "[util_wrap_list $command_line]\n
\n" if { $script_p } { - append out "Defined in $doc_elements(script)

" + append out [subst {Defined in + $doc_elements(script) +

}] } if { $doc_elements(deprecated_p) } { @@ -625,44 +627,49 @@ -package_key acs-api-browser \ -parameter FancySourceFormattingP \ -default 1]} { - append out "

Source code:
+ append out [subst {
Source code:
[api_tcl_to_html $proc_name]
-

\n" +

+}] } else { - append out "

Source code:
+ append out [subst {
Source code:
[ns_quotehtml [api_get_body $proc_name]]
-

\n" +

+}] } } - set xql_base_name [get_server_root]/ + set xql_base_name $::acs::rootdir/ append xql_base_name [file rootname $doc_elements(script)] if { $xql_p } { set there {} set missing {} if { [file exists ${xql_base_name}.xql] } { - append there "

Generic XQL file:
+ append there [subst {
Generic XQL file:
[api_quote_file ${xql_base_name}.xql]
-

\n" +

+}] } else { lappend missing Generic } if { [file exists ${xql_base_name}-postgresql.xql] } { - append there "

Postgresql XQL file:
+ append there [subst {
Postgresql XQL file:
[api_quote_file ${xql_base_name}-postgresql.xql]
-

\n" +

+}] } else { lappend missing PostgreSQL } if { [file exists ${xql_base_name}-oracle.xql] } { - append there "

Oracle XQL file:
+ append there [subst {
Oracle XQL file:
[api_quote_file ${xql_base_name}-oracle.xql]
-

\n" +

+}] } else { lappend missing Oracle } if {[llength $missing] > 0} { - append out "

XQL Not present:
[join $missing ", "]
" + append out [subst {
XQL Not present:
[join $missing ", "]
}] } append out $there } @@ -692,11 +699,16 @@ append out "$label" } array set doc_elements [nsv_get api_proc_doc $proc] + if {$doc_elements(deprecated_p)} { + set deprecated ", decprecated" + } else { + set deprecated "" + } if { $doc_elements(public_p) } { - append out " (public)" + append out " (public$deprecated)" } if { $doc_elements(private_p) } { - append out " (private)" + append out " (private$deprecated)" } return $out } @@ -763,9 +775,9 @@ } { set matches [list] foreach function [nsv_array names api_proc_doc] { - if {[string match -nocase *$string* $function]} { + if {[string match -nocase "*$string*" $function]} { array set doc_elements [nsv_get api_proc_doc $function] - lappend matches [list "$function" "$doc_elements(positionals)"] + lappend matches [list $function $doc_elements(positionals)] } } return $matches @@ -1197,13 +1209,13 @@ ad_proc -private api_xql_links_list { path } { Returns list of xql files related to tcl script file - @param path path and filename from [acs_root_dir] + @param path path and filename from $::acs::rootdir } { set linkList [list] - set filename "[acs_root_dir]/$path" + set filename "$::acs::rootdir/$path" set path_dirname [file dirname $path] set file_dirname [file dirname $filename] set file_rootname [file rootname [file tail $filename]] Index: openacs-4/packages/acs-api-browser/www/content-page-view.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-api-browser/www/content-page-view.tcl,v diff -u -r1.5.4.3 -r1.5.4.4 --- openacs-4/packages/acs-api-browser/www/content-page-view.tcl 14 Sep 2013 12:36:13 -0000 1.5.4.3 +++ openacs-4/packages/acs-api-browser/www/content-page-view.tcl 16 Oct 2013 20:08:07 -0000 1.5.4.4 @@ -2,7 +2,7 @@ Displays information about a content page. @param version_id the id of the package version the file belongs to - @param path the path and filename of the page to document, relative to [acs_root_dir] + @param path the path and filename of the page to document, relative to $::acs::rootdir @author Jon Salz (jsalz@mit.edu) @author Lars Pind (lars@pinds.com) @@ -52,7 +52,7 @@ lappend context [file tail $path] -set filename "[acs_root_dir]/$path" +set filename "$::acs::rootdir/$path" if {[regsub -all {[.][.]/} $filename "" shortened_filename]} { ns_log notice "INTRUDER ALERT:\n\nsomesone tried to snarf '$filename'!\n file exists: [file exists $filename]\n user_id: [ad_conn user_id]\n peer: [ad_conn peeraddr]\n" Index: openacs-4/packages/acs-api-browser/www/display-sql.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-api-browser/www/display-sql.tcl,v diff -u -r1.4.10.2 -r1.4.10.3 --- openacs-4/packages/acs-api-browser/www/display-sql.tcl 16 Sep 2013 20:38:39 -0000 1.4.10.2 +++ openacs-4/packages/acs-api-browser/www/display-sql.tcl 16 Oct 2013 20:08:07 -0000 1.4.10.3 @@ -29,7 +29,7 @@ } set context [list] -if {[exists_and_not_null version_id]} { +if {$version_id ne ""} { db_0or1row package_info_from_package_id { select pretty_name, package_key, version_name from apm_package_version_info @@ -55,7 +55,7 @@ return } -if {[exists_and_not_null package_key]} { +if { $package_key ne "" } { set safe_p [regexp {/?(.*)} $url package_url] } Index: openacs-4/packages/acs-api-browser/www/package-view.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-api-browser/www/package-view.adp,v diff -u -r1.6.22.2 -r1.6.22.3 --- openacs-4/packages/acs-api-browser/www/package-view.adp 14 Sep 2013 14:41:17 -0000 1.6.22.2 +++ openacs-4/packages/acs-api-browser/www/package-view.adp 16 Oct 2013 20:08:07 -0000 1.6.22.3 @@ -8,8 +8,8 @@
- - + + Index: openacs-4/packages/acs-api-browser/www/package-view.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-api-browser/www/package-view.tcl,v diff -u -r1.7.2.3 -r1.7.2.4 --- openacs-4/packages/acs-api-browser/www/package-view.tcl 15 Sep 2013 12:04:31 -0000 1.7.2.3 +++ openacs-4/packages/acs-api-browser/www/package-view.tcl 16 Oct 2013 20:08:07 -0000 1.7.2.4 @@ -137,8 +137,7 @@ for { set n_same_components 0 } \ { $n_same_components < [llength $last_components] } \ { incr n_same_components } { - if { ![string equal [lindex $last_components $n_same_components] \ - [lindex $components $n_same_components]] } { + if { [lindex $last_components $n_same_components] ne [lindex $components $n_same_components] } { break } } Index: openacs-4/packages/acs-api-browser/www/proc-search.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-api-browser/www/proc-search.tcl,v diff -u -r1.12 -r1.12.10.1 --- openacs-4/packages/acs-api-browser/www/proc-search.tcl 10 Jan 2007 21:22:01 -0000 1.12 +++ openacs-4/packages/acs-api-browser/www/proc-search.tcl 16 Oct 2013 20:08:07 -0000 1.12.10.1 @@ -144,7 +144,7 @@ set matches [lsort -command ad_sort_by_score_proc $matches] if {$quick_view && $matches ne "" || [llength $matches] == 1 } { - ad_returnredirect [api_proc_url [lindex [lindex $matches 0] 0]] + ad_returnredirect [api_proc_url [lindex $matches 0 0]] ad_script_abort } Index: openacs-4/packages/acs-api-browser/www/proc-view.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-api-browser/www/proc-view.tcl,v diff -u -r1.6.16.3 -r1.6.16.4 --- openacs-4/packages/acs-api-browser/www/proc-view.tcl 13 Sep 2013 13:01:03 -0000 1.6.16.3 +++ openacs-4/packages/acs-api-browser/www/proc-view.tcl 16 Oct 2013 20:08:08 -0000 1.6.16.4 @@ -19,7 +19,7 @@ set title $proc set context [list] -if { [exists_and_not_null version_id] } { +if { $version_id ne "" } { db_0or1row package_info_from_package_id { select pretty_name, package_key, version_name from apm_package_version_info
@procs_files.path@
@procs_files.path@       @procs_files.first_sentence@