How can we extract string 'abc.com' from a string
"http://email@example.com" using regular expression of PHP
Answers were Sorted based on User's Feedback
Answer / rachana
We can use the preg_match() function with "/.*@(.*)$/" as
the regular expression pattern. For example:
|Is This Answer Correct ?||49 Yes||2 No|
Answer / sameer joshi
You can do like $site_array=explod("@","http://firstname.lastname@example.org");
$site_addr will get the value as abc.com
|Is This Answer Correct ?||13 Yes||7 No|
Answer / gaurav
you can use array split
$site_name will have the value abc.com.
|Is This Answer Correct ?||10 Yes||5 No|
Answer / sathya
Use this coding
|Is This Answer Correct ?||7 Yes||4 No|
Answer / nitesh kumar
you can use explode funciton
|Is This Answer Correct ?||4 Yes||2 No|
Answer / navneet singh
$url = "http://email@example.com"
$domain = strstr($url,"@");
|Is This Answer Correct ?||5 Yes||7 No|
hello experts good morning to everyone ! at present am now learning LAMP course sir( linux, apache,mysql and php) after finishing this course can i create my own website without investment is it possible ? please can any one tell sir and also tell me how can i upload my project after finishing the project in internet ? please tell the ways sir please send ur valuable suggestions to firstname.lastname@example.org
Explain mail function in PHP with syntax?
Does winrunner 8.0 or qtp 8.0 supports php
Tell me what are the functions to be used to get the image's properties (size, width and height)?
What is different between software and app
Tell me how to find current date and time?
Why do we use htaccess
Does php have multiple inheritance?
Tell me how to create a text file in php?
what is the difference between php and my sql
What is Joomla?
Tell me what does pear stands for?