|
|||||||
| JavaScript JavaScript (not Java) Discussion and technical support, including AJAX and frameworks (JQuery, MooTools, Prototype...) |
![]() |
|
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Copy input from text box to hidden field
I have a form that includes a input type="file" field for upload. Would it be possible in javascript to have the path from the that field be automatically copied to a hidden field? Of course, if the answer is "yes", the next question would be, how?
|
|
#2
|
|||
|
|||
|
Code:
<form name="frm" action=""> <input type="file" name="fileUp1" onchange="this.form.copy1.value=this.value; alert(this.form.copy1.value);"> <input type="hidden" name="copy1"> </form> |
|
#3
|
|||
|
|||
|
Absolutely perfect. Thanks!
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|