11
McNaz
Re: Picking up windows environment variables in PHP
  • 2005/12/21 13:01

  • McNaz

  • Just can't stay away

  • Posts: 574

  • Since: 2003/4/21


Hi there.

I remember trying to do this a few years ago. Users on windows machines which autologon into Xoops, which ran on an Apache Linux box.

The problem (not really a problem actually) with PHP is that it is a server side script so you would not be able to run anything on the client to determine usernames etc.

The solution was to use the NTLM module for Apache. Check outhttp://modntlm.sourceforge.net/ and Google NTLM and Apache. There were some pitfalls involved and it did require some research.

Another solution would be to write a small program that runs on each client machine (kicked off by a logon script) that would plant the username into an enviroment variable (these can be seen if you type SET from a cmd prompt)

I'd hate to say it, but it is much easier to do using IIS (spit), which supplies these variables.

HTH and good luck.

McNaz.

Login

Who's Online

125 user(s) are online (71 user(s) are browsing Support Forums)


Members: 0


Guests: 125


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits