you might want to try:
my $therequest=$r->the_request;
my($host,$uri) = $therequest=~m!http://([^/]+)(.*))!;
unless($host=~m!xyz\.com!){
$r->content_type('text/html');
$r->header_out(Location => "http://www.xyz.com$uri");
return REDIRECT;
}
you can probably also get mod_rewrite to do this for you very easily as
well.
--
___cliff [EMAIL PROTECTED]
"Hello!" wrote:
> sirs, i met a problem on EMBPERL_COOKIE_DOMAIN, which i set it to
> "xyz.com" for example. the IP address of my www.xyz.com is
> 123.99.88.77. %udat fails to be persistent if the URL entered in
> browser's Location box is http://123.99.88.77, very possibly because
> the domain part is "99.88.77" which is different from "xyz.com" i set
> for EMBPERL_COOKIE_DOMAIN so that the browser won't return the cookie
> EMBPERL_UID. i uncomment PerlSetEnv EMBPERL_COOKIE_DOMAIN but it still
> not work. or, how can i know entered URL is 123.99.88.77 (not
> SERVER_NAME) so that i can redirect the browser to www.xyz.com? is
> there any elegant remedy for such kind of user
> ignorance? thanks.huang-ming
>
> ----- Original Message -----
> From: Gerald Richter
> To: Hello ; Embperl@Perl. Apache. Org
> Sent: Friday, May 12, 2000 2:04 PM
> Subject: RE: %udat persistence problem...S.O.S.
>
>
> I'm sorry I didn't read the mailing list, because
> I don't know how to get the list.
>
> Look at
>
>http://perl.apache.org/embperl/Embperl.pod.15.html#Feedback_and_Bug_ReportsGerald
>
>
>