Skip to content

Retrieve text of a input=text to change name of an image #5

@Knet89

Description

@Knet89

Hi, Thanks a lot for your code, i have an issue, im trying to retrieve the text of the input=text an form like this:

<form method="post" enctype="multipart/form-data"> <input type="file" name="files[]" multiple> <br> <label>New Name</label> <input type="text" id="cod" name="cod"> <br> <input type="submit" value="Upload File" name="submit" /><br> </form>
and my idea is that the name of the image is like the text of the input text called "cod"... but it is not renamed with the new name, instead it renames it as undefined.png

and if it is posible, i do not want to upload multiple files, instead only one file.

I will send you the files if you want to analyze the code, can you help me?
index.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions