Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How can we extract string 'techinterviews.com' from a string
'http://www.techinterviews.com' using regular expression in PHP?

Answer Posted / rajeev raj karn

$url="http://www.techinterviews.com";
$url_part=split("w{1,3}[\.]",$url);
echo $url_part[1];

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to check your php installation?

943


What is the correct and the most two common way to start and finish a php block of code?

895


How do you find the length of a string in php?

921


What is abstract class php?

864


What is php routing?

922


What is return in php function?

951


How do you count numbers in php?

923


What is the empty function?

892


Is php a low level language?

922


What is str_replace()?

961


Which operator is used to combine string values in php?

882


What does $_ post mean in php?

1013


hello all, I need some sample placement papers in lion bridge.. can anyone help me?

2003


Does wordpress still use php?

939


Explain me what is the difference between $_files['userfile']['name'] and $_files['userfile']['tmp_name']?

866