\r\n in data breaks php
| From: | Marc Fromm | Date: | Thu, 27 Mar 2014 20:58:24 +0000 |
| Subject: | \r\n in data breaks php | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-323115@lists.php.net to get a copy of this message | ||
Server1:
CENTOS 6.4
Postgresql-8.4
PHP 5.3
Server2:
RHEL 5.2
Postgresql-8.1
PHP 5.1
Bother servers serve the same php pages that connect to a postgresql database. Both servers have
magic quotes turned off.
I have a problem with carriage returns in the database. They are stored fine but when selected in a
query there is a problem. The twist is the problem only happens on the server2. Any record with a
carriage return, when selected by a php page, does not display any of the fields values in the form
that the data should populate. All the boxes are empty. If I manually remove the carriage returns
through phpPgAdmin then the form does display all the field data.
Since the same code works on server1 but not on sever2, I must assume the problem is a configuration
issue. Not sure if it's with PHP or postgresql.
Any insight is most welcomed.
Marc