Ezilon.com - Target Your Audience, be Seen in Your Region

2 odd questions for you!

You are viewing this site as a guest. Join our community to get your questions answered and share knowledge. Active members may advertise and ask for a website critique.

They have: 32 posts

Joined: Nov 2003

Hey everyone,

I was wondering 2 things:

Is it possible when using .htaccess to have some text say "Welcome person's name" when they log in?

and:

Do you know if there are any plans to allow use of login forms for .htaccess instead of the pop up login box? (Since microsoft recently took this option away)

Thanks in advance,

Mark

andy206uk's picture
DeveloperModerator

He has: 1,754 posts

Joined: Jul 2002

I take it by "when using .htaccess" you mean, when using .htaccess with .htpasswd to password protect a page?

If so, yes using PHP you can get the username and password that were entered in the box using special variables which are:

$PHP_AUTH_USER
$PHP_AUTH_PW

'

This can then be used to retrieve the user's propername from a database,flatfile or whatever... or you could just greet them with their username...

Andyk

Blog of a Web Designer
Give a man a fish and you feed him for a day. Teach him to use the Net and he won't bother you for weeks.

They have: 32 posts

Joined: Nov 2003

Thanks Andy..Can you tell me what I would do with the code you gave me? As in: Where would I put it? How would I make it work?

I apologize but I am still a php newb!

Thanks,

Mark

Subscribe to this feed: Syndicate content