lib/controller/pdf_builder.rb in lipsiadmin-5.0.4 vs lib/controller/pdf_builder.rb in lipsiadmin-5.0.5
- old
+ new
@@ -57,10 +57,10 @@
# try to find erb extension
ext = File.exist?("#{view_path}/#{template}.html.erb") ? "erb" : "haml"
# encode the template
- input = encode_entities(render(:template => "#{view_path}/#{template}.html.#{ext}"))
+ input = encode_entities(render(:template => "#{view_path}/#{template}.html.#{ext}", :layout => false))
# search for stylesheet links and make their paths absolute.
input.gsub!('<link href="/javascripts', '<link href="' + view_path + '/../../../public/javascripts')
input.gsub!('<link href="/stylesheets', '<link href="' + view_path + '/../../../public/stylesheets')
\ No newline at end of file