Windows jquery+ajax+php file Upload, linux+nginx+php+mysql problem ..... There is a choice of file path after the JS detection suffix does not pop up, after the submission can not accept anything .... Wnmp wrote.
Reply to discussion (solution)
You're giving too little information.
Windows jquery+ajax+php file Upload, linux+nginx+php+mysql problem ..... There is a choice of file path after the JS detection suffix does not pop up, after the submission can not accept anything .... Wnmp wrote.
Jquery
Windows
......
Html
Importing programs
Importing programs
Php
Can you confirm that the JS code is executed?
Can you confirm that the JS code is executed?
Executes the JS method outside the alert can play just see there is a JS undefined to the size of the case is not found the problem
Judging by my years of experience ... It should be JS problem.
Your 2 platform browser is consistent. Whether the browser is the same.
var f_content = Form.fileToUpload.value;
The form can be used directly? I feel the problem of Jane writing
And then look at the JS problem or the PHP problem.
Cancel JS to determine the test can be uploaded successfully. AJAX trigger alert (1) Ajax execution successful return at alert (2)
Separate test to solve the problem
It's probably a matter of case.
To complete the test individually:
1, judge whether JS gets the form object is successful;
2, to determine the feedback of the results of the submission, such as the form does not submit files, only post data, to determine the PHP back end of the post global array output;
3, the use of the removal of JS after the form submitted to see if the success;
4, use to remove JS after the file upload, to see if the success; (Ensure that the corresponding directory on the Linux server has write permissions)
Judging by my years of experience ... It should be JS problem.
Your 2 platform browser is consistent. Whether the browser is the same.
var f_content = Form.fileToUpload.value;
The form can be used directly? I feel the problem of Jane writing
And then look at the JS problem or the PHP problem.
Cancel JS to determine the test can be uploaded successfully. ajax trigger at alert (1) Ajax execution successfully returns to alert (...).
This var f_content = Form.fileToUpload.value; Change the
Now also reported error is: uncaught syntaxerror:unexpected end of input
Chrome IE has ...
Resolved because the return JSON type will not return a specific error so JS change jquery after the value is no problem (win under the original is no problem), the last is because the operation of the non-establishment of the corresponding table inserted error. After the establishment of the table all normal, thank you ~ ~