str_contains function
<?php
$text = 'Checking if a string contains a substring';
$result = str_contains($text, 'if');
echo $result ? 'Yes' : 'No';
<?php
$text = 'Checking if a string contains a substring';
$result = str_contains($text, 'if');
echo $result ? 'Yes' : 'No';
Leave a Comment
Cancel reply