Write a regular expression to get the value xxx from the
string 'xxx@yyy.com'
Answer Posted / bipin
<?php
$string = 'xxx@yyy.com';
list($firstString,$secondString) = split('@',$string);
echo $firstString;
?>
| Is This Answer Correct ? | 9 Yes | 7 No |
Post New Answer View All Answers
What are Routines?
What is abstract class php?
Tell me what does the php error 'parse error in php - unexpected t_variable at line x' means?
What is the role of php?
How can php and javascript interact?
Which function will you use to create an array?
What are the new features available in php 7?
How to Pass JSON Data in a URL using CURL in PHP?
How to remove leading and trailing spaces from user input values in php?
How to randomly retrieve a value from an array?
What is the difference between nowdoc and heredoc?
How to get no of arguments passed to a PHP Function?
Tell me what kind of things have you done on the social side?
Where are the persistent cookies stored on your computer?
What are php filters?