php string indexof char code example Example: find index of a character in a string php <?php echo strpos("I love php, I love php too!","php"); ?>