Page 1 of 1

Re: Email approval not working

Posted: 19 Feb 2009, 23:53
by Jan
Hi, which version do you use, did you set the mail in parameters component, does your mail function work on your site?

Jan

Re: Email approval not working

Posted: 25 Mar 2009, 12:26
by mkraus81
i have the same error.
all other email-functions work, only the guestbook do not work...
i use the Phoca Guestbook 1.3.2

Re: Email approval not working

Posted: 25 Mar 2009, 12:35
by Jan
Hi, try to change the following code (on some servers there is a problem with e-mail name):

Line 535 +
in components\com_phocaguestbook\controllers\phocaguestbook.php
FROM:

Code: Select all

if (isset($post['email']) && $post['email'] != '') {
   $mailfrom = $post['email'];
} else {
   $mailfrom = $rows[0]->email;
} 
TO:

Code: Select all

$mailfrom = $rows[0]->email; 
Jan

Re: Email approval not working

Posted: 25 Mar 2009, 13:05
by mkraus81
hi,

it don´t work.

i found out something...

i think the problem is here
$send_mail = 0;
if ($params->get( 'send_mail' ) != '') {
$send_mail = $params->get( 'send_mail' );
}

because the following code will not work, because $send_mail is 0
if ((int)$send_mail > 0) {
PhocaGuestbookControllerPhocaGuestbook::sendPhocaGuestbookMail((int)$send_mail, $post, $uri->toString());
}
i test it i set in the code $send_mail to the id of the user and than it works...
with the code
$send_mail = $params->get( 'send_mail' );
i always get 0

The user is selected in the phoca guestbook parameters.
Do you have an Idea?

Re: Email approval not working

Posted: 25 Mar 2009, 16:04
by Jan
Did you select the user in parameters component in menu link to guestbook?

Re: Email approval not working

Posted: 25 Mar 2009, 16:15
by mkraus81
oooh thanks,

i dont know that i must select this in the menu parameters, i only selected it in the phoca guestbook parameters.
Now it works!

THANKS!!!!!

Re: Email approval not working

Posted: 30 Mar 2009, 14:30
by Jan
Great

Re: Email approval not working

Posted: 02 Apr 2009, 10:10
by willson
I'm am facing the same symptom (not emailing to admin) and also did not catch the "trick" that the destination always needs to be set in the menu item (everything else has Use Globals except this). Perhaps it would be an idea to have a big notice next to the setting in the component configuration window to remind those of us who aren't so quick off the mark.

So now, in my case, send_mail=66 (that's me, user 66) in jos_component and in jos_menu item too (I checked in the db to make sure).
But, still, in phocaguestbook.php I see that $params->get( 'send_mail')=0. That is, it's returning 0 instead of 66. Something of a mystery at the moment.
Note: If I force $send_mail=66 the mail sends okay so that's good new for me - I have a workaround.

I'm going to log out, make sure my sessions expire and try again - in case it's picking up something from the sessions variables. But if anyone has any ideas I'd be happy to hear them.

Running: phocaguestbook 1.3.2, joomla 1.5.9, php 5.1.6, Apache 2.2.0

Re: Email approval not working

Posted: 02 Apr 2009, 12:01
by willson
That was it. After the change to indicate the destination in the menu item did not work at first I then logged out of everything, went for a coffee, let the sessions expire and reentered the application. In the new session phocaguestbook picked up the new destination for sending the email and everything is now working as expected.

Thank you for all your fine components.

Re: Email approval not working

Posted: 18 Jun 2009, 15:29
by Jan
Ok