note 126280 rejected from function.str-contains by cmb
| From: | cmb@php.net | Date: | Tue, 27 Jul 2021 18:17:28 +0000 |
| Subject: | note 126280 rejected from function.str-contains by cmb | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-216669@lists.php.net to get a copy of this message | ||
Note Submitter: vinicius at dias dot dev
----
The function str_contains doesn't seem to work with multi-line strings. For example:
<?php
var_dump(str_contains("hello world", "world")); // bool(true)
var_dump(str_contains("hello\nworld", "world")); // bool(false)
?>