Page 1 of 1

how to get the online user's MAC address using PHP?

Posted: Wed Dec 06, 2006 9:02 am
by nmb
hi pp!

how to get the online user's MAC address using PHP??
is that possible?

tnks!

Posted: Wed Dec 06, 2006 9:14 am
by John Cartwright
not possible

Posted: Wed Dec 06, 2006 9:20 am
by nmb
hum ok!

so how can it be made?

Re: how to get the online user's MAC address using PHP?

Posted: Wed Dec 06, 2006 9:22 am
by yckelvin
nmb wrote:hi pp!

how to get the online user's MAC address using PHP??
is that possible?

tnks!
First, php is server-based scripting but not client-based, so it can't work

Posted: Wed Dec 06, 2006 9:32 am
by nmb
yes that's right.

but the same we can get IP ADDRESS using $_SERVER['REMOTE_ADDR'],
i thought that I would give MAC ADDRESS by the same way.

mabye using javascript i can get the MAC ADDRESS.

I was only searching in php programming.. mabye the right place to search is javascript programming

tnks! ;)[/quote]

Posted: Wed Dec 06, 2006 9:56 am
by pickle
The MAC address isn't passed in an HTTP request. The only way I've found it possible is if your server is also the DHCP server for the user. You can then look in the dhcpd.leases file for the MAC address. Other than that - you're out of luck.

Posted: Wed Dec 06, 2006 11:09 am
by feyd
Javascript cannot pull the MAC address either. It's just not available.