Helping ordinary people create extraordinary websites!
HOME TUTORIALS SCRIPTS WEB HOSTING BLOG FORUM
Get Our Newsletter
Email:
 
Floating Email-This-Link Script With URL Auto-Capture

This script creates a floating layer (scroll the page to see it work) with an email-this-link script in it. The layer can be positioned anywhere on the screen, and it will float to that position whenever the window is scrolled. Enter the recipient address and click the send button, and the visitor's email client is opened, complete with a message in the email body that includes the link for whatever page in which the script is placed.



Additional Script Notes




This script, though long, is easy to install -- just paste the entire code block into your page, just before the tag, now, the tag). Take special care not to let line-breaks intervene anywhere but where shown in the JavaScript portions of the code!

Customization of the appearance of the layer is done entirely with styles in the section marked as editable HTML.

Positioning is done with the hX and vY variables (see the script). This is a little unusual, so take note: a negative number in hX will position horizontally relative to the right of the screen; whilst a positive number will position relative to the left. Similarly, in the vY variable, a negative number will position relative to the bottom of the screen, whilst a positive one will position relative to the top. (Keep in mind that you must also allow for the dimensions of the layer.)

Using these two variables, however; it is possible to position the layer so that it floats in any desired position on the screen.

Finally (show enlarged, below), here is the background image used in the layer. Right-click and save-as to download a copy.


Author: CodeLifter
Price: Free
Version: 2.0
Platform(s): All
Rating:
Total Votes: 5
Demo: View it
Download Script: click here

Visit Site | Bookmark | Digg It! | Stumbleupon! | Send to a Friend | Report Bad Link


More JavaScript Email Scripts:
Ask A Question
characters left.