in reply to Re: Perl and Mysql Queries
in thread Perl and Mysql Queries
Here are the error messages:
[Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Premature en +d of script headers: job_post_test.pl, referer: http://diversitylink. +com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Bareword fou +nd where operator expected at E:\\Pinnacle\\DiversityLink\\cgi-bin\\j +ob_post_test.pl line 38, near "my$sth =$dbh->prepare("INSERT", refere +r: http://diversitylink.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] (Might be +a runaway multi-line "" string starting on line 37), referer: http:// +diversitylink.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Semicolon se +ems to be missing at E:\\Pinnacle\\DiversityLink\\cgi-bin\\job_post_t +est.pl line 38., referer: http://diversitylink.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Use of ?PATT +ERN? without explicit operator is deprecated at E:\\Pinnacle\\Diversi +tyLink\\cgi-bin\\job_post_test.pl line 39., referer: http://diversity +link.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Use of ?PATT +ERN? without explicit operator is deprecated at E:\\Pinnacle\\Diversi +tyLink\\cgi-bin\\job_post_test.pl line 39., referer: http://diversity +link.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Use of ?PATT +ERN? without explicit operator is deprecated at E:\\Pinnacle\\Diversi +tyLink\\cgi-bin\\job_post_test.pl line 39., referer: http://diversity +link.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Use of ?PATT +ERN? without explicit operator is deprecated at E:\\Pinnacle\\Diversi +tyLink\\cgi-bin\\job_post_test.pl line 39., referer: http://diversity +link.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Use of ?PATT +ERN? without explicit operator is deprecated at E:\\Pinnacle\\Diversi +tyLink\\cgi-bin\\job_post_test.pl line 39., referer: http://diversity +link.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Use of ?PATT +ERN? without explicit operator is deprecated at E:\\Pinnacle\\Diversi +tyLink\\cgi-bin\\job_post_test.pl line 39., referer: http://diversity +link.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] syntax error + at E:\\Pinnacle\\DiversityLink\\cgi-bin\\job_post_test.pl line 38, n +ear "my$sth =$dbh->prepare("INSERT INTO ", referer: http://diversityl +ink.com/ [Mon Jun 10 12:18:31 2024] [error] [client 73.21.226.229] Search patte +rn not terminated or ternary operator parsed as search pattern at E:\ +\Pinnacle\\DiversityLink\\cgi-bin\\job_post_test.pl line 39., referer +: http://diversitylink.com/
Here is the entire code:
#!C:/Perl/bin/perl -w ##post_jobs.pl use CGI qw(:standard); use DBI; print "Content-type: text/html\n\n"; ###use POSIX qw(strftime); ####$shortdate = strftime "%B %d, %Y", localtime; $JobID=param('JobID'); $EmployerID=param('EmployerID'); $EmployerName=param('EmployerName'); $Title=param('Title'); $Logo=param('Logo'); $City=param('City'); $StateProvince=param('StateProvince'); $Description=param('Description'); $Function=param('Function'); $Sector=param('Sector'); $Country=param('Country'); $Posted=param('Posted'); if ($JobID eq ""||$EmployerID eq ""||$EmployerName eq ""||$Title eq "" +||$Logo eq ""||$City eq ""||$StateProvince eq ""||$Description eq ""| +| $Function eq ""||$Sector eq ""||$Country eq ""||$Posted eq ""||$Logo e +q "") { print "The FORM is INCOMPLETE"; } else { my$dbh = DBI->connect('dbi:mysql:jobs_db', "Poster','Poster Password') +; my$sth =$dbh->prepare("INSERT INTO jobs (JobID,EmployerID,EmployerName +,Title,City,StateProvince,Description,Function,Sector,Country,Posted) Values(?,?,?,?,?,?,?,?,?,?,?)"); $sth ->execute($JobID,$EmployerID,$EmployerName,$Title,$City,$StatePro +vince,$Description,$Function,$Sector,$Country,$Posted); $sth ->finish(); $dbh->disconnect (); } #!/usr/local/bin/perl print "Your Ad Was Posted.\n"; exit;
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Perl and Mysql Queries
by Danny (Chaplain) on Jun 10, 2024 at 19:43 UTC | |
by etj (Priest) on Jun 11, 2024 at 08:41 UTC | |
by mldvx4 (Friar) on Jun 11, 2024 at 09:59 UTC | |
Re^3: Perl and Mysql Queries
by talexb (Chancellor) on Jun 11, 2024 at 01:56 UTC | |
by Milti (Beadle) on Jun 11, 2024 at 12:27 UTC | |
by hippo (Archbishop) on Jun 11, 2024 at 12:47 UTC | |
by Milti (Beadle) on Jun 11, 2024 at 15:08 UTC | |
by marto (Cardinal) on Jun 11, 2024 at 15:49 UTC | |
by Danny (Chaplain) on Jun 11, 2024 at 15:23 UTC | |
by hippo (Archbishop) on Jun 11, 2024 at 15:35 UTC | |
by Milti (Beadle) on Jun 11, 2024 at 15:56 UTC | |
| |
by talexb (Chancellor) on Jun 11, 2024 at 13:14 UTC | |
by talexb (Chancellor) on Jun 14, 2024 at 14:06 UTC | |
by soonix (Chancellor) on Jun 11, 2024 at 12:52 UTC | |
by Danny (Chaplain) on Jun 11, 2024 at 14:21 UTC | |
Re^3: Perl and Mysql Queries
by GrandFather (Saint) on Jun 10, 2024 at 22:08 UTC |