I user mac osx and try my html file to pdf file via wickedpdf. I want to put a string every page of my pdf file but I have a problem about header which is not rendering.
My wickedpdf method is,
format.pdf do
render :pdf => '#{@examination.name}.pdf',
:disposition => 'inline',
:layout => 'examination_session_pdf.html.erb',
:no_background => true,
:header =>{:html =>{:template=>'shared/pdf/header.pdf.erb'}}
end
and the header file contains just "hello" string or nothing. However, every time I see this error,
can't convert nil into String
The problem line is ":header =>{:html =>{:template=>'shared/pdf/header.pdf.erb'". In addition, I cannot see any logs about rendering the header page on the console.
How can I fix it?