Skip to content

Instantly share code, notes, and snippets.

@alex-endfinger
Created August 12, 2011 16:57
Show Gist options
  • Save alex-endfinger/1142469 to your computer and use it in GitHub Desktop.
Save alex-endfinger/1142469 to your computer and use it in GitHub Desktop.
<html>
<head>
<title>Print Test Page</title>
<script src="//www.google.com/cloudprint/client/cpgadget.js">
</script>
<script defer="defer">
var gadget = new cloudprint.Gadget();
gadget.setPrintButton(
document.getElementById("print_button");
gadget.setPrintDocument("url", "Cloud Print test page",
"http://commondatastorage.googleapis.com/chromeies/TestPage.pdf");
</script>
</head>
<body>
<center>
<h1>Print A Cloud Test Page</h1>
<button id="print_button" type="button">Print Test Page</button>
</center>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment