Hi, I get these error messages for a site I built, I am in need of help, how do you get it to work withouth these kind of messages. Thanks so much.😃
PHP Notice: Undefined variable: txtName in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 9 PHP Notice: Undefined variable: txtLast in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 10 PHP Notice: Undefined variable: txtCompany in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 11 PHP Notice: Undefined variable: txtPhone in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 12 PHP Notice: Undefined variable: txtAddress1 in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 13 PHP Notice: Undefined variable: txtAddress2 in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 14 PHP Notice: Undefined variable: txtCity in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 15 PHP Notice: Undefined variable: txtState in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 16 PHP Notice: Undefined variable: txtCountry in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 17 PHP Notice: Undefined variable: txtPostal in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 18 PHP Notice: Undefined variable: txtarea1 in C:\Inetpub[url]www.agimedia.com\contact_thanks.php(9[/url]) : eval()'d code on line 22 PHP Notice: Undefined variable: txtName in C:\Inetpub[url]www.agimedia.com\contact_thanks.php[/url] on line 12 PHP Notice: Undefined variable: txtName in C:\Inetpub[url]www.agimedia.com\contact_thanks.php[/url] on line 14 PHP Notice: Undefined variable: txtEmail in C:\Inetpub[url]www.agimedia.com\contact_thanks.php[/url] on line 14 PHP Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\Inetpub[url]www.agimedia.com\contact_thanks.php[/url] on line 14
absolutdmatt wrote:how do you get it to work withouth these kind of messages.
how do you get it to work withouth these kind of messages.
By not writing erroneous code.
In addition, you need to specify a valid SMTP server for PHP to be able to send mail.
From the error messages, I'd say you need to go back and define variables on lines 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 22, 12, and 14. Also, the aforementioned SMTP server.
Not to mention you should check to see if the form is posted in contact_thanks so people can't just get to that page accidentally. Helps with usability 😉
And I have to ask, why on earth are you eval()'ing all your form variables? ....
if you built this site you should know exactly why and where you cause these errors.
i must also ask why every var is being eval() ed ?
HINT: look inside of eval();