Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

open email client program with functions 1

Status
Not open for further replies.

lovekang

Programmer
Feb 16, 2006
86
KR

It's a normail method to open email clients through A tag and the href attribute.
I'm worndering is it possible to achieve the same thing with javascript functions and vbscript functions.
If so how?

Thanks.

======== method 1(a tag)========
<html>
<head>
<title>method 1(a tag)</title>
</head>
<body>
<a href="mailto:a@b.com">mail to a@b.com</a>
</body>
</html>
======== method 2(javascript)========
<html>
<head>
<title>method 2(javascript)</title>
<script language=javascript>
function mailto(addr){
}
</script>
</head>
<body>
<span onClick="mailto('a@b.com')">mail to a@b.com</span>
</body>
</html>
======== method 3(vbscript)========
<html>
<head>
<title>method 3(vbscript)</title>
<script language="vbscript">
function mailto(addr)
msgbox addr
end function
</script>
</head>
<body>
<span onClick="mailto('a@b.com')">mail to a@b.com</span>
</body>
</html>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top