Page 1 of 1

Hiding email address

Posted: Wed Apr 19, 2006 5:36 pm
by sslieng
Script URL: www.iai-dojo.com
Version of script: gbook
Version of PHP: 1.35
Hosting company:
Have you searched THIS FORUM for your problem: yes
(if not please do before posting)
If so, what terms did you try: email

Write your message below:

Hi,
I want to hide our guest email address from any viewer of my guestbook for security reason (unauthorized reply, etc).
I tried to change the "function printEntries (.... )" at email-links row. I have the result : the gbook page is empty (blank screen: no error message and none of character showed).
Is there any way to hide email address?
Thanks.

Ps. I already read Henrie's modification, that an option for my guest to choose. That's not I mentioned above. thx.

Posted: Thu Apr 20, 2006 10:01 am
by Klemen
Hi,

This is actually a good idea, having e-mails hidden by default for better privacy and security and only shown to admin after entering a password. Will most likely include it in the next version, until then you can simply delete lines 582-586 in gbook.php (since your edited version doesn't work edit the ORIGINAL one again):

Lines to be deleted are 582-586:

Code: Select all

echo '<br>
<font class="smaller">E-mail:</font> ';
if (strlen($email)>0) {
echo '<a href="mailto:'.$email.'" target="_blank" class="smaller">'.$email.'</a>';
}
Regards

Posted: Thu Apr 20, 2006 12:56 pm
by sslieng
Hi,

Thanks so much. It's working now. Your Guest Book is really great. Thx.

Regards,

Siang Lieng

Posted: Mon Apr 02, 2007 3:18 am
by geos
Hi, I just wanted to know if that function for hiding the e-mails to public, but still visible for admin, was implemented because I didn't find it.

Posted: Mon Apr 02, 2007 8:15 am
by Klemen
No, not yet. You will still have to manually edit gbook.php to hide the e-mail address.

email address not hidden

Posted: Tue May 22, 2007 11:50 am
by shimmerfx
i have tried the suggestion but it's still showing the email address on my one at shimmerfx.com can anyone please help me?

Posted: Tue May 22, 2007 12:38 pm
by Klemen
In version 1.5 (which you have) find and delete this (lines 895-898):

Code: Select all

if ($email)
{
	echo 'E-mail: <a href="mailto:'.$email.'" class="smaller">'.$email.'</a>';
}
Note that the above code is located TWICE inside gbook.php, delete both or only the second one.