What is the functionality of the function strstr and stristr?

Answers were Sorted based on User's Feedback



What is the functionality of the function strstr and stristr?..

Answer / 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

What is the functionality of the function strstr and stristr?..

Answer / umapathi

strstr-finds the first occurence of a string inside another
string (case-sensitive)
stristr-finds the first occurence of a string inside
another string (case-insensitive)

Is This Answer Correct ?    17 Yes 3 No

Post New Answer

More PHP Interview Questions

What are the steps involved to run php?

0 Answers  


what is the importence of session.save_path in Php.ini file and wht changes u've to made before using sesssions in ur php program first time?

4 Answers  


Explain me what are the 3 scope levels available in php and how would you define them?

0 Answers  


What is variable give example?

0 Answers  


How to split a string into array using php?

0 Answers  






What is include in php?

0 Answers  


how to run PHP in command line?

8 Answers   InfoShore, Ramp Green, Xtreeme,


Difference between notify url, return url in paypal payment gateway?

4 Answers   A1 Technology, Capital IQ, CMS, Essar, HCL, IAS, Karvy, L&T, State Bank Of India SBI, TATA, Tisco, WNS,


How data or variable can be receive or send from PHP to HTML page??

3 Answers   TCS,


What is the use of callback in php?

0 Answers  


Which cryptographic functions in php returns the longest hash value?

0 Answers  


Can we learn php without html?

0 Answers  


Categories