On my https enabled website, I discovered that when I tried htmlConverter.Convert("https://mywebsite.com/Home") that I just get a blank page in the PDF, but if I do the call with just http:// it works fine. I am using SecuritySwitch, which allowed me to turn off the secure HTTP and so I am able to make it work, but I thought I would post about this issue here in case it comes up for anybody else. I am saving the document to a stream and feeding it to the HttpResponse stream as a download file, in c# here:
string urlToConvert = "http://mywebsite.com/page"; // : this url works, but https://mywebsite.com/page only gives blank page in the PDF
byte [] pdfData = null;
using (PdfDocument document = htmlConverter.Convert(urlToConvert))
{
using (MemoryStream memStream = new MemoryStream())
{
document.Save(memStream);
pdfData = memStream.ToArray();
}
}
// ... continue to feed PdfData to Response...
Bob