Forums

undefined index in mails.php on line 142

bitbonk 12 Feb, 2011
Hello I am using ChronoForms 3.1 RC5.5 with Joomla! I have a confirmation email setup that is sent to the customer and one is send to us. Since some time I get the following error after a form was posted:

Notice: Undefined index: in/mnt/web9/52/21/5541221/htdocs/spielwiese/components/com_chronocontact/libraries/mails.phpon line 142



The affected line in that file looks like this:

$from = (trim($email->fromemail)) ? trim($email->fromemail) : $posted[trim($email->dfromemail)];


The problem probably lies in
$posted[trim($email->dfromemail)]
what is dfrommail and what is $posted? How can I fix this problem?

I have found a table column that is called dfromname in jos_chrono_contact_emails

GreyHead 12 Feb, 2011
Hi bitbonk,

The quickest way to fix this is to hide the PHP Notices. Setting Error Reporting to 'None' or 'System Default' in the site global configuration should do it.

Bob
bitbonk 12 Feb, 2011
Thanks. And the not so quick way?
GreyHead 13 Feb, 2011
Hi bitbonk,

I think I see the problem. The first email id = 193 doesn't have a value in the From Email box. I think that if you put one in then the problem will go away.

Usually ChronoForms doesn't allow that - the Email Setup stays red if there is no entry in the box.

Bob
This topic is locked and no more replies can be posted.