Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/wordpress/13.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 可视化编辑器&x27;在wordpress中显示前端时不要断线_Php_Wordpress - Fatal编程技术网

Php 可视化编辑器&x27;在wordpress中显示前端时不要断线

Php 可视化编辑器&x27;在wordpress中显示前端时不要断线,php,wordpress,Php,Wordpress,我在Wordpress中为工具VisualEditor下的WriteQuestion构建了插件,但当获取前端内容的数据响应时并没有中断 PHP代码如下: <?php echo apply_filters('the_content', esc_attr($item['question'])); ?> 如何在前端解决这个问题 提前感谢。在 esc_属性($item['question'])) 使用 $item[“问题”] 因为esc_attr函数可以删除html标记。像换行h1标

我在Wordpress中为工具VisualEditor下的WriteQuestion构建了插件,但当获取前端内容的数据响应时并没有中断

PHP代码如下:

<?php echo apply_filters('the_content', esc_attr($item['question'])); ?>

如何在前端解决这个问题

提前感谢。

esc_属性($item['question']))

使用 $item[“问题”]

因为esc_attr函数可以删除html标记。像换行h1标签额外 欲了解更多信息,请访问。

希望它能帮助你。:)