Javascript: E-mail This Page


/ Published in: JavaScript
Save to your folder(s)



Copy this code and paste it in your HTML
  1. function mailpage() {
  2. mail_str = "mailto:?subject=Link from Yourwebsite.com";
  3. mail_str += "&body=I thought you would enjoy looking at this page.";
  4. mail_str += " " + parent.location.href;
  5. location.href = mail_str;
  6. }
  7.  
  8.  
  9.  
  10.  
  11. <a href="javascript:mailpage()">E-mail this page</a>

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.