php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #2904 nl2br malfunction
Submitted: 1999-12-03 10:16 UTC Modified: 1999-12-03 22:02 UTC
From: nicolai at dailyrush dot dk Assigned:
Status: Closed Package: Scripting Engine problem
PHP Version: 4.0 Beta 3 OS: FreeBSD3.1
Private report: No CVE-ID: None
 [1999-12-03 10:16 UTC] nicolai at dailyrush dot dk
The nl2br function doens't work correctly.

It seems it mistreats the _'_ sign

ex: 

$text = "It's not working";
$string = nl2br($text);

result: 

$string = 'It\'s not working";

Same problem with

$string = ereg_replace("\n","<BR>",$text);

Running FreeBSD3.1, Apache 1.3.9, PHP4b3, with-mysql, with-imap.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-12-03 22:02 UTC] rasmus at cvs dot php dot net
I can't duplicate this.  I am sure you are passing this from one page to another with escape_magic_quotes enabled.

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed May 15 19:01:34 2024 UTC