Re: URL output query

From: Date: Tue, 28 Feb 2006 05:24:50 +0000
Subject: Re: URL output query
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-231182@lists.php.net to get a copy of this message
Hi Chris, if the only thing you want is to get the domain (having the whole URL) you have more than one way to solve it. Chris -it's a little akward that Chris answered to Chris- already told you about parse_url(), and since we're talking about strings, I would suggest something like $domain = preg_replace('{^([a-z]+://[^/]+).*$}X', '%1', $uri); Chris wrote:
Greetings PHP folks, Which PHP function do I use if I want to achieve the following : http://www.somesite.com/gallery/pics.php is the url...how do I get it to read only http://www.somesite.com in the browser address bar without the rest of the directory and filename appearing ? -- Atentamente, J. Rafael Salazar Magaña Innox - Innovación Inteligente Tel: +52 (33) 3615 5348 ext. 205 / 01 800 2-SOFTWARE rsalazar@innox.com.mx http://www.innox.com.mx


« previous php.general (#231182) next »