The PHP function str_word_count() is used to find the number of words in a string.
Let's check the following example to understand how this function actually works
<?php $string = 'Welcome to America. Nice to meet you'; echo str_word_count($string); // Outputs: 7 ?>0 0
Please Login to Post the answer