Index: openacs-4/packages/acs-core-docs/www/sql/display-sql.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/sql/display-sql.tcl,v diff -u -r1.5 -r1.6 --- openacs-4/packages/acs-core-docs/www/sql/display-sql.tcl 10 Jan 2007 21:22:03 -0000 1.5 +++ openacs-4/packages/acs-core-docs/www/sql/display-sql.tcl 27 Oct 2014 16:39:30 -0000 1.6 @@ -31,11 +31,11 @@ # for example if { [string match "*..*" $url] || [string match "*..*" $package_key] } { - ad_return_error "Can't back up beyond the pageroot" "You can't use display-sql.tcl to look at files underneath the pageroot." + ad_return_warning "Can't back up beyond the pageroot" "You can't use display-sql.tcl to look at files underneath the pageroot." ad_script_abort } -if {[exists_and_not_null package_key]} { +if {$package_key ne ""} { set safe_p [regexp {/?(.*)} $url package_url] } @@ -48,7 +48,7 @@ set files [glob -nocomplain "[acs_package_root_dir $package_key]/sql/*/$url" "[acs_package_root_dir $package_key]/sql/$url"] foreach f $files { regexp {([^/]*)/([^/]*)$} $f match db url - append text "
  • $db
  • " + append text "
  • $db
  • " } if {$files eq ""} { append text "
  • No sql file found." @@ -70,7 +70,7 @@ if { $safe_p && [llength $files] > 0 } { ns_returnfile 200 text/plain $files } else { - ad_return_error "Invalid file location" "Can only display files in package or doc directory." + ad_return_warning "Invalid file location" "Can only display files in package or doc directory." } ad_script_abort }