What is the functionality of the function strstr and stristr?
Answer Posted / arvind pippal(delhi)
strstr() function is used to return the sub string from
first occurrence of string point from the string base.If
string point is not found, returns FALSE. syntax: strstr
(string base,string point)
examle: <?php
$email = 'arvindpippal@gmail.com';
$domain = strstr($email, '@');
echo $domain;
?>
output: @gmail.com
stristr() does the same thing in Case-insensitive manner
| Is This Answer Correct ? | 23 Yes | 3 No |
Post New Answer View All Answers
What is session in c#?
How to convert strings to numbers in php?
How to connect to a url in php?
What enctype is required for file uploads to work?
What does $_cookie means?
How do I check if a given variable is empty?
How to take a substring from a given string in php?
How do I run a php script in windows?
Is it more secure to use cookies to trfer session ids?
What is meant by an associative array?
Explain me difference between mysql_connect and mysql_pconnect?
What is urlencode and urldecode in php?
Why delimiter is used in mysql?
How to read the entire file into a single string?
Can we run php on tomcat server?