Guestbook notification

Dr. GBooky is here to help you with your guestbook problems ...
Post Reply
cmpque
Posts: 3
Joined: Sun Apr 09, 2006 6:31 pm

Guestbook notification

Post by cmpque »

Script URL:
Version of script: GB 1.35
Version of PHP:
Hosting company: emax
Have you searched THIS FORUM for your problem: Yes
(if not please do before posting)
If so, what terms did you try: email, admin

Write your message below:

When I receive guestbook notificaiton email it says it is from marchin@gary.yourhostdsn.com. Is there a way to change this to say its from my website or something else. Thanks
Henrie
Posts: 1095
Joined: Sun Aug 14, 2005 8:57 pm

Post by Henrie »

Hello cmpque,

There is a way by editing the gbook.php file.

Find this line (line 484 in GBook 1.35)

Code: Select all

mail("$settings[admin_email]","Someone has just signed your guestbook",$message);}
To show a fixed name as the name, change it to this:

Code: Select all

mail("$settings[admin_email]","Someone has just signed your guestbook",$message,"From: gbook");}
To show the name of the sender, change it to this:

Code: Select all

mail("$settings[admin_email]","Someone has just signed your guestbook",$message,"From: $name");}
To show the name of the sender with the e-mail address linked to it so you can reply a mail, change it to this:

Code: Select all

mail("$settings[admin_email]","Someone has just signed your guestbook",$message,"From: $name <$email>");}
Ofcourse the last only works if a e-mail address is entered otherwise you can't reply.

Greetings,
Henrie
cmpque
Posts: 3
Joined: Sun Apr 09, 2006 6:31 pm

Post by cmpque »

Thanks Henrie,

The second and third methods worked like a charm. The first method shows gbook@gary.yourhostdsn.com and not just the fixed name.

Thanks again, cmpque
Henrie
Posts: 1095
Joined: Sun Aug 14, 2005 8:57 pm

Post by Henrie »

Well,

They all work for me, I tested before I posted.
Maybe a difference in the settings of the server?
Perhaps adding single quotes around the name helps, like not gbook but 'gbook'

Greetings,
Henrie
cmpque
Posts: 3
Joined: Sun Apr 09, 2006 6:31 pm

Post by cmpque »

Nope I tried the 'gbook' it still list as gbook@gary.yourhostdsn.com, It must me some setting with my host server. I'm good with the other methods. Thanks,

cmpque
Post Reply