# Live\_file\_input does not work

**URL:** <https://forum.elixirforum.com/t/live-file-input-does-not-work/46424>\
**Category:** Questions\
**Tags:** phoenix, file-uploading, surface\
**Created:** [March 7, 2022, 9:57am UTC](https://forum.elixirforum.com/t/live-file-input-does-not-work/46424 "2022-03-07T09:57:03Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Xty](https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/xty/32/25569_2.png) [@Xty](https://forum.elixirforum.com/u/Xty)\
**Post date:** [March 7, 2022, 10:10am UTC](https://forum.elixirforum.com/t/live-file-input-does-not-work/46424/2 "2022-03-07T10:10:23Z")

</div>

It’s hard to tell if the code samples you’ve provided are complete or boiled down examples, but I’m fairly sure that the LiveView upload features are expected to be used from within a `form` element.

Have you tried putting the `live_file_input` inside of a form? If not, I think that would be a good place to start.

Another thing that has caused me issues with live uploads is not having a `phx-change` handler on the form. Even if that handler does nothing but respond `{:noreply, socket}` it’s still needed for live uploads.

I’d recommend reading through the official documentation if you haven’t, it should cover everything you need and is likely more up-to-date than the videos you’ve mentioned.

> **[Uploads — Phoenix LiveView v1.2.5](https://phoenix-live-view.hexdocs.pm/uploads.html)**

---

_[View the full topic](https://forum.elixirforum.com/t/live-file-input-does-not-work/46424)._
