PHP question

Discussion in 'Programming' started by Lifeonblack, Jul 7, 2018.

Thread Status:
Not open for further replies.
  1. Hi there so the
    The PHP strpos() function searches for a specific text within a string.

    If a match is found, the function returns the character position of the first match. If no match is found, it will return FALSE.

    The example below searches for the text "world" in the string "Hello world!":

    but if I did this thing
    Code (PHP):
    echo strpos("Hello world!", "world");
    the output is 6 since it will find the specific text within a string it will be 8 for me double ll in "heLLo" and one o in hellO" the rest is in the word "world" or I'm wrong in analyzing the explanation. My native language is not english so explain in simple worlds thank you.
Thread Status:
Not open for further replies.