subreddit
stringclasses
7 values
author
stringlengths
3
20
id
stringlengths
5
7
content
stringlengths
67
30.4k
score
int64
0
140k
lolphp
funtex666
detupng
<|sols|><|sot|>Test of JSON parsers - PHP's is almost the only one completely correct one.<|eot|><|sol|>http://seriot.ch/json/pruned_results.png<|eol|><|sor|>How is this lol php?<|eor|><|sor|>It's funny that one of the things PHP does correctly is parsing something based on a competing language<|eor|><|sor|>[deleted]<|...
10
lolphp
cfreak2399
dei6c10
<|sols|><|sot|>Test of JSON parsers - PHP's is almost the only one completely correct one.<|eot|><|sol|>http://seriot.ch/json/pruned_results.png<|eol|><|sor|>Ironic that the parser is almost to spec when if you want to use the API properly you have to wrap it in a class that will handle errors properly.<|eor|><|sor|>Lo...
9
lolphp
RedMser
dehxof1
<|sols|><|sot|>Test of JSON parsers - PHP's is almost the only one completely correct one.<|eot|><|sol|>http://seriot.ch/json/pruned_results.png<|eol|><|sor|>Has anyone tried this with .NET?<|eor|><|sor|>The table does have a column for "Json.NET 9.0.1", if that's what you were looking for.<|eor|><|eols|><|endoftext|>
6
lolphp
MorrisonLevi
2v8mbz
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|eoss|><|endoftext|>
74
lolphp
Sarcastinator
cofv5vf
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>You mean to tell me that when you do something stupid, undefined behaviour occurs? Amazing.<|eor|><|...
32
lolphp
allthediamonds
cogg78t
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>You mean to tell me that when you do something stupid, undefined behaviour occurs? Amazing.<|eor|><|...
27
lolphp
gu3st12
cofm5hc
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>You mean to tell me that when you do something stupid, undefined behaviour occurs? Amazing.<|eor|><|...
22
lolphp
FionaSarah
coi1xpp
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>You mean to tell me that when you do something stupid, undefined behaviour occurs? Amazing.<|eor|><|...
20
lolphp
disclosure5
coggm9n
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>You mean to tell me that when you do something stupid, undefined behaviour occurs? Amazing.<|eor|><|...
18
lolphp
allthediamonds
cogfrg3
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>[As per today's PHP discussion](http://codelegance.com/embracing-coercion-in-php/), apparently you sh...
16
lolphp
ioctl79
cogpy5u
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>You mean to tell me that when you do something stupid, undefined behaviour occurs? Amazing.<|eor|><|...
12
lolphp
disclosure5
cofpwp5
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>[As per today's PHP discussion](http://codelegance.com/embracing-coercion-in-php/), apparently you sh...
10
lolphp
ahruss
cog48h2
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>You mean to tell me that when you do something stupid, undefined behaviour occurs? Amazing.<|eor|><|...
10
lolphp
nick_
cor9clr
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>[As per today's PHP discussion](http://codelegance.com/embracing-coercion-in-php/), apparently you sh...
8
lolphp
MorrisonLevi
cogh2z4
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>You mean to tell me that when you do something stupid, undefined behaviour occurs? Amazing.<|eor|><|...
8
lolphp
MorrisonLevi
coggu8p
<|soss|><|sot|>TIL you can use unset as a cast.<|eot|><|sost|> $apple = "apple"; var_dump((unset) $apple); // NULL var_dump($apple); // still "apple" Thank you for this excellent feature, PHP.<|eost|><|sor|>Typecasting never changes the actual value, so I don't know why this is a lolphp. Is it funny just be...
6
lolphp
SaraMG
5zgur6
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|eols|><|endoftext|>
73
lolphp
SaraMG
dexzzq4
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|soopr|>The result for PHP 7 is particularly lol-worthy.<|eoopr|><|eols|><|endoftext|>
37
lolphp
madsohm
deyarew
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|sor|>For people who don't want to look at bit flipping and stuff, here's a string version: https://3v4l.org/sXiiL<|eor|><|eols|><|endoftext|>
29
lolphp
SaraMG
dey1kg0
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|soopr|>PHP is all about having options: https://3v4l.org/eVLvX https://3v4l.org/n2hnu <|eoopr|><|eols|><|endoftext|>
14
lolphp
Perdouille
dezyyxo
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|sor|>For people who don't want to look at bit flipping and stuff, here's a string version: https://3v4l.org/sXiiL<|eor|><|sor|>BarABarC is the only thing that makes...
12
lolphp
jesseschalken
dey9fsq
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|sor|>Good find. Once again HHVM does the sane thing. (`self` always refers to the class the code is written in, `static` refers to the concrete runtime class.)<|eor...
10
lolphp
edave64
deygdbr
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|sor|>Good find. Once again HHVM does the sane thing. (`self` always refers to the class the code is written in, `static` refers to the concrete runtime class.)<|eor...
10
lolphp
ZiggyTheHamster
dez4ria
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|sor|>For people who don't want to look at bit flipping and stuff, here's a string version: https://3v4l.org/sXiiL<|eor|><|sor|>BarABarC is the only thing that makes...
9
lolphp
bj_christianson
deyncie
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|sor|>Good find. Once again HHVM does the sane thing. (`self` always refers to the class the code is written in, `static` refers to the concrete runtime class.)<|eor...
7
lolphp
edave64
deypg8u
<|sols|><|sot|>Q. Does 'self::SOME_CONST' refer to the current class, or potentially a subclass? A: It depends.<|eot|><|sol|>https://3v4l.org/vUHq3<|eol|><|sor|>Good find. Once again HHVM does the sane thing. (`self` always refers to the class the code is written in, `static` refers to the concrete runtime class.)<|eor...
6
lolphp
pacotes
3nka8j
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|eols|><|endoftext|>
73
lolphp
AngularSpecter
cvovfsn
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>is escapeshellargs not good enough for that?<|eor|><|soopr|>escapeshellargs has had several bypasses in the past (as recent...
47
lolphp
user0x29a
cvp3zjm
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>i wonder how many people expect a python project when they read pydio<|eor|><|eols|><|endoftext|>
40
lolphp
pacotes
cvotmta
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>is escapeshellargs not good enough for that?<|eor|><|soopr|>escapeshellargs has had several bypasses in the past (as recent...
36
lolphp
jadkik94
cvp7jb0
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>i wonder how many people expect a python project when they read pydio<|eor|><|sor|>I expect a python script that plays Dio ...
29
lolphp
YouBecame
cvoyqht
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>I read the method name as "escapes hell args. "<|eor|><|eols|><|endoftext|>
25
lolphp
iheartrms
cvp4ax6
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>is escapeshellargs not good enough for that?<|eor|><|soopr|>escapeshellargs has had several bypasses in the past (as recent...
23
lolphp
pacotes
cvp6xml
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>The scary thing is that before this commit there was no escape at all.<|eor|><|soopr|>****bingo**** The rest of the projec...
22
lolphp
yrro
cvp3xw9
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>is escapeshellargs not good enough for that?<|eor|><|soopr|>escapeshellargs has had several bypasses in the past (as recent...
21
lolphp
iheartrms
cvp4bgw
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>i wonder how many people expect a python project when they read pydio<|eor|><|sor|>I sure did. <|eor|><|eols|><|endoftext|>
20
lolphp
tdammers
cvp8jen
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>is escapeshellargs not good enough for that?<|eor|><|sor|>`escapeshellargs` is fundamentally wrong because there is absolut...
19
lolphp
masklinn
cvqdl65
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>So now we're just posting any shitty code we find to this sub? /r/badcode<|eor|><|sor|>Well, the fact that PHP has no port...
16
lolphp
dotted
cvpesxd
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>is escapeshellargs not good enough for that?<|eor|><|soopr|>escapeshellargs has had several bypasses in the past (as recent...
15
lolphp
tdammers
cvp8kbk
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>And let's not forget that this requires **passwordless sudo**, which is *never* a good idea for systems storing anything wo...
14
lolphp
00Davo
cvpwufq
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>So now we're just posting any shitty code we find to this sub? /r/badcode<|eor|><|sor|>Well, the fact that PHP has no port...
14
lolphp
user0x29a
cvp7d4w
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>The scary thing is that before this commit there was no escape at all.<|eor|><|soopr|>****bingo**** The rest of the projec...
14
lolphp
luchs
cvq3okt
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>is escapeshellargs not good enough for that?<|eor|><|soopr|>escapeshellargs has had several bypasses in the past (as recent...
14
lolphp
LinkXXI
cvoutmf
<|sols|><|sot|>Why yes, lets do `sudo mount` in PHP and hope escapeshellargs saves us!<|eot|><|sol|>https://github.com/pydio/pydio-core/commit/2049254e7a215491019d2646a274a8fb1cf29e3b<|eol|><|sor|>is escapeshellargs not good enough for that?<|eor|><|soopr|>escapeshellargs has had several bypasses in the past (as recent...
11
lolphp
Muchoz
2dokyy
<|sols|><|sot|>[X-Post ProgrammerHumor] How to generate a random string<|eot|><|sol|>http://i.imgur.com/RwJ0kJB.png<|eol|><|eols|><|endoftext|>
74
lolphp
TheCockBottler
cjrte1c
<|sols|><|sot|>[X-Post ProgrammerHumor] How to generate a random string<|eot|><|sol|>http://i.imgur.com/RwJ0kJB.png<|eol|><|sor|>I thought we all agreed that you only get real entropy when putting a first year CS Student in front of VIM and tell him to close it?<|eor|><|sor|>Isn't that classified as a form of cruel and...
20
lolphp
Varriount
cjrshob
<|sols|><|sot|>[X-Post ProgrammerHumor] How to generate a random string<|eot|><|sol|>http://i.imgur.com/RwJ0kJB.png<|eol|><|sor|>I thought we all agreed that you only get real entropy when putting a first year CS Student in front of VIM and tell him to close it?<|eor|><|sor|>Isn't that classified as a form of cruel and...
17
lolphp
fnzp
cjszp9z
<|sols|><|sot|>[X-Post ProgrammerHumor] How to generate a random string<|eot|><|sol|>http://i.imgur.com/RwJ0kJB.png<|eol|><|sor|>I thought we all agreed that you only get real entropy when putting a first year CS Student in front of VIM and tell him to close it?<|eor|><|sor|>Hah, the average fourth year CS student at m...
8
lolphp
Banane9
cjt5dbj
<|sols|><|sot|>[X-Post ProgrammerHumor] How to generate a random string<|eot|><|sol|>http://i.imgur.com/RwJ0kJB.png<|eol|><|sor|>I thought we all agreed that you only get real entropy when putting a first year CS Student in front of VIM and tell him to close it?<|eor|><|sor|>Hah, the average fourth year CS student at m...
7
lolphp
aenigmaclamo
cjrwdiq
<|sols|><|sot|>[X-Post ProgrammerHumor] How to generate a random string<|eot|><|sol|>http://i.imgur.com/RwJ0kJB.png<|eol|><|sor|>I thought we all agreed that you only get real entropy when putting a first year CS Student in front of VIM and tell him to close it?<|eor|><|sor|>Hah, the average fourth year CS student at m...
6
lolphp
allthediamonds
29s2it
<|sols|><|sot|>DateTimeImmutable::modify<|eot|><|sol|>http://www.php.net/manual/en/datetimeimmutable.modify.php<|eol|><|eols|><|endoftext|>
71
lolphp
despens
cio070w
<|sols|><|sot|>DateTimeImmutable::modify<|eot|><|sol|>http://www.php.net/manual/en/datetimeimmutable.modify.php<|eol|><|sor|>Seemingly misleading documentation, everything is fine though. This does not modify the object, but returns a modified object.<|eor|><|sor|>On a php level of expectations this is fine, but there ...
35
lolphp
wung
ciny3vv
<|sols|><|sot|>DateTimeImmutable::modify<|eot|><|sol|>http://www.php.net/manual/en/datetimeimmutable.modify.php<|eol|><|sor|>Seemingly misleading documentation, everything is fine though. This does not modify the object, but returns a modified object.<|eor|><|eols|><|endoftext|>
18
lolphp
ismtrn
cioa86n
<|sols|><|sot|>DateTimeImmutable::modify<|eot|><|sol|>http://www.php.net/manual/en/datetimeimmutable.modify.php<|eol|><|sor|>Seemingly misleading documentation, everything is fine though. This does not modify the object, but returns a modified object.<|eor|><|sor|>> Seemingly misleading... > DateTimeImmutable::modify...
9
lolphp
startwearinggreen
ciourf4
<|sols|><|sot|>DateTimeImmutable::modify<|eot|><|sol|>http://www.php.net/manual/en/datetimeimmutable.modify.php<|eol|><|sor|>Seemingly misleading documentation, everything is fine though. This does not modify the object, but returns a modified object.<|eor|><|sor|>On a php level of expectations this is fine, but there ...
5
lolphp
jtickle
1gnoa5
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
74
lolphp
epsy
cam4uw5
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
47
lolphp
grafilicious
cam3grf
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
31
lolphp
Denommus
cam6khe
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
20
lolphp
vytah
cam6isa
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
19
lolphp
Jonno_FTW
cammsqd
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
13
lolphp
BufferUnderpants
cam48iy
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
12
lolphp
BufferUnderpants
cam46l5
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
10
lolphp
wbkang
cam369h
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
9
lolphp
BufferUnderpants
cam6vfg
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
9
lolphp
metamorphosis
camiegh
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
7
lolphp
Kwpolska
camt72x
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
7
lolphp
Porges
car7o1w
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
6
lolphp
Denommus
cam4kim
<|soss|><|sot|>Functional Map() and Reduce() in php 5.3!!!<|eot|><|sost|>I know 5.3 has been around for awhile but until fairly recently, we targeted 5.1 for a wider audience. I'll skip my usual rant about introducing major language features on a minor version number and skip directly to this absurdity: array arr...
5
lolphp
Sgoettschkes
c05jn4
<|sols|><|sot|>The only language going against the versioning of bcrypt<|eot|><|sol|>https://i.redd.it/t2ws949ng4431.png<|eol|><|eols|><|endoftext|>
73
lolphp
Sgoettschkes
er1fs6h
<|sols|><|sot|>The only language going against the versioning of bcrypt<|eot|><|sol|>https://i.redd.it/t2ws949ng4431.png<|eol|><|soopr|>I was trying to use bcrypt hashed passwords from our PHP application in another application reading directly from the database. Turns out half the passwords are in the correct format (...
25
lolphp
Miserable_Fuck
er2y1zo
<|sols|><|sot|>The only language going against the versioning of bcrypt<|eot|><|sol|>https://i.redd.it/t2ws949ng4431.png<|eol|><|sor|># <|eor|><|eols|><|endoftext|>
5
lolphp
MMauro94
4sgcmj
<|sols|><|sot|>On SERIOUSLY malformed URLs, parse_url() MAY return false<|eot|><|sol|>https://i.redd.it/xu4vqtpcbs8x.png<|eol|><|eols|><|endoftext|>
71
lolphp
roodammy44
d596bjm
<|sols|><|sot|>On SERIOUSLY malformed URLs, parse_url() MAY return false<|eot|><|sol|>https://i.redd.it/xu4vqtpcbs8x.png<|eol|><|sor|>I think the lol here is the documentation. It doesn't tell you in any way what seriously malformed is, or why it "may" return false (or put another way - may return true!)<|eor|><|eols|>...
35
lolphp
Liorithiel
d597j1y
<|sols|><|sot|>On SERIOUSLY malformed URLs, parse_url() MAY return false<|eot|><|sol|>https://i.redd.it/xu4vqtpcbs8x.png<|eol|><|sor|>That looks funny at first, but it's actually implementation of robustness principle "Be conservative in what you send, be liberal in what you accept". As long as the URL can be parsed, e...
19
lolphp
olsner
d59j1so
<|sols|><|sot|>On SERIOUSLY malformed URLs, parse_url() MAY return false<|eot|><|sol|>https://i.redd.it/xu4vqtpcbs8x.png<|eol|><|sor|>Anybody have an example of a "seriously malformed URL"?<|eor|><|sor|>[deleted]<|eor|><|sor|>I'd say "host:65536" is only a bit malformed.<|eor|><|sor|>[deleted]<|eor|><|sor|>No it's just...
17
lolphp
maweki
d59alrc
<|sols|><|sot|>On SERIOUSLY malformed URLs, parse_url() MAY return false<|eot|><|sol|>https://i.redd.it/xu4vqtpcbs8x.png<|eol|><|sor|>Anybody have an example of a "seriously malformed URL"?<|eor|><|sor|>[deleted]<|eor|><|sor|>I'd say "host:65536" is only a bit malformed.<|eor|><|eols|><|endoftext|>
11
lolphp
miggyb
d595g5o
<|sols|><|sot|>On SERIOUSLY malformed URLs, parse_url() MAY return false<|eot|><|sol|>https://i.redd.it/xu4vqtpcbs8x.png<|eol|><|sor|>Better than returning `TRUE` I guess<|eor|><|eols|><|endoftext|>
10
lolphp
perk11
d5958pw
<|sols|><|sot|>On SERIOUSLY malformed URLs, parse_url() MAY return false<|eot|><|sol|>https://i.redd.it/xu4vqtpcbs8x.png<|eol|><|sor|>That looks funny at first, but it's actually implementation of robustness principle "Be conservative in what you send, be liberal in what you accept". As long as the URL can be parsed, e...
10
lolphp
bart2019
d5aaq8k
<|sols|><|sot|>On SERIOUSLY malformed URLs, parse_url() MAY return false<|eot|><|sol|>https://i.redd.it/xu4vqtpcbs8x.png<|eol|><|sor|>I think the lol here is the documentation. It doesn't tell you in any way what seriously malformed is, or why it "may" return false (or put another way - may return true!)<|eor|><|sor|>N...
5
lolphp
nickguletskii200
3wjzqp
<|sols|><|sot|>200 OK: Internal server error!<|eot|><|sol|>https://bugs.php.net/bug.php?id=50921<|eol|><|eols|><|endoftext|>
72
lolphp
edave64
cxwsv7b
<|sols|><|sot|>200 OK: Internal server error!<|eot|><|sol|>https://bugs.php.net/bug.php?id=50921<|eol|><|sor|>> it turned out that we added the explicit display_errors check for not setting the http 500 response code because Internet Explore will show a custom error page for non-2xx responses if the length of the respo...
54
lolphp
ThisIsADogHello
cxwzbaa
<|sols|><|sot|>200 OK: Internal server error!<|eot|><|sol|>https://bugs.php.net/bug.php?id=50921<|eol|><|sor|>> it turned out that we added the explicit display_errors check for not setting the http 500 response code because Internet Explore will show a custom error page for non-2xx responses if the length of the respo...
33
lolphp
milordi
cxwsju6
<|sols|><|sot|>200 OK: Internal server error!<|eot|><|sol|>https://bugs.php.net/bug.php?id=50921<|eol|><|sor|>>Status: Not a bug Classic. Sadly, they finally reopened it.<|eor|><|eols|><|endoftext|>
31
lolphp
stfarn
cxxee3r
<|sols|><|sot|>200 OK: Internal server error!<|eot|><|sol|>https://bugs.php.net/bug.php?id=50921<|eol|><|sor|>"i'm afraid we can't do much about this" This stuff is gold<|eor|><|eols|><|endoftext|>
15
lolphp
maweki
cxwxjjb
<|sols|><|sot|>200 OK: Internal server error!<|eot|><|sol|>https://bugs.php.net/bug.php?id=50921<|eol|><|sor|>Who thought it would be a good idea for the client scripts to have unbuffered access to the socket, negating any chance to set a different status code after writing the first byte?<|eor|><|eols|><|endoftext|>
12
lolphp
myhf
cxxcgok
<|sols|><|sot|>200 OK: Internal server error!<|eot|><|sol|>https://bugs.php.net/bug.php?id=50921<|eol|><|sor|>Who thought it would be a good idea for the client scripts to have unbuffered access to the socket, negating any chance to set a different status code after writing the first byte?<|eor|><|sor|>The ability to s...
8
lolphp
cbraga
cxx4sbf
<|sols|><|sot|>200 OK: Internal server error!<|eot|><|sol|>https://bugs.php.net/bug.php?id=50921<|eol|><|sor|>Who thought it would be a good idea for the client scripts to have unbuffered access to the socket, negating any chance to set a different status code after writing the first byte?<|eor|><|sor|>TBH if the clien...
6
lolphp
ayanami_rei
26spvj
<|sols|><|sot|>Cutesy PHP mascot (Be very afraid)<|eot|><|sol|>http://imgur.com/1NowUfu<|eol|><|eols|><|endoftext|>
73
lolphp
iftpadfs
chua7vo
<|sols|><|sot|>Cutesy PHP mascot (Be very afraid)<|eot|><|sol|>http://imgur.com/1NowUfu<|eol|><|sor|>[Factual representation of PHP](http://next.rikunabi.com/tech/contents/ts_report/img/201312/002412/part5_img.jpg)<|eor|><|eols|><|endoftext|>
27
lolphp
Takeoded
ciu3wq
<|sols|><|sot|>get_current_user(): get the on-disk script file's owner, regardless of what user is actually executing the script.<|eot|><|sol|>https://www.php.net/manual/en/function.get-current-user.php<|eol|><|eols|><|endoftext|>
70
lolphp
vytah
ev9hy1h
<|sols|><|sot|>get_current_user(): get the on-disk script file's owner, regardless of what user is actually executing the script.<|eot|><|sol|>https://www.php.net/manual/en/function.get-current-user.php<|eol|><|soopr|>... someone should make a bugreport about the function name being very, very, very wrong.<|eoopr|><|so...
30
lolphp
dotancohen
ev9e3uo
<|sols|><|sot|>get_current_user(): get the on-disk script file's owner, regardless of what user is actually executing the script.<|eot|><|sol|>https://www.php.net/manual/en/function.get-current-user.php<|eol|><|sor|>I've seen this function used instead of [wp_get_current_user()](https://codex.wordpress.org/wp_get_curre...
22
lolphp
Takeoded
ev962yu
<|sols|><|sot|>get_current_user(): get the on-disk script file's owner, regardless of what user is actually executing the script.<|eot|><|sol|>https://www.php.net/manual/en/function.get-current-user.php<|eol|><|soopr|>... someone should make a bugreport about the function name being very, very, very wrong.<|eoopr|><|eo...
15
lolphp
kmark937
evadwou
<|sols|><|sot|>get_current_user(): get the on-disk script file's owner, regardless of what user is actually executing the script.<|eot|><|sol|>https://www.php.net/manual/en/function.get-current-user.php<|eol|><|sor|>This isn't a LOL: it's very common to have a single process for Apache running in a shared hosting envir...
12
lolphp
Altreus
40se6f
<|sols|><|sot|>Today someone said "PHP7 <3" - which is true. PHP thinks 7 < 3<|eot|><|sol|>https://3v4l.org/N5hXC<|eol|><|eols|><|endoftext|>
71
lolphp
Rhomboid
cywok3d
<|sols|><|sot|>Today someone said "PHP7 <3" - which is true. PHP thinks 7 < 3<|eot|><|sol|>https://3v4l.org/N5hXC<|eol|><|sor|>That's not a lolphp. It's a misunderstanding of how NaN works and the requirement for a strict weak ordering. Comparing anything to NaN results in false. The sort algorithm is going to ask "...
74
lolphp
squiggleslash
cywoswp
<|sols|><|sot|>Today someone said "PHP7 <3" - which is true. PHP thinks 7 < 3<|eot|><|sol|>https://3v4l.org/N5hXC<|eol|><|sor|>That's not a lolphp. It's a misunderstanding of how NaN works and the requirement for a strict weak ordering. Comparing anything to NaN results in false. The sort algorithm is going to ask "...
30
lolphp
Rhomboid
cywpa5j
<|sols|><|sot|>Today someone said "PHP7 <3" - which is true. PHP thinks 7 < 3<|eot|><|sol|>https://3v4l.org/N5hXC<|eol|><|sor|>That's not a lolphp. It's a misunderstanding of how NaN works and the requirement for a strict weak ordering. Comparing anything to NaN results in false. The sort algorithm is going to ask "...
29
lolphp
Altreus
cyxsglu
<|sols|><|sot|>Today someone said "PHP7 <3" - which is true. PHP thinks 7 < 3<|eot|><|sol|>https://3v4l.org/N5hXC<|eol|><|sor|>That's not a lolphp. It's a misunderstanding of how NaN works and the requirement for a strict weak ordering. Comparing anything to NaN results in false. The sort algorithm is going to ask "...
18