Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
tszming
on Dec 25, 2012
|
parent
|
context
|
favorite
| on:
Python alternatives for PHP functions
Not disagreeing what you said, but your quoted example of Python implementation of `nl2br` is wrong, the original PHP's implementation did handle all (\r\n, \n\r, \n and \r), see:
http://php.net/manual/en/function.nl2br.php
&
http://phpjs.org/functions/nl2br/
carbocation
on Dec 25, 2012
[–]
Here's what's going on behind the scenes in PHP:
https://gist.github.com/4372596
(Taken from
https://github.com/php/php-src/blob/PHP-5.4.9/ext/standard/s...
)
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: