By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,278 Members | 1,329 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,278 IT Pros & Developers. It's quick & easy.

Pass a querystring through <a href="mailto:xxxx .... using PHP variables

P: n/a
I'm trying to send a link with a querystring as the body of an email
message. My HTML syntax looks something like this:

<a href="mailto:xx*@yyy.com?Subject=<? print $subject ?>&Body=<? print
urlencode($url) ?>">Send an Email</a>

(I've had to URLENCODE the variables first, and it works. If I don't
do so, then it doesn't work.)

The problem occurs when it is time to display the encoded version. It
automatically translates it into the appropriate URL in certain email
clients (like OUTLOOK) but leaves it encoded in others (like
Groupwise).

Basically, I would like to be able to email a link in the body with
querystring in such a way that it appears on ALL email clients. I've
tried lots of things, but nothing seems to work. Any suggestions?
Jul 16 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Bill Petrol wrote:
Basically, I would like to be able to email a link in the body with
querystring in such a way that it appears on ALL email clients. I've
tried lots of things, but nothing seems to work. Any suggestions?


mailto: is simply unreliable. You cannot
help it in any way, except flushing it and using
your own form to send emails.

--
Seks, seksić, seksolatki... news:pl.soc.seks.moderowana
http://hyperreal.info { iWanToDie } WiNoNa ) (
http://szatanowskie-ladacznice.0-700.pl foReVeR( * )
Poznaj jej zwiewne kształty... http://www.opera.com 007
Jul 16 '05 #2

P: n/a
bp********@hotmail.com (Bill Petrol) shaped the electrons to say:
Basically, I would like to be able to email a link in the body with
querystring in such a way that it appears on ALL email clients. I've
tried lots of things, but nothing seems to work. Any suggestions?


mailto: is *extremely* unreliable. Hell, even the ?subject and ?body
extensions are not reliable. Anything beyond mailto:us**@domain.tld
is up for grabs and known not to work in various clients. I think
some of the extensions were finally codified in an RFC, but the
original RFC covering mailto only specified the address - so
everything else was a non-standard extension, and various clients
didn't always agree on what to support or even how to support a given
feature.

Putting that aside (and that is a LOT to put aside) you really have no
control over what the different email clients do with the content.
What is truly correct? Decoding the content? Or sending it as is? I
can see arguments for both.

(Personally I mailto: links tend not to work for me at all - I don't
keep email clients configured on my desktops, I read my email on a
UNIX shell in mutt over an ssh link. So mailto links either just
don't do anything, or they open the mailer on the box - but it isn't
configured to send anything anyway.)

-MZ, RHCE #806199299900541, ex-CISSP #3762
--
<URL:mailto:me******@megazone.org> Gweep, Discordian, Author, Engineer, me..
"A little nonsense now and then, is relished by the wisest men" 508-755-4098
<URL:http://www.megazone.org/> <URL:http://www.eyrie-productions.com/> Eris
Jul 16 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.