在页面结束的时候用JS调用window.print()就行了撒

解决方案 »

  1.   

    <a href="javascript:window.print();">打印文章</a>
      

  2.   

    在页面代码的结束增加如下代码
    <script>
     window.print();
    </script>
      

  3.   

    好像没有吧,楼上的那些都是要按确定才开始打印的
    不知道window.print()可不可以加参数就可以直接打印的
      

  4.   

    楼主,是一打开页面就开始打,脚本语言先解释
    <script>
    window.print();
    </script>
      

  5.   

    XC. Printer Functions
    简介
    These functions are only available under Windows 9.x, ME, NT4 and 2000. They have been added in PHP 4.0.4. 安装
    Add the line extension=php_printer.dll to your php.ini file. <?php 
       $handle = printer_open("\\\\DOMAIN_NAME\\Printer_Name"); 
    ?> 
    具体看php手册吧,有这个函数,但是自己没有用过