且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何认证头添加到$ window.open

更新时间:2022-06-25 16:49:34

我觉得你可以在URL中添加该认证参数和在你的服务器端做一个GET

I think you can add this authentication parameters in URL and do a GET in your server side

//Add authentication headers as params
var params = {
    access_token: 'An access_token',
    other_header: 'other_header'
};

//Add authentication headers in URL
var url = [url_generating_pdf, $.param(params)].join('?');

//Open window
window.open(url);