How can we extract string ‘abc.com ‘ from a string
info@abc.com" target="_blank">http://info@abc.com using
regular expression of php?
Answer Posted / ankush prasad
<?php
$string1="info@abc.com";
$string2=preg_match("/[a-c]+.[c-o]+/",$string1,$a);
print $a[0];
?>
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is the main difference between require() and include()?
What is $_ get in php?
How to move uploaded files to permanent directory?
How to remove duplicate values from php array?
Is php a backend?
How does php serialize work?
What is the difference between get and post method in php?
Explain how is it possible to set an infinite execution time for php script?
How can we encrypt the password using php?
Tell me what is pear?
Why and where do we use htaccess?
What is singleton design pattern in php?
Is polymorphism inherited?
What is the best way to avoid email sent through php getting into the spam folder?
Why do we use htaccess and where?