In order to take the name of the file from a <INPUT TYPE="FILE" >, we could
write a small Javascript.it is as follows.
<script language="javascript">
function SetFileName(filePath){
var parts = filePath.split('\\');
if (parts.length < 2)
parts = filePath.split('\/');
return parts[parts.length-1];
}
</script>
<FORM NAME="LOCAL">
<INPUT TYPE="HIDDEN" NAME="SAVEAS">
<INPUT TYPE=FILE NAME="fupload" align="top"
onFocus="this.form.SAVEAS.value=SetFileName(this.value);"
onBlur="this.form.SAVEAS.value=SetFileName(this.value);"
onChange="this.form.SAVEAS.value=SetFileName(this.value);"
onClick="this.form.SAVEAS.value=SetFileName(this.value);" >
</FORM>
Hope this helps!
thanx
Prasad R
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Robert Garcia
Sent: Friday, September 06, 2002 11:19 AM
To: Multiple recipients of list witango-talk
Subject: Re: Witango-Talk: Mac To TangoServerOnPC Upload
In your taf, how are you parsing the file name? Take a look at how your
filename is being parsed.
Robert.
On Thursday, September 5, 2002, at 08:30 PM, <[EMAIL PROTECTED]> wrote:
Hello all,
I am having a problem when uploading a file from a Mac (client) to
Tango_2000_SP1 server (running under Windows NT 4.0 server).
The upload itself is working fine, but the name of the file I get is huge,
for ex.:
macintosh+hd%2fdesktop+folder%2frecovered+desktop1%21%2frecovered+%231%2fiku
ko%2fmjb+3+ir+refurb62+folder%2fmjb3+ir.jpg
which I believe is the way a full pathname looks like on a Mac computer
(obviously I do not know much Macs).
I am pretty sure that sometimes the procedure works fine (I had users
transferring files from Macs), but there is at least this one instance in
which I got the above filename.
Does anybody have any idea why this is happening?
(Uploads from PCs to TangoServer work always).
Many thanks,
Mike.
--
Robert Garcia
BigHead Technology
2781 N Carlmont Pl
Simi Valley, CA 93065
Phone 805.522.8577
http://www.bighead.net/
http://www.theradmac.com/
[EMAIL PROTECTED]
________________________________________________________________________
TO UNSUBSCRIBE: send a plain text/US ASCII email to [EMAIL PROTECTED]
with unsubscribe witango-talk in the message body