Bootstrap and PHP file upload

2k views Asked by At

I'm trying to submit the image I'm uploading using Bootstrap jQuery plugins and PHP.

My PHP is working fine with a normal HTML form but when I'm using the Bootstrap the PHP is failing silently.

"Sorry for not uploading the code directly"

This is my html file

This is my php file

1

There are 1 answers

0
jophab On BEST ANSWER

Nesting of form is not allowed in HTML.

Every form must be enclosed within a FORM element. There can be several forms in a single document, but the FORM element can't be nested

see more about forms here

You have opened a form tag at Search and Account section.

This form is closed after the form which takes the file input.

So in effect there is nesting of forms.

So close the first form before the second form to avoid nesting