Page 1 of 1
How to detect Windows vs Mac files upon user upload ??
Posted: Tue Jun 22, 2004 3:29 pm
by mgm_03
We have a need to ensure a user is uploading an acceptable file format (image artwork). The company only supports Windows and would like to know if it's possible to discern between Windows and Mac. Then let the user know the file was acceptable or not.
Is file platform detection possible with PHP?
Does anyone have thoughts?
TIA !!!
Posted: Tue Jun 22, 2004 3:33 pm
by feyd
most file formats use a specific byte order. For the formats that don't, which is few, they normally have a byte order marker/indicator inside the file format. TIFF's for example have a two byte marker that shows which order (big-endian or little-endian) the data was written in. MP3s have the same sort of form.
Posted: Tue Jun 22, 2004 3:34 pm
by feyd
..and turn off "Notify on reply", read my sig for additional details.
Posted: Tue Jun 22, 2004 6:39 pm
by tim
are u asking to see what OS the visitor uses??
$_SERVER['HTTP_USER_AGENT'];
Posted: Tue Jun 22, 2004 10:50 pm
by d3ad1ysp0rk
feyd wrote:..and turn off "Notify on reply", read my sig for additional details.
--feyd
That helps..

Posted: Tue Jun 22, 2004 11:28 pm
by mgm_03
Thanks for all replies.
..and turn off "Notify on reply", read my sig for additional details.
pardon my density ...if notify is turned off, how do I know if someone has replied to a post? Where are the "additional details"?
Posted: Tue Jun 22, 2004 11:38 pm
by feyd
it's already fixed.. ignore that.
Posted: Wed Jun 23, 2004 10:20 am
by d3ad1ysp0rk
mgm_03 wrote:pardon my density ...if notify is turned off, how do I know if someone has replied to a post? Where are the "additional details"?
By checking back to the forum?
We have a rather lively forum, all posts are usually answered/responded to in a few hours.