Smart card reader - javascript

How can I write javascript codes to interact with a smart card reader? I have found some activex controls and examples, but I think, it will be limited to IE only.

How can I make it run in all browsers, if the card reader driver is installed, and the hardware is available for use?

My problem is to make sure that the user puts his/her own smart card in the reader unit before he signs up in a website (a particular website, that I will be coding for).

Thank you for your replies and suggestions.

The Card Boss product from Comet Way does this. They have both activex (for IE) and netscape/chrome plugins. Both versions work the same way, the developer writes simple scripts that can send high-level commands or raw APDU commands.

They have an example on their site that shows how to use Javascript to control the card and parse the results from the card, look for the “PIV” demonstration (it works with a PIV card and uses javascript.)

Hope this helps.