Problems on embedded h5 Android

<input type="file" class="add-view-img-btn j-upbtn" name="quanjing" data-type="quanjing" data-maxupimg="15" accept="image/jpeg">
$(".j-upbtn").on("change",function(e){
        var _file =  this.files[0];
        var para = {};
        para.name = $(this).attr("name");
        para.type = $(this).attr("data-type");
        para.maxupimg = $(this).attr("data-maxupimg");

        var formData = new FormData();
        formData.append("name", para.name);
        formData.append("file", _file);
        formData.append("type", para.type);
        formData.append("data", $("-sharpdataParms").val());
        formData.append("iscamera",2);

        $.ajax({
            url: "{:U("Api/Carclaim/uploadImage",array("sessionid"=>$_GET["sessionid"],"token"=>$_GET["token"]))}",
            type: "POST",
            data: formData,
            processData: false,
            contentType: false,
            beforeSend:function(){
                dialog.loading.open("");
            },
            complete:function(){
                dialog.loading.close();
            },
            success: function (res) {
                console.log(res)
                if(res.status){
                    dialog.toast(res.msg,"success",2000);
                    var tmphtml = "<li id="file-"+res["data"]["id"]+"" class="view-img-item" onclick="openView(this)">"+
                            "<div class="bgimg" style="background-image:url("+res["data"]["imgPath"]+")"></div>"+
                            "<input type="hidden" name=""+res["data"]["type"]+"[]" value=""+res["data"]["id"]+""/>"+
                            "<span class="delspanCar" onclick="delspanCar("+res["data"]["id"]+",this)"><i class="iconfont icon-shanchu"></i></span>"+
                            "</li>";
                    $(obj).parents(".add-view-img-btn-wrap").siblings("ul").append(tmphtml)
                }else{
                    dialog.toast(res.msg,"error",1500)
                }
            },
            error:function(xhr,text){
                dialog.toast(xhr, "error", 2000);
            }
        });
    });

there is no problem with the above code in Wechat and mobile browsers. Put it in the embedded page, and the back end says that it cannot receive parameters. The parameters that are always returned are incomplete.
previously used the localResizeIMG plug-in to do compression,. There"s nothing wrong with it.
now I upload it to new formData instead. But it is still said that the parameters are not complete, it is really impossible to ask the great god for guidance!

Feb.17,2022

1. I just finished an Android embedded H5 the day before yesterday and there is also an upload function. What I encountered was that the upload control could not be opened. Then I checked that Android was blocked. ,
2. Another problem is cross-domain upload. If it is jq, you may have to add two parameters, xhrFields: {withCredentials: true}, crossDomain: true;
. I don't know if it will help you.


the test machine you use does not support formdata?

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b35b8c-2bfcd.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b35b8c-2bfcd.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?