문제

I am just allow user to upload file via computer so I don't really need the pop-up.

Is that possible to plug the filepicker window directly to <input type="file"> so when user click choose file button. It direct open OS file window instead of open filepicker ?

도움이 되었습니까?

해결책

You can use the filepicker.store() API for exactly this purpose - https://developers.inkfilepicker.com/docs/web/#store

var input = document.getElementById("store-input");
filepicker.store(input, function(InkBlob){
        console.log("Store successful:", JSON.stringify(InkBlob));
    }, function(FPError) {
        console.log(FPError.toString());
    }, function(progress) {
        console.log("Loading: "+progress+"%");
    }
);
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top