Solved

How to get uploaded file value in JS?

Posted on 2008-10-17
5
541 Views
Last Modified: 2012-05-05
Hi all..,

        I am using a HTML file Input control to upload some files. I'm able to get the file path in IE using the command..."document.getelementbyId("filecontrolid").value. Now, the problem is if I run the application in IE its giving full filename, including filepath. But, the same code is yeilding only filename (without path) in mozilla browser. How to over come this and get the filename with filepath in both browsers???
0
Comment
Question by:sastry_hora
  • 3
5 Comments
 
LVL 15

Expert Comment

by:MMDeveloper
ID: 22742858
I'm not exactly sure this is doable. Browsers usually have some built-in restrictions to protect privacy, such as displaying full file paths.
0
 
LVL 36

Expert Comment

by:Loganathan Natarajan
ID: 22743072
Probably you can get the full path in FF.
0
 
LVL 36

Expert Comment

by:Loganathan Natarajan
ID: 22743075
Sorry, Probably you can not get the full path in FF.
0
 
LVL 36

Accepted Solution

by:
Loganathan Natarajan earned 500 total points
ID: 22743118
0
 

Author Closing Comment

by:sastry_hora
ID: 31507175
good solutions
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The task A number given should be formatted for easy reading by separating digits into triads. Format must be made inline via JavaScript, i.e., frameworks / functions are not welcome. So let’s take a number like this “12345678.91¿ and format i…
This article discusses the difference between strict equality operator and equality operator in JavaScript. The Need: Because JavaScript performs an implicit type conversion when performing comparisons, we have to take this into account when wri…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now