/    Sign up×
Community /Pin to ProfileBookmark

calling an email address

I have a web site that has pages which are generated by CGI. Once a viewer clicks on a particular category, the CGI generated page for that category is displayed. I want to show banners which are specific to that category on the particular page. We have a JS which filters the url of the query string that selects the correct banner for the CGI page for each category. We have the JS working to filter correctly, and it displays the banners correctly. We are even able to attach a href to the banners as a hyperlink to other sites. What we cannot get to work is a “mailto” attached in the script for the banner.
For instance: a href=mailto:[email protected] will open the email program but will address the email to “tom.net” instead of “[email protected]” Here is the section of script that is giving us problems:

if(docloc==urls[0]){
document.write(“<a href=mailto:[email protected]><img src =http://www.somewhere.com/Bannerforsomebody.jpg></a>”)
}

to post a comment
JavaScript

2 Comments(s)

Copy linkTweet thisAlerts:
@AdamBrillApr 22.2003 — Hmm... Everything looks right. I even tried it to make sure and it worked fine for me, so I don't know what to tell you... Do you have a link to your site?
Copy linkTweet thisAlerts:
@DrDaMourApr 22.2003 — "<a href='mailto:[email protected]'><img..></a>"

maybe the @ is throwing it off, and it needs to be a string?
×

Success!

Help @SNAKE spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.16,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...