1<html> 2<head> 3<script> 4 // Called when the user clicks on the browser action. 5 chrome.browserAction.onClicked.addListener(function(tab) { 6 var action_url = "javascript:window.print();"; 7 chrome.tabs.update(tab.id, {url: action_url}); 8 }); 9</script> 10</head> 11</html> 12 13