$time = time; ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime($tim +e); $mon++; $year += 1900; $memo = "Original Message\n------------\n$INPUT{'memo'}"; $memo_final = $memo . "\n\nCreated by: $username\nDate Created: $year- +$mon-$mday\n\n"; use DBI; my $dbh_m = DBI->connect('DBI:mysql:MEMO') or print "Couldn't con +nect to database: " . DBI->errstr; $sql_m = " INSERT INTO memo VALUES ( '?', '$year-$mon-$mday', '$INPUT{'user'}', '$INPUT{'ref'}', '$INPUT{'username'}', 'notread', '$memo_final' ) "; $sth_m = $dbh_m->prepare($sql_m) or print "preparing: ",$dbh_m->errst +r; $sth_m->execute or print "executing: ", $dbh_m->errstr; $sth_m->finish; $dbh_m->disconnect; &header; print <Memo to $INPUT{'user'} successfully added.
EOF &footer; #### $time = time; ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime($time); $mon++; $year += 1900; my $memo = "Original Message\n------------\n$INPUT{'memo'}"; my $memo_final = "$memo" . "\n\nCreated by: $username\nDate Created: $year-$mon-$mday\n\n"; use DBI; my $dbh_m = DBI->connect('DBI:mysql:MEMO') or print "Couldn't connect to database: " . DBI->errstr; DBI->trace(2); my $sth_m = $dbh_m->prepare(<execute('?', '$year-$mon-$mday', '$INPUT{'user'}', 'INPUT{'ref'}', '$INPUT{'username'}', 'notread', '$memo_final'); #line 148 $sth_m->finish; $dbh_m->disconnect; DBI->trace(0); &header; print <Memo to $INPUT{'user'} successfully added.
EOF &footer;