Skip to content

Instantly share code, notes, and snippets.

@geeksilva97
Created June 14, 2020 02:11
Show Gist options
  • Save geeksilva97/6f7153c6461b6039e04ee4f843e5ef46 to your computer and use it in GitHub Desktop.
Save geeksilva97/6f7153c6461b6039e04ee4f843e5ef46 to your computer and use it in GitHub Desktop.
Angular upload
<h2>Angular File Upload</h2>
<form (submit)="sendFile()" id="upload_form" enctype="multipart/form-data" method="post">
<input #inputFile type="file" name="file1" id="file1"><br>
<progress #progressBar id="progressBar" value="0" max="100" style="width:300px;"></progress>
<h3 id="status">{{ status }}</h3>
<p id="loaded_n_total">{{ uploadStatus }}</p>
<hr />
<button type="submit">Enviar arquivo</button>
</form>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment