Pass parameter to BLOB object URL

前端 未结 3 1032
醉话见心
醉话见心 2020-12-21 09:49

Say I\'ve got a reference to a html file as a Blob b and I create a URL for it, url = URL.createObjectURL(b);.

This gives

3条回答
  •  北海茫月
    2020-12-21 10:27

    I don't think adding a query string to the url will work as it essentially changes it to a different url.
    However if you simply want to pass parameters you can use the hash to add a fragment to the url

    ifrm.src = url + '#foo=bar';
    

    http://jsfiddle.net/thpf584n/1/

提交回复
热议问题