Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

Check if a String Contains a Substring in PHP

phpCopy<?php
$mystring = "This is a PHP program.";

if (strpos($mystring, "program.") !== false) {
    echo("True");
}
?>
Source by www.delftstack.com #
 
PREVIOUS NEXT
Tagged: #Check #String #Contains #Substring #PHP
ADD COMMENT
Topic
Name
1+9 =