0

I am creating one web application. It has one print link on it which calls

window.print();

function of javascript. It works fine in Chrome and Safari. But its not working in the Samsung Stock browsers in android. Please suggest how to initiate print in these browsers.

Aashutosh Sharma
  • 1,483
  • 2
  • 17
  • 29

1 Answers1

0

As indicated in the window.print() documentation, the command is not supported on Android devices. You can use the Google Cloud Print Web Element to add print functionality. You will need to implement a browser sniffer to determine which device is being used.

An online search will most likely provide you with options utilizing NavigatorID.userAgent property, however, this has been deprecated and may not work in the near future. Feature testing is probably your best option.

Hopefully this will help you get pointed in the right direction.

Community
  • 1
  • 1
Overflow Stack
  • 833
  • 5
  • 9