How to return particular word in the string ??

Discussion in 'Programming/Scripts' started by Prahlad Makwana, Dec 3, 2019 at 6:40 AM.

  1. Prahlad Makwana

    Prahlad Makwana New Member

    Hello, everyone
    I want "Sumit" as output but it returns me empty string.
    I have tried something like this:
    Code:
    <?php
    $email  = '[email protected]';
    $user = strstr($email, 'sumit', true);
    echo $user;
    ?>
    
    Thanks In Advance
     

Share This Page