I want to know where do i get or how do i get the user details
such as username, id number and email when he/she logs-in in an intranet of
a corporate network using PHP?
I want to use those details to automatically authenticate user to the web-application
i am developing.
I have read about AUTH_USER but where or how do i access the variable?
You can do most of what you want via PHP LDAP functions. The only catch is that you would need to get a unique item to each user. You will have to do a little more research, but I am pretty sure that if you use IIS as the webserver rather than Apache, there is some quirk or trick to getting the logon/username of the person on the other end – which you could then use to query against LDAP in the following manner:
Apache will just return AUTH_USER as blank. A workaround would be to create a one off request for their logon, store it in a cookie and use the same LDAP queries to get up-to-date info on the user.