Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rotativa ignoring Boostrap CSS when published to the server

Rotativa correctly shows and renders a PDF with my Bootstrap when hosted locally, but not once it is posted to the server. The rendered PDF shows some CSS, but no Bootstrap. I have seen other posts about this, but the suggestions did not work. The Rotativa folder is in the root of the web app as suggested.

like image 1000
Rachel Ostrander Avatar asked Jun 05 '15 13:06

Rachel Ostrander


1 Answers

I had the same issue, and solved it by changing it to something like:

<link href="@Server.MapPath("~/Content/bootstrap.min.css")" rel="stylesheet" />
like image 179
Stephen Zeng Avatar answered Nov 15 '22 10:11

Stephen Zeng