Created/modified getPDF

Function at page onload modified to function getPDF which comunicates with the
pdf.js api