News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Contact Page

Started by SMFHacks.com Team, July 06, 2006, 12:59:38 PM

Previous topic - Next topic

vbgamer45

In SMF 2.0.x at least you have to edit this code in the index.php and add "contact" as an action to allow

// If guest access is off, a guest can only do one of the very few following actions.
elseif (empty($modSettings['allow_guestAccess']) && $user_info['is_guest'] && (!isset($_REQUEST['action']) || !in_array($_REQUEST['action'], array('coppa', 'login', 'login2', 'register', 'register2', 'reminder', 'activate', 'help', 'smstats', 'mailq', 'verificationcode', 'openidreturn'))))
{
require_once($sourcedir . '/Subs-Auth.php');
return 'KickGuest';
}
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Lucarella

Does the procedure change for 2.1.4?

vbgamer45

It might but look for similar code in the index.php file
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Lucarella

Everything ok, works well...

Thank you

vbgamer45

Great! Glad to help  8)
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Panoulis64

Quote from: Lucarella on March 11, 2024, 10:38:25 AMEverything ok, works well...

Thank you

There is the possibility to report exactly what you did and where in 2.1.4. Thanks.

Lucarella

Hi, as you can see from the image, you have to enter 'contact', in the same position where I put it


Panoulis64

Thank you, now a guest can contact, the contact form is displayed.

vbgamer45

Added Spanish ai assisted translation.
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

live627

Can you move your language entries to dedicated files instead of adding them to Modifications.english.php where the most mod conflicts occur upon uninstallation please?

marcosbr

 language portuguese_pt:

 

<file name="$languagedir/Modifications.portuguese_pt.php">
 <operation>
 <search position="after"><![CDATA[
?>]]></search>
 <add><![CDATA[
// Begin Contact Page Text Strings
$txt['smfcontact_contact'] = 'Contato';
$txt['permissionname_view_contact'] = 'Ver página de contato';
$txt['permissionhelp_view_contact'] = 'Permite que os membros visualizem a página de contato e enviem e-mails.';
$txt['cannot_view_contact'] = 'Você não pode visualizar a página de contato.';
$txt['smfcontact_name'] = 'Seu nome:';
$txt['smfcontact_subject'] = 'Assunto';
$txt['smfcontact_body'] = 'Menssagem';
$txt['smfcontact_emailaddress'] = 'Endereço de email';
$txt['smfcontact_sendemail'] = 'Enviar e-mail';
$txt['smfcontact_messagesent'] = 'Sua mensagem foi enviada!';
$txt['smfcontact_messagesent_click'] = 'Sua mensagem foi enviada! Click ';
$txt['smfcontact_messagesent_return'] = 'aqui</a> para retornar.';
$txt['smfcontact_errname'] = 'Você precisa digitar seu nome.';
$txt['smfcontact_errsubject'] = 'Você precisa digitar um assunto.';
$txt['smfcontact_errmessage'] = 'Você precisa digitar uma mensagem.';
$txt['smfcontact_erremail'] = 'Você precisa digitar seu endereço de e-mail.';
$txt['smfcontact_errbademail'] = 'Você não inseriu um endereço de e-mail válido.';
$txt['smfcontact_titlesent'] = ' - Mensagem enviada.';
$txt['smfcontact_form'] = 'Formulário de página de contato para ';
$txt['smfcontact_formname'] = "Nome: ";
$txt['smfcontact_formemail'] = "Email: ";
$txt['smfcontact_ip'] = "IP: ";
$txt['smfcontact_formmessage'] =  "mensagem: \n";
$txt['smfcontactpage_email'] = 'Página de contato - E-mail: ';
$txt['smfcontactpage_board'] = 'Página de contato - Quadro para postar (opcional): ';
// END Contact Page Text Strings
]]></add>
 </operation>
</file>
Do you feel superior?
Above is a slab and below is darkness. It's fire brother!
https://amigosdaeletronica.com.br

vbgamer45

Added the portuguese_pt translation!
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Sir Osis of Liver

I've installed current version of the mod on a 2.0.19 forum.  We're giving guests permission to use the form, but verification doesn't work correctly.  It's only presented on first page load, reloading form displays it without verification.  Any way to fix that?
When in Emor, do as the Snamors.
                              - D. Lister

vbgamer45

What type of verification are you using? this mod supports normal, recaptcha, hcaptcha
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Sir Osis of Liver

We have the Image for Anti-Spam Verification Questions installed -

https://custom.simplemachines.org/index.php?mod=4278

Without the mod verification questions are displayed correctly, but I'll have to code in the image in the contact template.
When in Emor, do as the Snamors.
                              - D. Lister

vbgamer45

That's probably why, I did not code to have that mod supported into the contact mod.
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Sir Osis of Liver

Ok, thanks.  I'll have to do it the hard way.
When in Emor, do as the Snamors.
                              - D. Lister

Sir Osis of Liver

Installed the mod on a 2.0.19 forum, didn't go well.  Set up verification questions with image (not the mod), works fine.  Gave guests permission to view contact page.  There are no members on this forum, all visitors are guests.  Guests do not see the main menu, so I coded a "Contact Us" link in the index template footer.  Everything looks and works fine, but we immediately started receiving spam emails.  With verification questions in place, I'm assuming these are human spammers,  How did they find the contact form so quickly?

My current theory is that a bot scraped the forum, found keyword "contact" in the page code, reported back to source, and human spammers followed to forum.  Is that how it works?  If so, I can replace the "Contact Us" text link with an image, so "contact" does not appear in view source, and change the action from "contact" to something else in contactHooks.php, since they already have it and it's easy to guess.

Does any of this make sense?
When in Emor, do as the Snamors.
                              - D. Lister

vbgamer45

It can happen normally bots will look for any pages that have forms then try to auto submit data.
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Sir Osis of Liver

Don't think they can auto submit anything without verification, and it's unlikely they got around that.  Would have to be human spammers, just a question of how they found it first day it was running.
When in Emor, do as the Snamors.
                              - D. Lister

Advertisement: