Jump to content

[SOLVED] email code, where email is hidden


Recommended Posts

this is a code i found in a template system

<span style="float: right; text-align: right;"><a target="_blank" rel="external" href='javascript:window.location="mai"+"lto:"+"admin"+"@"+"randomgamedesign.uk.tt";self.close();' onmouseover='window.status="mai"+"lto:"+"admin"+"@"+"randomgamedesign.uk.tt"; return true;' onmouseout='window.status="";return true;'>Email </a></span>

 

how can i use this code or something similar so you can only email them, and not see there email when you mouseover?

Link to comment
Share on other sites

I think I understand now.

Use explode function on there email address.

 

<?php
$email = "admin@randomgamedesign.uk.tt";
$email = explode($email, '@');
?>
<span style="float: right; text-align: right;"><a target="_blank" rel="external" href='javascript:window.location="mai"+"lto:"+"<?php echo $email[0]; ?>"+"@"+"<?php echo $email[1]; ?>";self.close();' ;return true;'>Email </a></span>

Does that make sense?

Link to comment
Share on other sites

yer, i think  i understand, i can replace this

$email = "admin@randomgamedesign.uk.tt";

 

with

$email = "something_from_mydatabase_using_a_query";

Yeah, as long as the something from your database is a valid email.

Link to comment
Share on other sites

i tried this way , and it didn't work

<?php
$email = "admin@randomgamedesign.uk.tt";
$email = explode($email, '@');
?>
<span style="float: right; text-align: right;"><a target="_blank" rel="external" href='javascript:window.location="mai"+"lto:"+"<?php echo $email[0]; ?>"+"@"+"<?php echo $email[1]; ?>";self.close();' ;return true;'>Email </a></span>

 

so i think i will have to try this way, and have two input boxes one for

"email" and another for "hotmail.com".

Unless anyone knows a better way to reduce spam.

Link to comment
Share on other sites

i tried this way , and it didn't work

<?php
$email = "admin@randomgamedesign.uk.tt";
$email = explode($email, '@');
?>
<span style="float: right; text-align: right;"><a target="_blank" rel="external" href='javascript:window.location="mai"+"lto:"+"<?php echo $email[0]; ?>"+"@"+"<?php echo $email[1]; ?>";self.close();' ;return true;'>Email </a></span>

 

so i think i will have to try this way, and have two input boxes one for

"email" and another for "hotmail.com".

Unless anyone knows a better way to reduce spam.

Try explode('@',$email);

Sorry, I made a mistake in the function syntax.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.