problem about wicked-pdf-Collection of common programming errors


  • Unixmonkey
    jquery ruby-on-rails-3 pdf-generation wicked-pdf
    I’m using Highcharts in my application to render charts. Everything works fine, except when I want to convert a page that has charts to PDF. I’m using wicked_pdf. Here is the show method my controller:format.pdf dorender :pdf => “report”,:template => “/quarters/report.pdf.erb”,endMy /quarters/report.pdf.erb file looks like it does in my show.html.erb for highcharts:<div id=”testcollections” style=”width: 600px;”></div><!– jQuery for testing collections charts –> <scr

  • Unixmonkey
    ruby-on-rails ruby pdf-generation wicked-pdf
    I’m using WickedPDF in my Rails app to generate PDF files. It’s working great on my local machine. In production I’m seeing the following error in my log:Started GET “/financieel/facturen/2.pdf” for 81.205.74.167 at 2012-09-19 14:58:37 +0200Processing by InvoicesController#show as PDFParameters: {“id”=>”2”} ***************WICKED*************** Rendered invoices/show.pdf.haml (6.9ms) Completed 500 Internal Server Error in 38msNoMethodError (undefined method `chomp’ for nil:NilClass):app/contro

  • Mat
    ruby pdf-generation wkhtmltopdf wicked-pdf
    I’m getting this error while generating pdf using wkhtmltopdfundefined method `pdf_from_string’ for #<WickedPdf:0x7f4b82a369c8>my wicked_pdf.rbWickedPdf.config = {:wkhtmltopdf => ‘/usr/local/bin/wkhtmltopdf’, :layout => “pdf.html”, :margin => { :top=> 40,:bottom => 20,:left=> 30,:right => 30}, :header => {:html => { :template=> ‘layouts/pdf_header.html’}}, :footer => {:html => { :template=> ‘layouts/pdf_footer.html’}} # :exe_path => ‘/usr/bin/wk

  • nbucciarelli
    ruby-on-rails ruby-on-rails-3 wicked-pdf
    I’m having an issue with wicked_pdf. It’s not taking into account any of my javascript. The report is being generated and the text that is rendered is “Page undefined of undefined”. Any help on linking up javascript into wicked_pdf would be greatly appreciated!Markup:<html><head><script>function number_pages() {console.log(‘hi’);var vars={};var x=document.location.search.substring(1).split(‘&’);for(var i in x) {var z=x[i].split(‘=’,2);vars[z[0]] = unescape(z[1]);}var x=[‘fr

  • Alex
    ruby-on-rails-3 pdf wicked-pdf
    Our platform has been online for a while and working just fine. Our customers are able to download their invoices in PDF format just fine.We’ve been working on a upgrades for a few month, and just today we noticed that “suddenly” non of our PDF generation with wicked_pdf and wkhtmltopdf no longer worked…I have absolutely no idea why, I checked everything I could think of: – routes – initializers – gems – etc.Everything seems to be fine, same as the actual only version.We have not changed Rails

  • user532339
    ruby-on-rails ruby-on-rails-3 wicked-pdf
    I am trying to attach my PDF to an email. However when I click the link I am given the following error undefiined method ‘user’ I have the following setup: Controllerdef index@hospital_bookings = HospitalBooking.scopedhospital_booking = @hospital_bookings@user = User.allif params[:format] == “pdf”@hospital_bookings = @hospital_bookings.where(:day => Date.today.beginning_of_month..Date.today.end_of_month)endrespond_to do |format|format.htmlformat.pdf dorender :pdf => “#{Date.today.strftime(

  • joelmaranhao
    ruby-on-rails heroku wicked-pdf
    I am trying to generate PDF reports with wicked_pdf gem. THe PDF generation works fine on my development environment, but it fails once it’s deployed on HerokuThis is the error I am getting:Failed to execute:/app/.bundle/gems/ruby/1.9.1/bin/wkhtmltopdf –header-font-name ‘Century Gothic’ –header-left ‘My Test – Neuffen, Germany’ –header-right ‘2012-02-05 15:50:57 -0800’ –header-font-size 14 –header-line –footer-center ‘Generated by Biowatts – http://biowatts.org’ –footer-font-name ‘Centur

  • Kashiftufail
    ruby-on-rails wicked-pdf
    Hi i am using wicked_pdf for generating images after i save image when i generate pdf and used this tag for display image like this<%= wicked_pdf_image_tag(@image.snap.url(:original)) unless @image.blank? %>it give me this unknown errorActionView::Template::Error (undefined method `pathname’ for nil:NilClass):while puts @image.inspect give me right path below”/system/snaps/7/original/flake.jpg”Can any one helpThanks….

  • dbaruah
    ruby-on-rails ruby centos wkhtmltopdf wicked-pdf
    I am using Ubuntu 11.04 to develop an app in Ruby on Rails. In the app I need to generate pdf documents. So I am using the wicked_pdf and wkhtmltopdf-binary gems.In the development environment in my system everything is working fine. But once I deployed the app in production on CentOS 5.6 using Phusion Passenger, when I try to generate pdfs on the fly its giving me the following error:RuntimeError (Location of wkhtmltopdf unknown)I am using Ruby1.9.2.p136Rails 3.1.1Any help will be much appreci

Originally posted 2013-11-27 05:11:23.