Title: javascript email link? or mailto with php?
Last modified: August 19, 2016

---

# javascript email link? or mailto with php?

 *  [mdavidson](https://wordpress.org/support/users/mdavidson/)
 * (@mdavidson)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/javascript-email-link-or-mailto-with-php/)
 * I’m looking to add a simple mailto to of my blog.
 *     ```
       <SCRIPT TYPE="text/javascript">
       emailE=('myname@' + 'mysite.com')
       document.write('<A href="mailto:' + emailE + '">' + emailE + '</a>')
        //-->
       </script>
       ```
   
 * Can’t seem to make it work.
    Works fine on html pages… I’m new to php.
 * I implemented:
    `<?php echo antispambot(get_the_author_email()); ?>` but I want
   a clickable mailto- this just displays the address, unless I’m doing it wrong.
   My goal is to put my email on within the footer, within a page, and perhaps in
   a post.
 * thanks for any help or advice…

Viewing 1 replies (of 1 total)

 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/javascript-email-link-or-mailto-with-php/#post-1379331)
 * `<a href="mailto:email_address_goes_here">Mail link text</a>`

Viewing 1 replies (of 1 total)

The topic ‘javascript email link? or mailto with php?’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 2 participants
 * Last reply from: [esmi](https://wordpress.org/support/users/esmi/)
 * Last activity: [16 years, 4 months ago](https://wordpress.org/support/topic/javascript-email-link-or-mailto-with-php/#post-1379331)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
