I'm trying to use your wrapper in order to generate a PDF file of a html page containing an invoice in ASP.net MVC 5. This is a order system where it's, of course, protected from the public by log in and cookie authentication using Identity. I tried adding Cookies by doing:
var cookies = Request.Cookies.AllKeys.ToDictionary(k => k, k => Request.Cookies[k].Value);
Codaxy.WkHtmlToPdf.PdfConvert.ConvertHtmlToPdf(new Codaxy.WkHtmlToPdf.PdfDocument
{
Url = Request.Url.AbsoluteUri.Replace("pdf", "print"),
HeaderLeft = "[title]",
HeaderRight = "[date] [time]",
FooterCenter = "Page [page] of [topage]",
Cookies = cookies
}, new Codaxy.WkHtmlToPdf.PdfOutput
{
OutputFilePath = Server.MapPath("~/Content/InvoicePDFs/"+ id.ToString() + ".pdf")
}
return File("~/Content/InvoicePDFs/" + id.ToString() + ".pdf", "application/pdf", id.ToString() + ".pdf");
);
But I just end up rendering the login page, and barely that, it's not even completely loaded. It just renders the elements, no text whatsoever.
I'm trying to use your wrapper in order to generate a PDF file of a html page containing an invoice in ASP.net MVC 5. This is a order system where it's, of course, protected from the public by log in and cookie authentication using Identity. I tried adding Cookies by doing:
But I just end up rendering the login page, and barely that, it's not even completely loaded. It just renders the elements, no text whatsoever.