How can we extract string 'abc.com' from a string
"http://info@abc.com" using regular expression of PHP

Answer Posted / sathya

Use this coding

$variablename="http://info@abc.com";
$u=explode("@",$variablename);
$u2=$u[1];

Is This Answer Correct ?    7 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is nan in php?

531


If we login more than one browser windows at the same time with same user and after that we close one window, then is the session is exist to other windows or not? And if yes then why? If no then why?

490


Tell me what is the use of isset() in php?

549


Why do we use hooks?

508


What is the use of namespace in php?

557






What is php stack?

529


Are php variables global?

564


Why do we use in php?

544


How many functions are there in php?

521


Explain what does the unset() function means?

580


What is the function of string in c?

534


How to replace a text in a string with another text in php?

522


What is php form validation?

559


What is ltrim?

518


How to set cookies in PHP?

601