I was testing the -dev release of the module, but when I try to get the PDF from a node, I got this error.

Notice: Undefined variable: node in print_pdf_controller()

After this, there are lots of

Notice: Trying to get property of non-object in node_token_values()

I found this

http://drupal.org/node/190173#templatenode

But I'm not actually using a custom template, but the built-in template with the Garland theme.
Any suggestion about how to find a solution?

Comments

jcnventura’s picture

Status: Active » Closed (duplicate)
nathancollins44’s picture

Version: 6.x-1.x-dev » 7.x-1.0-alpha1

I am getting the same Notice does anyone know how to fix this?
But I am using D7 7.x-1.0-alpha1

Notice: Undefined variable: node in print_pdf_controller() (line 45 of /home8/kpcprodu/public_html/americanwrc/sites/all/modules/print/print_pdf/print_pdf.pages.inc).
User warning: Attempting to perform token replacement for token type node without required data in token_tokens() (line 791 of /home8/kpcprodu/public_html/americanwrc/sites/all/modules/token/token.tokens.inc).

I only get this message when I click modules button after clicking the PDF version.

MagmarFire’s picture

I'm getting the exact-same notice on line 45, too. The thing different with mine is that I'm also getting another notice (and that I don't see the user warning):

Notice: Undefined offset: 1 in _print_pdf_wkhtmltopdf_version() (line 655 of /home/vhosts/proms/user-dir/htdocs/sites/all/modules/print/print_pdf/print_pdf.module)

nathancollins44’s picture

Status: Closed (duplicate) » Needs work

I guess I was able to fix this Notice: Undefined variable: node in print_pdf_controller() by un checking the Use URL alias instead of node ID in the configuration.

jcnventura’s picture

Status: Needs work » Closed (duplicate)