kinderyum Posted May 17, 2016 Share Posted May 17, 2016 (edited) At the moment, the email address in my Contact Information Block/Module can be clicked on and it opens up the user's default email program (mailto function).I would like to disable the mailto function and just have my email address in plain text (in the hope that it will reduce spam).I think I need to modify one or both of these two files?blockcontact.tplblockcontactinfos.tplin both my core folder and theme folderBut I do not know what the code should be. I have copied and pasted the present code below: blockcontact.tpl<div id="contact_block" class="block"><h4 class="title_block">{l s='Contact us' mod='blockcontact'}</h4><div class="block_content clearfix"><p>{l s='Our support hotline is available 24/7.' mod='blockcontact'}</p>{if $telnumber != ''}<p class="tel"><span class="label">{l s='Phone:' mod='blockcontact'}</span><span itemprop="telephone"><a href="tel:{$telnumber|escape:'html':'UTF-8'}">{$telnumber|escape:'html':'UTF-8'}</a></span></p>{/if}{if $email != ''}<a href="mailto:{$email|escape:'html':'UTF-8'}" title="{l s='Contact our expert support team!' mod='blockcontact'}">{l s='Contact our expert support team!' mod='blockcontact'}</a>{/if}</div></div> blockcontactinfos.tpl<!-- MODULE Block contact infos --><div id="block_contact_infos"><h4 class="title_block">{l s='Contact us' mod='blockcontactinfos'}</h4><ul>{if $blockcontactinfos_company != ''}<li><strong>{$blockcontactinfos_company|escape:'html':'UTF-8'}</strong></li>{/if}{if $blockcontactinfos_address != ''}<li><pre>{$blockcontactinfos_address|escape:'html':'UTF-8'|nl2br}</pre></li>{/if}{if $blockcontactinfos_phone != ''}<li>{l s='Tel' mod='blockcontactinfos'} {$blockcontactinfos_phone|escape:'html':'UTF-8'}</li>{/if}{if $blockcontactinfos_email != ''}<li>{l s='Email:' mod='blockcontactinfos'} {mailto address=$blockcontactinfos_email|escape:'html':'UTF-8' encode="hex"}</li>{/if}</ul></div><!-- /MODULE Block contact infos --> Edited May 17, 2016 by kinderyum (see edit history) Link to comment Share on other sites More sharing options...
musicmaster Posted May 18, 2016 Share Posted May 18, 2016 This is just simple html: remove the <a....> and </a> enclosing texts. So <a href="mailto:{$email|escape:'html':'UTF-8'}" title="{l s='Contact our expert support team!' mod='blockcontact'}">{l s='Contact our expert support team!' mod='blockcontact'}</a> will become just {l s='Contact our expert support team!' mod='blockcontact'} Link to comment Share on other sites More sharing options...
kinderyum Posted May 31, 2016 Author Share Posted May 31, 2016 This is just simple html: remove the <a....> and </a> enclosing texts. So <a href="mailto:{$email|escape:'html':'UTF-8'}" title="{l s='Contact our expert support team!' mod='blockcontact'}">{l s='Contact our expert support team!' mod='blockcontact'}</a> will become just {l s='Contact our expert support team!' mod='blockcontact'} Thank you! I will try it! Link to comment Share on other sites More sharing options...
kinderyum Posted May 31, 2016 Author Share Posted May 31, 2016 (edited) I tried it, but it's not working Maybe something needs to be changed in blockcontactinfos.tpl as well? Edited May 31, 2016 by kinderyum (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now