php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #12812 nl2br, get_html_translation_table and strtr
Submitted: 2001-08-17 10:10 UTC Modified: 2001-08-19 17:29 UTC
From: kapp at bigping dot de Assigned:
Status: Not a bug Package: Feature/Change Request
PHP Version: 4.0.6 OS: Linux (SuSE Based)
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: kapp at bigping dot de
New email:
PHP Version: OS:

 

 [2001-08-17 10:10 UTC] kapp at bigping dot de
since php 4.0.5 with

nl2br I get an XHTML1.0 compatible <br /> tag back.

So far so good, but if I have to translate it back with strtr (and get_html_translation_table) it won't be recognized.

No problem, I know the workaround (adding a '"<br />" => "\n"' to the translation array) but it would be nice to be fixed.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-08-17 10:11 UTC] derick@php.net
Making this a feature request
 [2001-08-19 07:11 UTC] kapp at bigping dot de
was my fault, sorry!
 [2001-08-19 14:40 UTC] sniper@php.net
user error.
 [2001-08-19 17:29 UTC] jeroen@php.net
"was my fault" referred to wrong type.

Anyway, html_translation_table is about entities (things like &something;), and not about html-tags. 

nl2br has nothing to with html_trans_table.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Jan 15 14:01:30 2025 UTC