Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: CGI and DBI

by hmerrill (Friar)
on Nov 29, 2004 at 12:29 UTC ( [id://410905] : note . print w/replies, xml ) Need Help??

in reply to CGI and DBI

Forget about connecting to the database for the moment, and first make sure that you can get your cgi script to run in the browser. Try something like this first:
#!C:\Perl\bin\perl.exe -wT use strict; use DBI; use CGI qw/:standard/; use CGI::Carp qw/fatalsToBrowser/; display_page("Got here!"); #routine to display any messages generated sub display_page { my $message = shift; print header, start_html, p( $message ), end_html; }
If that works in the browser, *then* move on to trying to get the database connection working.