You didn't provide enough of your Perl source code to solve your problem. When I copied your code to my machine I instantly got errors regarding the %in hash so I replaced that with the ever-popular CGI module:

use CGI qw|:standard|; #my $firstname = $in{name}; + my $firstname = CGI::param('name');

Now to get it to compile cleanly you have other problems:

use strict; #<- get into the habit of using this #... my ($lastname, $date_first_employed, $annual_salary, $id , $email_address, $home_phone_number, $emergency_phone_number); while (($lastname, $date_first_employed, $annual_salary, $id, $email_address, $home_phone_number, $emergency_phone_number) = $sth->f +ethrow_array()) #...

You are using $date_first_employed multiple times in while statement (I changed it) and although you were using $id in your print statement on line 61 you had not defined or set it to anything. Strict would have complained about these things.

Wow, my SQL skills must be getting rusty when I see your query -- from where I'm sitting that isn't ever going to work:

"SELECT lastname, date_first_employed, annual_salary FROM employees WH +ERE firstname = $qfirstname, SELECT * FROM employee_contacts WHERE contact_id = $qcontactid")

These are two totally separate SQL statements comma separated. Is there database engine that allows that? If so please let me know.

Celebrate Intellectual Diversity


In reply to Re: Calling a PERL script from an html form by InfiniteSilence
in thread Calling a PERL script from an html form by steampunk333

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.