473,385 Members | 1,282 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

name instead of email address in To: field from mailto: link

I am trying to set up a mailto: link so that the actual address that
the email is being sent to is obscured and replaced by a name. For
example, I have <a href="mailto:js*****@abc.com">Joe Schmoe</a>. When
this link is clicked, an email window appears in the clicker's email
client where the To: field is js*****@abc.com. What I want to have
displayed there is Joe Schmoe. I've seen it suggested that formatting
the link like this: <a href="mailto:Joe Schmoe<js*****@abc.com>">Joe
Schmoe</a> will work. I've tried that to no avail. I also took a
stab in the dark and tried
<a href="mailto:js*****@abc.com?To=Joe%20Schmoe">Joe Schmoe</a> but
that didn't work either. Any help here would be greatly appreciated.
Thanks.
Jul 20 '05 #1
18 28287

"Shinin" <bw*******@snl.com> wrote in message
news:99*************************@posting.google.co m...
I am trying to set up a mailto: link so that the actual address that
the email is being sent to is obscured and replaced by a name. For
example, I have <a href="mailto:js*****@abc.com">Joe Schmoe</a>. When
this link is clicked, an email window appears in the clicker's email
client where the To: field is js*****@abc.com. What I want to have
displayed there is Joe Schmoe. I've seen it suggested that formatting
the link like this: <a href="mailto:Joe Schmoe<js*****@abc.com>">Joe
Schmoe</a> will work. I've tried that to no avail. I also took a
stab in the dark and tried
<a href="mailto:js*****@abc.com?To=Joe%20Schmoe">Joe Schmoe</a> but
that didn't work either. Any help here would be greatly appreciated.
Thanks.


Try mailto:Joe%20Schmoe%20%3cjs*****@abc.com%3e

In other words,
Joe Schmoe <js*****@abc.com>

Jul 20 '05 #2
in post: <news:99*************************@posting.google.c om>
bw*******@snl.com (Shinin) said:
I am trying to set up a mailto: link so that the actual address that
the email is being sent to is obscured and replaced by a name.


&deity; will punish your evil doings

--
brucie - i usenet nude
Jul 20 '05 #3
On 30 Jan 2004 10:26:44 -0800, Shinin <bw*******@snl.com> wrote:
I am trying to set up a mailto: link so that the actual address that
the email is being sent to is obscured and replaced by a name. For
example, I have <a href="mailto:js*****@abc.com">Joe Schmoe</a>. When
this link is clicked, an email window appears in the clicker's email
client where the To: field is js*****@abc.com. What I want to have
displayed there is Joe Schmoe.
Oh my. I wonder what you hope to gain here. You won't be hiding the email
address.
I've seen it suggested that formatting
the link like this: <a href="mailto:Joe Schmoe<js*****@abc.com>">Joe
Schmoe</a> will work. I've tried that to no avail. I also took a
stab in the dark and tried
<a href="mailto:js*****@abc.com?To=Joe%20Schmoe">Joe Schmoe</a> but
that didn't work either. Any help here would be greatly appreciated.
Thanks.


mailto protocols aren't universally recognized. Even setting a subject
isn't a guarantee the subject will appear.

I recommend not using a mailto link at all. Instead, set up a form. The
nmc version of formmail at http://www.scriptarchive.com is easy to
install. Your host must allow you to have CGIs, if they do all the
necessary information you need to set it up should be available from the
tech help section of their website.

Jul 20 '05 #4
On Sat, 31 Jan 2004 04:29:55 -0500, Neal <ne*****@spamrcn.com> wrote:
The nmc version of formmail at http://www.scriptarchive.com is easy
to install.


It's also rather out of date. Get the newest version directly from the
NMS project: http://nms-cgi.sourceforge.net/

Cheers,
Philip
--
Philip Newton <no***********@gmx.li>
That really is my address; no need to remove anything to reply.
If you're not part of the solution, you're part of the precipitate.
Jul 20 '05 #5
On Sat, 31 Jan 2004 10:45:30 +0100, Philip Newton
<pn*************@newton.digitalspace.net> wrote:
On Sat, 31 Jan 2004 04:29:55 -0500, Neal <ne*****@spamrcn.com> wrote:
The nmc version of formmail at http://www.scriptarchive.com is easy
to install.


It's also rather out of date. Get the newest version directly from the
NMS project: http://nms-cgi.sourceforge.net/


News to me, thanks for the link.
Jul 20 '05 #6
On Sat, 31 Jan 2004 04:29:55 -0500, Neal <ne*****@spamrcn.com> wrote:
mailto protocols aren't universally recognized. Even setting a subject
isn't a guarantee the subject will appear.
AIUI mailto is a recognised standard (if I was less lazy I'd quote the
RFC) though not all browser/email-client combinations support it. OTOH
setting the subject is not standardised, and decreases the chances of
the mailto link working.
I recommend not using a mailto link at all. Instead, set up a form.


I'd recommend supplying both.

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 20 '05 #7
"Harlan Messinger" <h.*********@comcast.net> wrote in message news:<bv************@ID-114100.news.uni-berlin.de>...

Try mailto:Jo***********************@abc.com%3e

In other words,
Joe Schmoe <js*****@abc.com>


To be standards-compliant, there should be quotes around the
human-readable-name portion, since it contains a space; in other
words:

mailto:%22Joe%20Schmoe%22%20%3cjs*****@abc.com%3e

"Joe Schmoe" <js*****@abc.com>

However, at least in my browser (Mozilla), the resulting mail window
comes up with both the human-readable name and the actual address
showing; it doesn't "hide" anything. And that's the way things
*ought* to be.

Maybe with Microsoft idiotware, though, the technique would "work",
given how that software loves to hide things from its users.

--
Dan
Jul 20 '05 #8
Neal wrote:

mailto protocols aren't universally recognized.
....by web user-agents. That last part is important. The mailto
protocol is registered.

http://www.w3.org/Addressing/URL/4.1_Schemes.html
Even setting a subject isn't a guarantee the subject will appear.
No, but then, subject isn't part of the mailto: protocol.
I recommend not using a mailto link at all. Instead, set up a form. These are not mutually exclusive. The best solution is to offer both
an email address and a form.
The nmc version of formmail at http://www.scriptarchive.com
nmc? Who are they? The link you provided points to Matt's Script Archive.

To the OP: I highly recommend that you consider the NMS formmail
script. Better written. Better support. Allows you to hide the
destination email address from spambots. And also free.

http://nms-cgi.sourceforge.net/
Your host must allow you to have CGIs, if they do all the necessary
information you need to set it up should be available from the tech
help section of their website.


Many isp's offer a formmail script built in to the hosting package.
You may already have a formmail and not know it. This, too, is
something for tech support to answer.

--
Brian (follow directions in my address to email me)
http://www.tsmchughs.com/

Jul 20 '05 #9
On Sat, 31 Jan 2004 18:38:13 GMT, Brian
<us*****@julietremblay.com.invalid-remove-this-part> wrote:
The nmc version of formmail at http://www.scriptarchive.com
nmc? Who are they? The link you provided points to Matt's Script Archive.


Yeah, I speled it rong. Fortunately, I think other readers figured it
out... And at the time, I was unaware that nm"S" had a separate site, I
had only encountered the older script versions at Matt's site.
To the OP: I highly recommend that you consider the NMS formmail
script. Better written. Better support. Allows you to hide the
destination email address from spambots. And also free.

http://nms-cgi.sourceforge.net/


Now that I know it's available in a more recent version, I can't disagree.
Jul 20 '05 #10
da*@tobias.name (Daniel R. Tobias) wrote:
"Harlan Messinger" <h.*********@comcast.net> wrote in message news:<bv************@ID-114100.news.uni-berlin.de>...

Try mailto:Jo***********************@abc.com%3e

In other words,
Joe Schmoe <js*****@abc.com>


To be standards-compliant, there should be quotes around the
human-readable-name portion, since it contains a space;


If it contains a space or if it contains an escape code standing in
for a space?

--
Harlan Messinger
Remove the first dot from my e-mail address.
Veuillez ōter le premier point de mon adresse de courriel.
Jul 20 '05 #11
Neal wrote:
On Sat, 31 Jan 2004 18:38:13 GMT, Brian wrote:
The nmc version of formmail at http://www.scriptarchive.com


nmc? Who are they? The link you provided points to Matt's Script
Archive.


Yeah, I speled it rong. Fortunately, I think other readers figured
it out...


Everyone except me, it seems. Sorry, it didn't occur to me that you
meant "nms."

--
Brian (follow directions in my address to email me)
http://www.tsmchughs.com/

Jul 20 '05 #12
On Sat, 31 Jan 2004 23:01:38 GMT, Brian
<us*****@julietremblay.com.invalid-remove-this-part> wrote:
Neal wrote:
On Sat, 31 Jan 2004 18:38:13 GMT, Brian wrote:
The nmc version of formmail at http://www.scriptarchive.com

nmc? Who are they? The link you provided points to Matt's Script
Archive.


Yeah, I speled it rong. Fortunately, I think other readers figured
it out...


Everyone except me, it seems. Sorry, it didn't occur to me that you
meant "nms."


Line 32, column 56: element "NMC" undefined :)

I should have known that was wrong though. NMC was the summer camp I went
to as a kid. Maybe I'm subconsciously pining for warmer days...
Jul 20 '05 #13
Tim
"Harlan Messinger" <h.*********@comcast.net> wrote
Try mailto:Jo***********************@abc.com%3e

In other words,
Joe Schmoe <js*****@abc.com>


da*@tobias.name (Daniel R. Tobias) wrote:
To be standards-compliant, there should be quotes around the
human-readable-name portion, since it contains a space; in other
words:


It shouldn't be necessary, blank spaces are allowed in the so-called
"display name" that goes along with an e-mail address (the server
ignores stuff outside of the < >, that extra stuff is just for your
benefit).

Generic e-mail syntax: display name <address> (comments)

Example: John Doe <jd**@example.com> (Manager)

If there was a comma, though, you would need to quote the name, as
commas are used as delimiters between multiple addresses (the quotes
stop that comma being interpreted as a delimiter).

e.g. "Doe, John" <jd**@example.com>, Jane Doe <ja***@example.com>

--
My "from" address is totally fake. The reply-to address is real, but
may be only temporary. Reply to usenet postings in the same place as
you read the message you're replying to.

This message was sent without a virus, please delete some files yourself.
Jul 20 '05 #14
Tim <Ti*@mail.localhost> wrote in message news:<ut********************************@4ax.com>. ..
da*@tobias.name (Daniel R. Tobias) wrote:
To be standards-compliant, there should be quotes around the
human-readable-name portion, since it contains a space; in other
words:


It shouldn't be necessary, blank spaces are allowed in the so-called
"display name" that goes along with an e-mail address (the server
ignores stuff outside of the < >, that extra stuff is just for your
benefit).


By my reading of RFC 2822:
http://www.rfc-editor.org/rfc/rfc2822.txt
the quotes are necessary in the display name if spaces are included.

To see why, you have to untangle a series of BNF definitions:

address = mailbox / group
mailbox = name-addr / addr-spec
name-addr = [display-name] angle-addr
angle-addr = [CFWS] "<" addr-spec ">" [CFWS] /
obs-angle-addr
display-name = phrase

According to the above, an address that includes a display-name
consists of the display name followed by the address within angle
brackets, and the display-name is a "phrase".

Then, you have these definitions:

word = atom / quoted-string
phrase = 1*word / obs-phrase

A phrase has only one word, but a "word" can be a quoted string. An
"atom" is defined so as to include only a limited set of name
characters not including the space.

--
Dan
Jul 20 '05 #15
Harlan Messinger <hm*******************@comcast.net> wrote in message news:<2f********************************@4ax.com>. ..
da*@tobias.name (Daniel R. Tobias) wrote:
To be standards-compliant, there should be quotes around the
human-readable-name portion, since it contains a space;


If it contains a space or if it contains an escape code standing in
for a space?


If it contains a space after the URI escapes are decoded, since the
standard in question is the one for e-mail headers (RFC 2822), not the
one for URIs.

--
Dan
Jul 20 '05 #16
da*@tobias.name (Daniel R. Tobias) writes:
By my reading of RFC 2822: http://www.rfc-editor.org/rfc/rfc2822.txt
the quotes are necessary in the display name if spaces are included.

To see why, you have to untangle a series of BNF definitions:

address = mailbox / group
mailbox = name-addr / addr-spec
name-addr = [display-name] angle-addr
angle-addr = [CFWS] "<" addr-spec ">" [CFWS] /
obs-angle-addr
display-name = phrase

According to the above, an address that includes a display-name
consists of the display name followed by the address within angle
brackets, and the display-name is a "phrase".

Then, you have these definitions:

word = atom / quoted-string
phrase = 1*word / obs-phrase

A phrase has only one word, but a "word" can be a quoted string. An
"atom" is defined so as to include only a limited set of name
characters not including the space.


Check out RFC 2234 <http://www.rfc-editor.org/rfc/rfc2234.txt>,
Section 3.6:

3.6. Variable Repetition: *Rule

The operator "*" preceding an element indicates repetition. The full
form is:

<a>*<b>element

where <a> and <b> are optional decimal values, indicating at least
<a> and at most <b> occurrences of element.

Default values are 0 and infinity so that *<element> allows any
number, including zero; 1*<element> requires at least one;
3*3<element> allows exactly 3 and 1*2<element> allows one or two.

So "1*word" means at least one word, not exactly one word.

Also, RFC 2822 Section 9.1. A.1. ("Addressing Examples") contains
several examples of display names with spaces and no quotation marks.
However, the quotation marks are required if the display name has any
punctuation, including periods, commas, or apostrophes (so names like
"O'Hara" have to be in quotation marks).

--
Dean Tiegs, NEĀ¼-20-52-25-W4
ā€œConfortare et esto robustusā€
http://telusplanet.net/public/dctiegs/
Jul 20 '05 #17
Dean Tiegs wrote:
So "1*word" means at least one word, not exactly one word.

Also, RFC 2822 Section 9.1. A.1. ("Addressing Examples") contains
several examples of display names with spaces and no quotation marks.
However, the quotation marks are required if the display name has any
punctuation, including periods, commas, or apostrophes (so names like
"O'Hara" have to be in quotation marks).


Thanks for the clarification. (However, when I reread the RFC now, it
seemed like the apostrophe was in fact in the list of permitted
characters in an atom, so it might not require quotes around it.)

--
== Dan ==
Dan's Mail Format Site: http://mailformat.dan.info/
Dan's Web Tips: http://webtips.dan.info/
Dan's Domain Site: http://domains.dan.info/
Jul 20 '05 #18
"Daniel R. Tobias" <da*@tobias.name> writes:
Dean Tiegs wrote:
So "1*word" means at least one word, not exactly one word. Also,
RFC 2822 Section 9.1. A.1. ("Addressing Examples") contains several
examples of display names with spaces and no quotation marks.
However, the quotation marks are required if the display name has
any punctuation, including periods, commas, or apostrophes (so
names like "O'Hara" have to be in quotation marks).


Thanks for the clarification. (However, when I reread the RFC now,
it seemed like the apostrophe was in fact in the list of permitted
characters in an atom, so it might not require quotes around it.)


Yes, the apostrophe is OK. After I had posted, I realized that I ought
to have checked that fact and not relied on my memory.

--
Dean Tiegs, NEĀ¼-20-52-25-W4
ā€œConfortare et esto robustusā€
http://telusplanet.net/public/dctiegs/
Jul 20 '05 #19

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: magister | last post by:
Hi I am sending emails from my website. The from field usually is an email address, but alot of email readers also seem to be able to pickup a "from real name". I read somewhere that I can set...
117
by: Steevo | last post by:
Any suggestions as to the best programs for cloaking email addresses? Many thanks -- Steevo
3
by: scott_baird | last post by:
I have an email macro setup (maybe I should go another way, but that was the quickest at the moment...) and what I would like to do is automate the "to" addressee of the email it generates for...
5
by: gullyou | last post by:
Sorry I crossposted this to java group. Didn't know distinction between Java & Javascript Hi, I'm not a Java script programmer but have this web page with a form form that includes a...
1
by: Mike | last post by:
Hi all, I need to verify that the supplied email address is valid or not. So, here's my situation: - In my <profilearea, I created <isVerifiedproperty. - Suppose a new user has been created. I...
4
by: Mike | last post by:
Hi all, In my recent ASP.NET 2.0 appl, I need to verify that the supplied email address is valid or not. So, here's my situation: - In my <profilearea, I created <isVerifiedproperty. - Suppose a...
5
by: wizard04 | last post by:
I'm trying to validate an email address field before it is submitted. I have read RFC 822 (http://www.faqs.org/rfcs/rfc822.html) but I'm not sure I'm fully grasping it. As far as I understand, a...
2
by: mshajar | last post by:
How to validate an email address field about including the @ sign which is not a Hyperlink field.
1
by: saravanatmm | last post by:
I need javascript code for validate the email address. Email address field cannot allowed the capital letters, special characters except '@' symbol. But can allowed the small letters, numeric...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.