Form processing

Form processing

am 12.09.2007 03:32:36 von Ron Piggott

------=OPENWEBMAIL_ATT_0.301777760536549
Content-Type: text/plain;
charset=iso-8859-1

I am trying to set up a form which will send e-mails for "late breaking news"
and urgent e-mailings.  

If I have "Today's news" in the subject line on the e-mail it comes out
with "Today\'s news" --- how can I prevent this from happening?  

Ron

------=OPENWEBMAIL_ATT_0.301777760536549--

Re: Form processing

am 12.09.2007 08:49:04 von Goltsios Theodore

I tried this:

$sub = "Today's news";
$to = 'tgol@kinetix.gr';
$body = "test";
?>

mail($to,$sub,$body);

And it seems that it works just fine. If you really want help, you
should post the code that is causing you trouble.

Theodore

ron.php wrote:
> I am trying to set up a form which will send e-mails for "late breaking news"
> and urgent e-mailings.
>
> If I have "Today's news" in the subject line on the e-mail it comes out
> with "Today\'s news" --- how can I prevent this from happening?
>
> Ron
>
>

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Re: Form processing

am 12.09.2007 15:12:38 von robleyd

ron.php wrote:

> I am trying to set up a form which will send e-mails for "late breaking
> news" and urgent e-mailings.
>
> If I have "Today's news" in the subject line on the e-mail it comes out
> with "Today\'s news" --- how can I prevent this from happening?
>
> Ron

Check your magic_quotes_gpc setting, probably on and would be better off. Of
course this may create havoc with database queries if you aren't already
ignoring it and using the appropriate escaping for whatever db you use.



Cheers
--
David Robley

Entropy isn't what it used to be.
Today is Setting Orange, the 36th day of Bureaucracy in the YOLD 3173.

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

RE: Form processing

am 13.09.2007 16:41:29 von Naintara

You could look up the PHP function get_magic_quotes_gpc()

When a form is posted, you could do a check like this:

if ( get_magic_quotes_gpc() ) {
//where $subject contains the subject string and $newsubject is
what you use for the mail
$newsubject =3D stripslashes ($subject);=09
}

This will remove the escape slashes added by the server php settings.
Read magic_quotes_gpc in php reference.

-----Original Message-----
From: ron.php [mailto:ron.php@actsministries.org]=20
Sent: Wednesday, September 12, 2007 7:03 AM
To: php-db@lists.php.net
Subject: [PHP-DB] Form processing

I am trying to set up a form which will send e-mails for "late breaking
news"=20
and urgent e-mailings. =A0

If I have "Today's news" in the subject line on the e-mail it comes out=20
with "Today\'s news" --- how can I prevent this from happening? =A0

Ron =20

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php