gpt4 book ai didi

PHP printer_open 正在打印 html 标签

转载 作者:可可西里 更新时间:2023-11-01 13:01:05 27 4
gpt4 key购买 nike

PHP printer_open 正在打印 html 标签。我将 printer_set_option 与 raw 和 text 一起使用,但它打印的内容相同。

下面是我的代码:

            if($ph = printer_open()) 
{
$content = $data;
printer_set_option($ph, PRINTER_MODE, "RAW");
printer_write($ph, $content);
printer_close($ph);
}
else "Couldn't connect...";

最佳答案

对于打印机,您无法使用打印机渲染 html,但可以使用 echo!

示例:

<?php
echo file_get_contents( "filename.php" ); // get the contents, and echo it out.
?>

关于PHP printer_open 正在打印 html 标签,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33093925/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com