subreddit stringclasses 7
values | author stringlengths 3 20 | id stringlengths 5 7 | content stringlengths 67 30.4k | score int64 0 140k |
|---|---|---|---|---|
lolphp | shitcanz | decv62y | <|sols|><|sot|>Unlike existing PECL libsodium module which uses \Sodium namespace, functions will be renamed to sodium_* for inclusion in 7.2<|eot|><|sol|>https://wiki.php.net/rfc/libsodium<|eol|><|sor|>They finally clean up some of their shit naming, so that's pretty good.
And this is one place where PHP is way ahead... | 8 |
lolphp | greenthumble | deb782c | <|sols|><|sot|>Unlike existing PECL libsodium module which uses \Sodium namespace, functions will be renamed to sodium_* for inclusion in 7.2<|eot|><|sol|>https://wiki.php.net/rfc/libsodium<|eol|><|sor|>To be fair, PHP namespaces are fucking ugly.<|eor|><|sor|>'\' was probably the only free token they could use, since ... | 6 |
lolphp | yxpow | deb7zs0 | <|sols|><|sot|>Unlike existing PECL libsodium module which uses \Sodium namespace, functions will be renamed to sodium_* for inclusion in 7.2<|eot|><|sol|>https://wiki.php.net/rfc/libsodium<|eol|><|sor|>To be fair, PHP namespaces are fucking ugly.<|eor|><|sor|>'\' was probably the only free token they could use, since ... | 5 |
lolphp | n0t0ri0us9 | 5mwwld | <|sols|><|sot|>TIL: Strict types aren't working in PHP7.0 for generators /r/PHP<|eot|><|sol|>https://www.reddit.com/r/PHP/comments/5mtpr0/til_strict_types_arent_working_in_php70_for/<|eol|><|eols|><|endoftext|> | 38 |
lolphp | n0t0ri0us9 | dc6y6yf | <|sols|><|sot|>TIL: Strict types aren't working in PHP7.0 for generators /r/PHP<|eot|><|sol|>https://www.reddit.com/r/PHP/comments/5mtpr0/til_strict_types_arent_working_in_php70_for/<|eol|><|soopr|>The funniest part is the the the poor souls question "Is this behavior documented somewhere?" is completely ignored by th... | 20 |
lolphp | pilif | dc6yn75 | <|sols|><|sot|>TIL: Strict types aren't working in PHP7.0 for generators /r/PHP<|eot|><|sol|>https://www.reddit.com/r/PHP/comments/5mtpr0/til_strict_types_arent_working_in_php70_for/<|eol|><|sor|>PHP has enough warts that aren't being fixed because of backwards compatibility or plain questionable opinions.
Let's not... | 19 |
lolphp | n0t0ri0us9 | dc732qt | <|sols|><|sot|>TIL: Strict types aren't working in PHP7.0 for generators /r/PHP<|eot|><|sol|>https://www.reddit.com/r/PHP/comments/5mtpr0/til_strict_types_arent_working_in_php70_for/<|eol|><|sor|>PHP has enough warts that aren't being fixed because of backwards compatibility or plain questionable opinions.
Let's not... | 18 |
lolphp | 00Davo | 40on3p | <|sols|><|sot|>The order of interfaces in an implements clause is meaningful.<|eot|><|sol|>https://3v4l.org/0gFa6<|eol|><|eols|><|endoftext|> | 37 |
lolphp | cliath | cyvzbii | <|sols|><|sot|>The order of interfaces in an implements clause is meaningful.<|eot|><|sol|>https://3v4l.org/0gFa6<|eol|><|sor|>Only applies if you implement a derived class and its base class, the base class must go first. Not sure how I feel about this...<|eor|><|eols|><|endoftext|> | 15 |
lolphp | OneWingedShark | cyvvzwh | <|sols|><|sot|>The order of interfaces in an implements clause is meaningful.<|eot|><|sol|>https://3v4l.org/0gFa6<|eol|><|sor|>...that's crazy.<|eor|><|eols|><|endoftext|> | 14 |
lolphp | 00Davo | cywffiy | <|sols|><|sot|>The order of interfaces in an implements clause is meaningful.<|eot|><|sol|>https://3v4l.org/0gFa6<|eol|><|sor|>Only applies if you implement a derived class and its base class, the base class must go first. Not sure how I feel about this...<|eor|><|sor|>I'm not sure what the use case is. I mean, you're ... | 12 |
lolphp | Danack | cywk11l | <|sols|><|sot|>The order of interfaces in an implements clause is meaningful.<|eot|><|sol|>https://3v4l.org/0gFa6<|eol|><|sor|>Reported - https://bugs.php.net/bug.php?id=71358
btw there are some other *cough* edge-cases related to "implements":
* https://bugs.php.net/bug.php?id=69317
* https://bugs.php.net/bug.php?id... | 9 |
lolphp | xrogaan | cywk73l | <|sols|><|sot|>The order of interfaces in an implements clause is meaningful.<|eot|><|sol|>https://3v4l.org/0gFa6<|eol|><|sor|>Reported - https://bugs.php.net/bug.php?id=71358
btw there are some other *cough* edge-cases related to "implements":
* https://bugs.php.net/bug.php?id=69317
* https://bugs.php.net/bug.php?id... | 6 |
lolphp | emilvikstrom | cywg5lo | <|sols|><|sot|>The order of interfaces in an implements clause is meaningful.<|eot|><|sol|>https://3v4l.org/0gFa6<|eol|><|sor|>Only applies if you implement a derived class and its base class, the base class must go first. Not sure how I feel about this...<|eor|><|sor|>I'm not sure what the use case is. I mean, you're ... | 6 |
lolphp | arturaz | 3j775k | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|eoss|><|endoftext|> | 36 |
lolphp | loptr | cun2kub | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>So now every single bug in PHP and related libraries/functionality ... | 25 |
lolphp | BufferUnderpants | cun8htd | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>So now every single bug in PHP and related libraries/functionality ... | 21 |
lolphp | mort96 | cumw6v3 | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>It's not a bug, it's a feature!
Seriously, why are PHP bugs consid... | 15 |
lolphp | cbraga | cunk37o | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>So now every single bug in PHP and related libraries/functionality ... | 15 |
lolphp | Miserable_Fuck | cunh2qa | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>So now every single bug in PHP and related libraries/functionality ... | 14 |
lolphp | Sheepshow | cune4fb | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>So now every single bug in PHP and related libraries/functionality ... | 10 |
lolphp | ozamosi | cunhamf | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>So now every single bug in PHP and related libraries/functionality ... | 7 |
lolphp | thelordofcheese | cumxk68 | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>It's not a bug, it's a feature!
Seriously, why are PHP bugs consid... | 7 |
lolphp | mort96 | cumwnzg | <|soss|><|sot|>When you try to connect to a Postgresql database with a password containing 1 or more spaces, pdo will fail to connect<|eot|><|sost|>http://stackoverflow.com/questions/13329787/pdo-cannot-connect-if-password-contains-spaces<|eost|><|sor|>It's not a bug, it's a feature!
Seriously, why are PHP bugs consid... | 7 |
lolphp | svens_ | 2ktgh2 | <|sols|><|sot|>PHP Type Coercion at it again. Be careful when comparing hashes. [x-post]<|eot|><|sol|>https://eval.in/108854<|eol|><|eols|><|endoftext|> | 39 |
lolphp | Banane9 | clomr9v | <|sols|><|sot|>PHP Type Coercion at it again. Be careful when comparing hashes. [x-post]<|eot|><|sol|>https://eval.in/108854<|eol|><|sor|>I think it's funny how they try to explain this shit by saying "oh it's in the documentation".
Any beginner would fall for this, unless anyone tells them to always use ===<|eor|><|e... | 15 |
lolphp | ismtrn | clolbea | <|sols|><|sot|>PHP Type Coercion at it again. Be careful when comparing hashes. [x-post]<|eot|><|sol|>https://eval.in/108854<|eol|><|sor|>Why on earth would be convert two strings to numbers to compare them? WHY? It is especially fucked up when your mapping into numbers isn't even injective.<|eor|><|eols|><|endoftext|> | 15 |
lolphp | svens_ | cloj5uu | <|sols|><|sot|>PHP Type Coercion at it again. Be careful when comparing hashes. [x-post]<|eot|><|sol|>https://eval.in/108854<|eol|><|soopr|>[Here's](http://www.reddit.com/r/PHP/comments/2krumr/what_in_gods_name_is_going_on_here/) the discussion on /r/php, for those of you who don't subscribe to it.<|eoopr|><|eols|><|en... | 11 |
lolphp | ThisIsADogHello | clpded6 | <|sols|><|sot|>PHP Type Coercion at it again. Be careful when comparing hashes. [x-post]<|eot|><|sol|>https://eval.in/108854<|eol|><|soopr|>[Here's](http://www.reddit.com/r/PHP/comments/2krumr/what_in_gods_name_is_going_on_here/) the discussion on /r/php, for those of you who don't subscribe to it.<|eoopr|><|sor|>Good ... | 6 |
lolphp | Gnolfo | clp79ey | <|sols|><|sot|>PHP Type Coercion at it again. Be careful when comparing hashes. [x-post]<|eot|><|sol|>https://eval.in/108854<|eol|><|sor|>Why on earth would be convert two strings to numbers to compare them? WHY? It is especially fucked up when your mapping into numbers isn't even injective.<|eor|><|sor|>[deleted]<|eor... | 5 |
lolphp | DoubleNabla | 2hgz0t | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|eols|><|endoftext|> | 33 |
lolphp | Various_Pickles | cksn4l7 | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|sor|> mysql_our_timestamps_didnt_have_timezones_... | 21 |
lolphp | pilif | ckt5waq | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|sor|>The real WTF is MySQL:
> An alternative is `u... | 14 |
lolphp | DoubleNabla | cksjy2p | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|soopr|>Found in /r/php (https://www.reddit.com/r/PH... | 11 |
lolphp | cythrawll | cksx7cq | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|sor|>to be fair they aren't talking about the PHP `... | 11 |
lolphp | poizan42 | ckueah5 | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|sor|>The real WTF is MySQL:
> An alternative is `u... | 10 |
lolphp | Various_Pickles | cktrhm8 | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|sor|> mysql_our_timestamps_didnt_have_timezones_... | 6 |
lolphp | frezik | cl1ucma | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|sor|>to be fair they aren't talking about the PHP `... | 6 |
lolphp | DoubleNabla | cktib9y | <|sols|><|sot|>PDO emulates prepared statements using mysql_real_escape_string(), which does a great job as you'd expect...<|eot|><|sol|>http://stackoverflow.com/questions/134099/are-pdo-prepared-statements-sufficient-to-prevent-sql-injection/12202218#12202218<|eol|><|sor|>On a sidenote. Can anybody explain why setting... | 5 |
lolphp | allthediamonds | 2ettnx | <|sols|><|sot|>The joys of using `array_intersect`<|eot|><|sol|>https://eval.in/184830<|eol|><|eols|><|endoftext|> | 35 |
lolphp | allthediamonds | ck2u88w | <|sols|><|sot|>The joys of using `array_intersect`<|eot|><|sol|>https://eval.in/184830<|eol|><|soopr|>For some goddamn reason, `array_intersect` compares values by strict equality of those values *when casted to string*.<|eoopr|><|eols|><|endoftext|> | 18 |
lolphp | andsens | ck2wgpy | <|sols|><|sot|>The joys of using `array_intersect`<|eot|><|sol|>https://eval.in/184830<|eol|><|soopr|>For some goddamn reason, `array_intersect` compares values by strict equality of those values *when casted to string*.<|eoopr|><|sor|>Heh, yeah. I stumbled upon that fuck-up as well about a month ago. We wound using [U... | 6 |
lolphp | allthediamonds | ck3m3rl | <|sols|><|sot|>The joys of using `array_intersect`<|eot|><|sol|>https://eval.in/184830<|eol|><|soopr|>For some goddamn reason, `array_intersect` compares values by strict equality of those values *when casted to string*.<|eoopr|><|sor|>[deleted]<|eor|><|soopr|>Yep, just like with everything else, there are workarounds.... | 6 |
lolphp | TortoiseWrath | 2bdolv | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|eols|><|endoftext|> | 36 |
lolphp | nikic | cj4n0sn | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>Note: PHP has always had [variadic functions](http://php.net/func_get_args), this is just a more convenient and clear way to implement... | 21 |
lolphp | ajmarks | cj4bcl5 | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>But they still don't have named arguments (because Rasmatazz thinks they're ugly or something), so you can't use variadic features unl... | 12 |
lolphp | h0rst_ | cj4nla3 | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>But they still don't have named arguments (because Rasmatazz thinks they're ugly or something), so you can't use variadic features unl... | 11 |
lolphp | ajmarks | cj4udep | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>What's the use of variadic functions?<|eor|><|sor|>In Python, I use them all the time as wrappers. For example, consider this:
d... | 11 |
lolphp | ajmarks | cj4o6s1 | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>But they still don't have named arguments (because Rasmatazz thinks they're ugly or something), so you can't use variadic features unl... | 8 |
lolphp | infinull | cj4u22h | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>What's the use of variadic functions?<|eor|><|sor|>In Python, I use them all the time as wrappers. For example, consider this:
d... | 8 |
lolphp | Sarcastinator | cj4btj8 | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>Constants can't be expressions?!
lol php.<|eor|><|eols|><|endoftext|> | 7 |
lolphp | ajmarks | cj4e0c5 | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>What's the use of variadic functions?<|eor|><|sor|>In Python, I use them all the time as wrappers. For example, consider this:
d... | 7 |
lolphp | nikic | cj5c6lh | <|sols|><|sot|>PHP 5.6 to include variadic functions. We have now caught up to ALGOL 68 in functionality.<|eot|><|sol|>http://php.net/manual/en/migration56.new-features.php<|eol|><|sor|>But they still don't have named arguments (because Rasmatazz thinks they're ugly or something), so you can't use variadic features unl... | 7 |
lolphp | Serialk | 20yfrt | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|eols|><|endoftext|> | 32 |
lolphp | HelloAnnyong | cg83ra8 | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>To be fair, once you make it static typed and eliminate the coercion, you will have taken a lot of lol out of PHP. That said, there's still enough lol left for twelve languages. <|eor|><|s... | 42 |
lolphp | ajmarks | cg7yvya | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>To be fair, once you make it static typed and eliminate the coercion, you will have taken a lot of lol out of PHP. That said, there's still enough lol left for twelve languages. <|eor|><|e... | 35 |
lolphp | cparen | cg81vk5 | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>To be fair, once you make it static typed and eliminate the coercion, you will have taken a lot of lol out of PHP. That said, there's still enough lol left for twelve languages. <|eor|><|s... | 18 |
lolphp | tdammers | cg8670i | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>To be fair, once you make it static typed and eliminate the coercion, you will have taken a lot of lol out of PHP. That said, there's still enough lol left for twelve languages. <|eor|><|s... | 18 |
lolphp | cparen | cg84030 | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>To be fair, once you make it static typed and eliminate the coercion, you will have taken a lot of lol out of PHP. That said, there's still enough lol left for twelve languages. <|eor|><|s... | 15 |
lolphp | allthediamonds | cg874f7 | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>To be fair, once you make it static typed and eliminate the coercion, you will have taken a lot of lol out of PHP. That said, there's still enough lol left for twelve languages. <|eor|><|s... | 10 |
lolphp | cbraga | cg8dbht | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>They certainly picked the right name for their project
<|eor|><|eols|><|endoftext|> | 9 |
lolphp | Innominate8 | cg8qj0q | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>To be fair, once you make it static typed and eliminate the coercion, you will have taken a lot of lol out of PHP. That said, there's still enough lol left for twelve languages. <|eor|><|s... | 7 |
lolphp | mirhagk | cg887sn | <|sols|><|sot|>"Hack": No matter how hard you try, a nice-looking PHP is still PHP.<|eot|><|sol|>http://hacklang.org/<|eol|><|sor|>To be fair, once you make it static typed and eliminate the coercion, you will have taken a lot of lol out of PHP. That said, there's still enough lol left for twelve languages. <|eor|><|s... | 6 |
lolphp | lisp-case | 1z4i00 | <|sols|><|sot|>Mcrypt: "Catastrophic crypto failure? That's worth a warning. Maybe."<|eot|><|sol|>http://www.leaseweblabs.com/2014/02/aes-php-mcrypt-key-padding/<|eol|><|eols|><|endoftext|> | 35 |
lolphp | lisp-case | cfqh9fu | <|sols|><|sot|>Mcrypt: "Catastrophic crypto failure? That's worth a warning. Maybe."<|eot|><|sol|>http://www.leaseweblabs.com/2014/02/aes-php-mcrypt-key-padding/<|eol|><|soopr|>Okay, lessons learned from reading this article:
Don't use Mcrypt.
Seriously, look at this API:
> AES-256 is different from RIJNDAEL-256. Th... | 19 |
lolphp | iopq | cfqxled | <|sols|><|sot|>Mcrypt: "Catastrophic crypto failure? That's worth a warning. Maybe."<|eot|><|sol|>http://www.leaseweblabs.com/2014/02/aes-php-mcrypt-key-padding/<|eol|><|sor|>People always scoff when I do my scripting in bash or perl.
Coincidently those are two languages that halt execution on error.<|eor|><|sor|>Peop... | 13 |
lolphp | ChoHag | cfqt4hv | <|sols|><|sot|>Mcrypt: "Catastrophic crypto failure? That's worth a warning. Maybe."<|eot|><|sol|>http://www.leaseweblabs.com/2014/02/aes-php-mcrypt-key-padding/<|eol|><|sor|>People always scoff when I do my scripting in bash or perl.
Coincidently those are two languages that halt execution on error.<|eor|><|sor|>Well... | 10 |
lolphp | nikic | cfs2eo6 | <|sols|><|sot|>Mcrypt: "Catastrophic crypto failure? That's worth a warning. Maybe."<|eot|><|sol|>http://www.leaseweblabs.com/2014/02/aes-php-mcrypt-key-padding/<|eol|><|sor|>People always scoff when I do my scripting in bash or perl.
Coincidently those are two languages that halt execution on error.<|eor|><|sor|>Peop... | 8 |
lolphp | n3xg3n | cfqqacs | <|sols|><|sot|>Mcrypt: "Catastrophic crypto failure? That's worth a warning. Maybe."<|eot|><|sol|>http://www.leaseweblabs.com/2014/02/aes-php-mcrypt-key-padding/<|eol|><|soopr|>Okay, lessons learned from reading this article:
Don't use Mcrypt.
Seriously, look at this API:
> AES-256 is different from RIJNDAEL-256. Th... | 5 |
lolphp | tavianator | cfqoair | <|sols|><|sot|>Mcrypt: "Catastrophic crypto failure? That's worth a warning. Maybe."<|eot|><|sol|>http://www.leaseweblabs.com/2014/02/aes-php-mcrypt-key-padding/<|eol|><|sor|>People always scoff when I do my scripting in bash or perl.
Coincidently those are two languages that halt execution on error.<|eor|><|sor|>Well... | 5 |
lolphp | ajmarks | cfqver5 | <|sols|><|sot|>Mcrypt: "Catastrophic crypto failure? That's worth a warning. Maybe."<|eot|><|sol|>http://www.leaseweblabs.com/2014/02/aes-php-mcrypt-key-padding/<|eol|><|sor|>People always scoff when I do my scripting in bash or perl.
Coincidently those are two languages that halt execution on error.<|eor|><|sor|>Pyth... | 5 |
lolphp | Torandi | 174coe | <|soss|><|sot|>Member variables for NULL? No problem!<|eot|><|sost|>At work I'm fixing bugs and implementing smaller features in a horrible php spaghetti monster. One of the gems I found was this:
$row = NULL;
$row->product = "foobar";
At first I was just perplexed that this would work, I then realized that $... | 39 |
lolphp | Tjoppen | c82358y | <|soss|><|sot|>Member variables for NULL? No problem!<|eot|><|sost|>At work I'm fixing bugs and implementing smaller features in a horrible php spaghetti monster. One of the gems I found was this:
$row = NULL;
$row->product = "foobar";
At first I was just perplexed that this would work, I then realized that $... | 24 |
lolphp | Legolas-the-elf | c825o4p | <|soss|><|sot|>Member variables for NULL? No problem!<|eot|><|sost|>At work I'm fixing bugs and implementing smaller features in a horrible php spaghetti monster. One of the gems I found was this:
$row = NULL;
$row->product = "foobar";
At first I was just perplexed that this would work, I then realized that $... | 6 |
lolphp | mejicat | 138nnh | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|eols|><|endoftext|> | 37 |
lolphp | audaxxx | c71triy | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>And the first comment is
> Note that } elseif() { is somewhat faster than } else if() {
I am sure, this is very often the... | 17 |
lolphp | Porges | c71wqx8 | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>And the first comment is
> Note that } elseif() { is somewhat faster than } else if() {
I am sure, this is very often the... | 17 |
lolphp | mejicat | c71x7kn | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>Do not use the colon syntax. Problem solved.<|eor|><|soopr|>I think a better solution is not using PHP.<|eoopr|><|eols|><|... | 16 |
lolphp | Mattho | c71rtjm | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>Wello, *else if* is just *else { if* so it makes sense. You can only have one statement/block after the else (without a blo... | 8 |
lolphp | barubary | c71zyzs | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>And in some languages it's elif and then I'm just all confused.
I wish the Emperor Of Programming Languages would just dec... | 8 |
lolphp | kezabelle | c71xvmm | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>And in some languages it's elif and then I'm just all confused.
I wish the Emperor Of Programming Languages would just dec... | 7 |
lolphp | more_exercise | c74y4i4 | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>Do not use the colon syntax. Problem solved.<|eor|><|soopr|>I think a better solution is not using PHP.<|eoopr|><|sor|>Whi... | 7 |
lolphp | leoel | c7214dq | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>And the first comment is
> Note that } elseif() { is somewhat faster than } else if() {
I am sure, this is very often the... | 7 |
lolphp | kingguru | c7294f2 | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>And the first comment is
> Note that } elseif() { is somewhat faster than } else if() {
I am sure, this is very often the... | 6 |
lolphp | Altreus | c71vzpz | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>Wello, *else if* is just *else { if* so it makes sense. You can only have one statement/block after the else (without a blo... | 5 |
lolphp | audaxxx | c71up4i | <|sols|><|sot|>"else if" is an alias for "elseif", but if you're using the colon syntax it becomes a parse error<|eot|><|sol|>http://uk.php.net/manual/en/control-structures.elseif.php<|eol|><|sor|>And the first comment is
> Note that } elseif() { is somewhat faster than } else if() {
I am sure, this is very often the... | 5 |
lolphp | petdance | pi1gy | <|sols|><|sot|>PHP silently converts any spaces in field names to underscores. Surprise!<|eot|><|sol|>http://www.phpbuilder.com/board/showthread.php?t=10353238<|eol|><|eols|><|endoftext|> | 37 |
lolphp | RobOplawar | c3pj9ec | <|sols|><|sot|>PHP silently converts any spaces in field names to underscores. Surprise!<|eot|><|sol|>http://www.phpbuilder.com/board/showthread.php?t=10353238<|eol|><|sor|>I just wrote a test script because surely this can't be true in php 5.3. It is. >_>
You know, sometimes it can be really hard to defend this lang... | 13 |
lolphp | petdance | c3pjq2c | <|sols|><|sot|>PHP silently converts any spaces in field names to underscores. Surprise!<|eot|><|sol|>http://www.phpbuilder.com/board/showthread.php?t=10353238<|eol|><|soopr|>Turns out it's more than just spaces.
http://php.net/manual/en/language.variables.external.php
The full list of field-name characters that PHP ... | 11 |
lolphp | infinull | c3ppqnv | <|sols|><|sot|>PHP silently converts any spaces in field names to underscores. Surprise!<|eot|><|sol|>http://www.phpbuilder.com/board/showthread.php?t=10353238<|eol|><|sor|>I just wrote a test script because surely this can't be true in php 5.3. It is. >_>
You know, sometimes it can be really hard to defend this lang... | 11 |
lolphp | sloat | c3pmyqg | <|sols|><|sot|>PHP silently converts any spaces in field names to underscores. Surprise!<|eot|><|sol|>http://www.phpbuilder.com/board/showthread.php?t=10353238<|eol|><|sor|>It would be better if it failed but what language allows you to make variables or function definitions with spaces?<|eor|><|sor|>None that I know o... | 8 |
lolphp | infinull | c3ppqxl | <|sols|><|sot|>PHP silently converts any spaces in field names to underscores. Surprise!<|eot|><|sol|>http://www.phpbuilder.com/board/showthread.php?t=10353238<|eol|><|sor|>It would be better if it failed but what language allows you to make variables or function definitions with spaces?<|eor|><|sor|>None that I know o... | 5 |
lolphp | yxpow | m87tyd | <|soss|><|sot|>Implicit conversions with []<|eot|><|sost|>Not sure if this has been posted here before, but using `$c[]` when `empty($c) === true` overwrites the value of `$c`:
$c = false;
$c[] = 2;
works without any errors, but:
$c = false;
array_push($c, 2);
produces a type error.
Of course, the ... | 35 |
lolphp | funtek | grgmacb | <|soss|><|sot|>Implicit conversions with []<|eot|><|sost|>Not sure if this has been posted here before, but using `$c[]` when `empty($c) === true` overwrites the value of `$c`:
$c = false;
$c[] = 2;
works without any errors, but:
$c = false;
array_push($c, 2);
produces a type error.
Of course, the ... | 5 |
lolphp | SerdanKK | ia4xwn | <|soss|><|sot|>Named parameters are cool, but PHP variables aren't typed so the implementation is completely broken.<|eot|><|sost|>[https://3v4l.org/P2XSm](https://3v4l.org/P2XSm)
Someone please tell me wth they're thinking. If this ships I'll have to put up another "don't use this feature" sign at work.
[C# equivale... | 33 |
lolphp | yawkat | g1laj1m | <|soss|><|sot|>Named parameters are cool, but PHP variables aren't typed so the implementation is completely broken.<|eot|><|sost|>[https://3v4l.org/P2XSm](https://3v4l.org/P2XSm)
Someone please tell me wth they're thinking. If this ships I'll have to put up another "don't use this feature" sign at work.
[C# equivale... | 11 |
lolphp | SerdanKK | g1l2cir | <|soss|><|sot|>Named parameters are cool, but PHP variables aren't typed so the implementation is completely broken.<|eot|><|sost|>[https://3v4l.org/P2XSm](https://3v4l.org/P2XSm)
Someone please tell me wth they're thinking. If this ships I'll have to put up another "don't use this feature" sign at work.
[C# equivale... | 10 |
lolphp | eMZi0767 | g1l0urw | <|soss|><|sot|>Named parameters are cool, but PHP variables aren't typed so the implementation is completely broken.<|eot|><|sost|>[https://3v4l.org/P2XSm](https://3v4l.org/P2XSm)
Someone please tell me wth they're thinking. If this ships I'll have to put up another "don't use this feature" sign at work.
[C# equivale... | 8 |
lolphp | yawkat | g1lcmfd | <|soss|><|sot|>Named parameters are cool, but PHP variables aren't typed so the implementation is completely broken.<|eot|><|sost|>[https://3v4l.org/P2XSm](https://3v4l.org/P2XSm)
Someone please tell me wth they're thinking. If this ships I'll have to put up another "don't use this feature" sign at work.
[C# equivale... | 8 |
lolphp | elcapitanoooo | g1kmdxb | <|soss|><|sot|>Named parameters are cool, but PHP variables aren't typed so the implementation is completely broken.<|eot|><|sost|>[https://3v4l.org/P2XSm](https://3v4l.org/P2XSm)
Someone please tell me wth they're thinking. If this ships I'll have to put up another "don't use this feature" sign at work.
[C# equivale... | 6 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.