First, it would be helpful if you have a Glitch project to share it here so we can take a look. But I’ll give some general thoughts…
the simplest thing that can possibly do something
I guess you have an
input type="file" (like this)
If you want to make this go to another page, you can wrap it in a
form element, set the
action to another page, and add a Submit button. For example:
<label for="avatar">Choose a profile picture:</label>
<form action="b.htm" method="GET">
- The way we set up the file input only allows image files. Maybe that helps you?
- Page B will receive the filename in the query string but not the file content (i.e. you will arrive at
but I want to store/analyse/do something to the image
In this case you need to move onto something with a backend – on Glitch we usually use Express for this (start a project with ~hello-express)
In Express you can set up a route to accept the form data, point the form at it, and change the method to
If that’s the way you want to go, let us know what you’re trying to achieve and we can be more specific!
Hope this helps