Reputation: 13
I have just started using http://printjs.crabbly.com/#documentation
and after reading the documentation, it doesnt seem to be giving me a printer preview window when i click print, what is very interesting is that it doesn't seem to be giving me any js errors on the console on chrome. please see below :
<button type="button" onclick("printJS('JobSheet','html')")>Print Job
Sheet</button>
<link rel="stylesheet" href="{{asset('bundles/css/print.min.css')}}">
<script src="{{asset('bundles/js/print.min.js')}}"></script>
Any tips would be greatly appreciated.
Upvotes: 1
Views: 3386
Reputation: 2075
Getting any errors??check out my simple snippets once and compare with yours.please make sure your referring the correct files of printjs and about the id
<p id="myElementId">Hello {{name}}!</p>
<button type="button" onclick="printJS('myElementId', 'html')">tryprint</button>
Upvotes: 1