Firefox 3 problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • SagarDoke
    New Member
    • Feb 2008
    • 24

    Firefox 3 problem

    Hi all,

    I wanted to browse a file using HTML.
    So, I have written this code:

    [HTML]<input type="file" style="height:2 2px" size=30 name="file" id="file"><br>< br>[/HTML]

    and JavaScript code for get the path of that selected file as
    [HTML]var file_name = document.getEle mentById('file' ).value;
    alert(file_name );
    [/HTML]

    But problem is I am getting only file name, not full path. Its working fine on Internet Explorer and Firefox version older than 3.0.
    Then what should be the problem? Is it Firefox 3 issue or is there any error in my code?

    Thanks
  • acoder
    Recognized Expert MVP
    • Nov 2006
    • 16032

    #2
    No problem with your code. Firefox 3 has changed the behaviour of file upload elements. See http://developer.mozilla.org/en/docs..._upload_fields.

    Comment

    Working...