Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   Perl Misc (http://www.velocityreviews.com/forums/f67-perl-misc.html)
-   -   Get htpasswd username (http://www.velocityreviews.com/forums/t893627-get-htpasswd-username.html)

hgwoss@gmx.de 08-06-2005 08:28 AM

Get htpasswd username
 
Hi,

I want to process the current users htpasswd username, which he has
entered in order to access a website.

I would appreciate any info.


Paul Lalli 08-06-2005 11:25 AM

Re: Get htpasswd username
 
hgwoss@gmx.de wrote:
> Hi,
>
> I want to process the current users htpasswd username, which he has
> entered in order to access a website.
>
> I would appreciate any info.


Apache stores this in the REMOTE_USER environment variable. Perl
provides access to the environment variables via the global %ENV hash.
Therefore:

my $username = $ENV{REMOTE_USER};

Paul Lalli



All times are GMT. The time now is 09:46 AM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.