I looked online to figure out a way to remove the book navigation from the generated PDF and couldn't find anything, so I thought I'd share how I did this... might not be the best way to do it, but it works quite well for me.

in pdfview.module, function theme_pdfview_node , I added the following after the line that says $content = drupal_render($node->content);

  if($node->type == 'book'){ // Remove the book-navigation links from the PDF
	  $begin_remove = stripos($content,'<div class="book-navigation">');
	  $end_remove = stripos($content,'</div></div>',$begin_remove);
	  $content = substr_replace($content,"",$begin_remove,$end_remove-$begin_remove+strlen('</div></div>'));
  }

This was just a quick workaround which worked for me... hope it's useful for someone.

Comments

rconstantine’s picture

Thanks!!!

rconstantine’s picture

Status: Active » Reviewed & tested by the community

Works well.