JavaScript Reference/Javascript Properties/enctype

Материал из Web эксперт
Версия от 11:21, 26 мая 2010; Admin (обсуждение | вклад) (1 версия)
(разн.) ← Предыдущая | Текущая версия (разн.) | Следующая → (разн.)
Перейти к: навигация, поиск

"enctype" Example

   <source lang="javascript">
   

<html> <body> <form id="fm" method="post"> <button onclick="alert(document.all.fm.encoding);">encoding</button> <button onclick="alert(document.all.fm.enctype);">enctype</button> </form> </body> </html>


     </source>
   
  


"enctype" is applied to

   <source lang="javascript">

+----------------+--------------------------------------------------------------+ | Applied_To |<form> | +----------------+--------------------------------------------------------------+

     </source>
   
  


"enctype" Syntax and Note

   <source lang="javascript">

Note: Read and write property. Provides the same functionality as the encoding property.

Syntax:

document.getElementById("formID").enctype = value document.all.formID.enctype = value // IE only


     </source>