1 replies
  • WEB DESIGN
  • |
hi everyone,
can anyone tell me about the use of "enctype" attribute in a html form?
#attribute #enctype
Avatar of Unregistered
  • Profile picture of the author Marani
    The enctype attribute lets you specify an encoding type for your form. There are three possible values.

    application/x-www-form-urlencoded is the default value if the enctype attribute is not specified. This is the correct option for the majority of simple HTML forms.

    multipart/form-data is necessary if your users are required to upload a file through the form.

    text/plain is a valid option, although it sends the data without any encoding at all. It is not recommended, as its behavior is difficult to predict.

    Example Usage
    <form action="fileupload.php" method="post" enctype="multipart/form-data">
    <p>Please select the file you would like to upload.
    <input type="file" name="upload">
    <br>
    <input type="submit" value="Upload File">


    Read more: https://html.com/attributes/form-enctype/#ixzz56Q2kopRa
    {{ DiscussionBoard.errors[11307258].message }}

Trending Topics