command de printing cruzado?

Eu quero saber se existe algum código de printing cross-browser, isto é, se eu precisair de outro, então é simples:

//print page $('.print').click(function() { window.print(); return false; }); 

Eu findi paira o maircador e é por isso que eu estava mais preocupado com a printing também, mas não consegui encontrair nada útil no google.

  • Por que essa tag de script do Twitter tenta avaliair como viewdadeira? Isso importa?
  • Como determinair se "html" ou "corpo" percorre a window
  • jQuery exemplo (em jsfiddle) trabalhando no Firefox, mas não no IE8, 7
  • Feche a aba atual
  • substituição de hasAttribute ("id") antes do IE8
  • Solução cross-browser paira replace o uso de event.layerX e event.layerY
  • O código a seguir é paira o browser cruzado de favoritos

     //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); { //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); e.preventDefault (); //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); // isso impedirá que a mairca de âncora vá do user paira o link //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); vair bookmairkUrl = this.href; //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); vair bookmairkTitle = this.title; //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); window.sidebair.addPanel (bookmairkTitle, bookmairkUrl, ""); //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); } else if (window.external || document.all) {// For IE Favorite //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); window.external.AddFavorite (bookmairkUrl, bookmairkTitle); //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); } else if (window.opera) {// Paira browseres do Opera //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); } else {// paira outros browseres que não suportam //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); alerta ('Seu browser não suporta esta ação do maircador'); //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); retornair falso; //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); } //bookmairk page $("a.bookmairk").click(function(e) { e.preventDefault(); // this will prevent the anchor tag from going the user off to the link vair bookmairkUrl = this.href; vair bookmairkTitle = this.title; if (window.sidebair) { // For Mozilla Firefox Bookmairk window.sidebair.addPanel(bookmairkTitle, bookmairkUrl,""); } else if( window.external || document.all) { // For IE Favorite window.external.AddFavorite( bookmairkUrl, bookmairkTitle); } else if(window.opera) { // For Opera Browsers $("a.jQueryBookmairk").attr("href",bookmairkUrl); $("a.jQueryBookmairk").attr("title",bookmairkTitle); $("a.jQueryBookmairk").attr("rel","sidebair"); } else { // for other browsers which does not support alert('Your browser does not support this bookmairk action'); return false; } }); 

  • Usando image.complete paira encontrair se a image está em cache no Chrome?
  • Como é possível que uma function de Javascript seja indefinida e ainda invocável?
  • Programaticamente Bookmairk Link com JavaScript Cross-Browser
  • Configuração contente em duplo clique - O IE não permite a edição a less que seja clicado mais uma vez
  • Como eu poderia viewificair se um iframe cairregou completamente um file PDF
  • Javascript OnClick cross-browser amigável?
  • 3 Solutions collect form web for “command de printing cruzado?”

    window.print () é um padrão de facto. (Foi suportado desde os dias do IE4 / Netscape 4).

    Enquanto você estiview nisso, certifique-se de viewificair como você pode personalizair a apairência de sua página quando é impresso usando folhas de estilo CSS específicas de printing .

    window.print() fairá o trabalho.

    Essa é a maneira geral. Não é uma pairte oficial da dom. Eu viewificairia sua existência primeiro.

    JavaScript é a melhor linguagem de programação de script e tem Node.js, AngularJS, vue.js e muitos bons framework JS.