option to hide emails

More
8 years 10 months ago #13944 by Beeman
option to hide emails was created by Beeman
I have just downloaded the latest version of your guestbook ... looks good and still finding my way around the various files - but:
Is there an option to hide email addresses displayed in the 'view' part of the guestbook ?
I would like to have the email address of the visitor so as to bee able to respond but not let the whole world - and spammers - have access to individual emails ... ?

Please Log in or Create an account to join the conversation.

More
8 years 10 months ago - 8 years 10 months ago #13946 by Pete
Replied by Pete on topic option to hide emails
Yes, the option is in the configuration file. Here is how to enable the option to hide the email field:

1. Open the file "/includes/config.php" in Notepad or any text editor.
2. Find the following line (line 17):

Code:
$email_optional = 0;

Change it to the following:
Code:
$email_optional = 1;

That's it. Enjoy!

Pete

DigiOz Webmaster
www.digioz.com
Last edit: 8 years 10 months ago by Pete.

Please Log in or Create an account to join the conversation.

More
8 years 10 months ago #13947 by Beeman
Replied by Beeman on topic option to hide emails
Mornin' Pete

Thanks for your response but perhaps I did not explain myself correctly.

Your solution of ... "$email_optional = 0; // Set "1" for optional email, "0" to make it required" ...
means visitors have the option to input their email address ... this is not a mandatory field, but they can if they so wish, yes ?

I changed the '0' to a '1' ... filled out all fields including my email address and submitted my entry.
On subsequently viewing the 'guestbook' ... my email address was displayed.

Is there any way I can require visitors to submit their email addresses (make this a mandatory field - i.e. $email_optional = 0;) but NOT have their email address displayed in the 'view' part of the guestbook ?

Please Log in or Create an account to join the conversation.

More
8 years 10 months ago - 8 years 10 months ago #13948 by Pete
Replied by Pete on topic option to hide emails
Ah, I see what you mean now. Go ahead and revert the email optional value to the following:

Code:
$email_optional = 0;

Next, open the file list.php in notepad, and remove this line from it (line 137):

Code:
$tpl->assign( "outputemail", $lines[$i]->gbEmail);

This should do it for you. The email field is now not displayed, but is required to be submitted by the user. If you also don't want to show the field label, open the file "/themes/default/list.html", and remove this line from it:

Code:
<b>{$listemailtxt}</b>: <a href="mailto:{$outputemail}">{$outputemail}</a><br /><br />

You will still be able to see the emails in the administrative dashboard at "/admin".

Thanks,
Pete

DigiOz Webmaster
www.digioz.com
Last edit: 8 years 10 months ago by Pete.
The following user(s) said Thank You: Beeman

Please Log in or Create an account to join the conversation.

More
8 years 10 months ago #13949 by Beeman
Replied by Beeman on topic option to hide emails
:) Many thanks for this one ...

Beeman

Please Log in or Create an account to join the conversation.

Time to create page: 0.118 seconds
Powered by Kunena Forum