Hi Toby, Thanks for your help again. I'll use the reg ex our system admin guy is reluctant to install new modules on the webserver.
Thank You Colin -----Original Message----- From: Toby Stuart [mailto:[EMAIL PROTECTED]] Sent: Thursday, December 12, 2002 10:59 To: Johnstone, Colin Cc: '[EMAIL PROTECTED]' Subject: RE: Preserving funny characters in email addresses > -----Original Message----- > From: Johnstone, Colin [mailto:[EMAIL PROTECTED]] > Sent: Thursday, December 12, 2002 10:22 AM > To: '[EMAIL PROTECTED]' > Subject: Preserving funny characters in email addresses > > > Gidday All, > > I have written a perl cgi mailing list subscription application. > > How do I preserve funny characters in email addresses for example > > one subscriber's email address is > > sorcha.o'[EMAIL PROTECTED] > > but when written to the textfile where I store subscribers > names it is written as > > [EMAIL PROTECTED] > > Because of this she doesn't get the first email from us > telling her that she needs to confirm her subscription. > > Any help appreciated. > > Thanking you in anticipation > > use URI::Escape; $str = uri_unescape('[EMAIL PROTECTED]'); print $str; OR $str = '[EMAIL PROTECTED]'; $str =~ s/%([0-9A-Fa-f]{2})/chr(hex($1))/eg; print $str; -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]