![]() |
|
| |||||||
| Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| HTML/XHTML CSS & JavaScript Pick up tips, exchange ideas and swap client side scripts. |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
One way to do it is to display it as an image, but this isn't very convenient for the user as they cannot click it to open their email client nor copy and paste it. One alternative is to use a link to an email form script, but this restricts what the user can do and also potentially opens a door for your server to be abused by an undesirable.
This method uses JavaScript to write the email address to the browser, which means that your address isn't in the source for the bots to read but is fully functional to your visitors. HTML Code:
<script language="JavaScript"><!-- var name = "YOUR_NAME"; var domain = "YOUR_SITE.com"; document.write('<a href=\"mailto:' + name + '@' + domain + '\">'); document.write(name + '@' + domain + '</a>'); // --></script>
__________________
Lawrence |
|
||||
|
Another way, just in case visitor has java turned off,
is to create an image, which shows your contact/ email details..code image, via html/php, into your web page. |
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| spam from email addresses used in html | Bill | eCommerce for Beginners | 3 | 30-11-2007 09:02 AM |
| How to use mod_rewrite to block bad bots with .htaccess | Lawrence | Servers | 0 | 30-10-2007 03:25 AM |
| Why don't people read? | Tinkerbell | Chill Out Lounge | 22 | 07-09-2007 04:47 PM |
| Display images on a page with no design restraints. | Lawrence | HTML/XHTML CSS & JavaScript | 1 | 06-09-2007 03:33 PM |
| How to display your PHP configuration | Lawrence | PHP/MySQL ASP.net and other server side technologies | 0 | 23-08-2007 06:59 AM |