I have a webpage in wordpress.
In a page template I make a call via Ajax to a php function that returns a pdf stream made by php-pdftk library call.
The pdf stream seems to return fine to the success event of the jquery ajax call, but I can not find a way to send this stream to the browser.
It seems there is no direct way to output to a new browser window nor a object or a embed in the same document.
I have read almost every answer to this question in SO and other sites, but it seems it cannot be done.
Does anyone find a way to do this from JS or Jquery, or this is impossible from the conceptual point of view?
What would be the best way to do this?