473,466 Members | 1,562 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

http user in php script

I once saw a code to show the username that logged in in a php script after
logging in with http authentification, I cant seem to find the code anywhere
Jul 17 '05 #1
4 2201
On 2005-04-09, aznFETISH <ne**@aznfetish.com> wrote:
I once saw a code to show the username that logged in in a php script
after logging in with http authentification, I cant seem to find the
code anywhere


Are you looking for this:

<http://dk.php.net/manual/en/reserved.variables.php#reserved.variables.server>

Check 'PHP_AUTH_USER'.

--
Cheers
- Jacob Atzen
Jul 17 '05 #2
I try this
<?PHP
$username=$_SERVER['PHP_AUTH_USER'];
echo "$username";
?>
but it shows nothing

"aznFETISH" <ne**@aznfetish.com> wrote in message
news:z5******************@tornado.tampabay.rr.com. ..
I once saw a code to show the username that logged in in a php script after
logging in with http authentification, I cant seem to find the code
anywhere

Jul 17 '05 #3
On 2005-04-09, aznFETISH <ne**@aznfetish.com> wrote:
I try this
<?PHP
$username=$_SERVER['PHP_AUTH_USER'];
echo "$username";
?>
but it shows nothing


Weird, it works fine here. Try var_dump($_SERVER) and see what you can
find.

--
Cheers
- Jacob Atzen
Jul 17 '05 #4
ok thanks, it shows that should use
$_SERVER['REMOTE_USER'];
"Jacob Atzen" <ja***@aub.dk> wrote in message
news:sl*******************@tank.aub.dk...
On 2005-04-09, aznFETISH <ne**@aznfetish.com> wrote:
I try this
<?PHP
$username=$_SERVER['PHP_AUTH_USER'];
echo "$username";
?>
but it shows nothing


Weird, it works fine here. Try var_dump($_SERVER) and see what you can
find.

--
Cheers
- Jacob Atzen

Jul 17 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Nancy Drew | last post by:
hi all it's been years since i've worked with perl, so i'd rather use prefad code. i've got a client who is concerned that a perl http client could login to his server and query a set of forms,...
2
by: Newton | last post by:
I'm having some issues with a greasemonkey script i've made (nothing serious, and you'll notice that by the mess). I made it to learn javascript properly at first but it ended handy and now i'm...
3
by: Thomas.Firnschrott | last post by:
i have a problem concerning a php script i worte some time ago. It is a rather simple thing. On a Site you login via a html form which points to a php that checks the username and password, and...
3
by: vj | last post by:
I'm building a large infrastructure with about 30 servers (all running linux). I allow my end users to write scripts which then get broken down in smaller parts and run across the 30 servers. The...
1
by: Charles Wilson | last post by:
Can someone point me to some good instructions on using the WinInet.dll functions from VBA? I need to interact with a MySQL database via HTTP strings. We already have the database set up and a...
2
by: HopfZ | last post by:
Is there a way to make a (cross-browser) javascript function that will open an existing webpage (for example, www.google.com) in a new window (or in some part of _self) and then load a specified...
4
by: Tom | last post by:
I have a script which allows a user to upload a file. The script does some filename editing, mimetype checking, etc., and it's then supposed to send the file to a remote server, without any...
1
by: MKR | last post by:
I need some help writing a Greasmonkey user script. An application that I use generates HTML pages with tags like this: <input type="button" name="9999" value="1234567890"...
0
by: allavarapu | last post by:
Hi, I am new to Python and wrote a http protocol script. I got this error please slove this my server::: import string,cgi,time from os import curdir, sep
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.