summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2009-07-01 17:47:10 +0000
committerRalph Amissah <ralph@amissah.com>2009-07-01 17:47:10 +0000
commit1f70e71190d6654b9b3487fff0574ae2956a0e9c (patch)
treea252f86cd1d64a3859f18571a0f34ea497820dd0
parentdb dbi, interfaces to sqlite and pgsql, fixes, pass individual sql statements (diff)
downloadsisu-1f70e71190d6654b9b3487fff0574ae2956a0e9c.zip
sisu-1f70e71190d6654b9b3487fff0574ae2956a0e9c.tar.xz
cgi generated sample search form, fix
-rw-r--r--lib/sisu/v0/cgi_pgsql.rb4
-rw-r--r--lib/sisu/v0/cgi_sqlite.rb4
2 files changed, 4 insertions, 4 deletions
diff --git a/lib/sisu/v0/cgi_pgsql.rb b/lib/sisu/v0/cgi_pgsql.rb
index 38da777..4f201df 100644
--- a/lib/sisu/v0/cgi_pgsql.rb
+++ b/lib/sisu/v0/cgi_pgsql.rb
@@ -22,7 +22,7 @@
This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
more details.
You should have received a copy of the GNU General Public License along with
@@ -136,7 +136,7 @@ module SiSU_CGI_pgsql
@hosturl_db="#{@env.url.webserv_base_cgi}"
@hosturl_files="#{@env.url.webserv_files_from_db}"
@port="#{@db.psql.port}"
- user='' # '#{@env.user}'
+ user='#{@env.user}' # check user name for access to pg database: '#{@env.user}'
WOK_SQL
end
def search_statement
diff --git a/lib/sisu/v0/cgi_sqlite.rb b/lib/sisu/v0/cgi_sqlite.rb
index 86d6987..34cb67d 100644
--- a/lib/sisu/v0/cgi_sqlite.rb
+++ b/lib/sisu/v0/cgi_sqlite.rb
@@ -22,7 +22,7 @@
This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
more details.
You should have received a copy of the GNU General Public License along with
@@ -93,7 +93,7 @@ module SiSU_CGI_sqlite
serve.each do |x|
f3 << %{ when /SiSU_#{x}/; "#{@env.path.webserv}/#{x}/sisu_sqlite.db"\n}
end
- f3 << "else #{@env.path.webserv}/#{serve[0]}/sisu_sqlite.db\n end\n"
+ f3 << %{ else '#{@env.path.webserv}/#{serve[0]}/sisu_sqlite.db'\n end\n}
if FileTest.writable?('.')
output=File.open('sisu_sqlite.cgi','w')
output << header0 << header1 << header_desc << header2 << f1 << buttons1 << buttons2 << search_request << search_statement << search_statement_common << search_query1 << @common.pages << search_query2 << @common.tail << @common.main1 << f2 << f3 << dbi_connect << @common.main2