将HTML变量的内容打印为HTML中的文本字符串 [英] print the contents of PHP variable as text string in HTML
本文介绍了将HTML变量的内容打印为HTML中的文本字符串的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在wordpress php脚本中,我具有以下内容:
in a wordpress php script, I have the following:
echo '<div class="slide-media">' . $slide_media .
'</div><!--/.slide-media-->' . "\n"; }
我想查看$slide_media
变量内的内容.
基本上,所以我可以向图像添加链接.
I want to see the contents of what is inside $slide_media
variable.
Basically, so I can add a link to the image.
是否存在纯文本函数的变量? 谢谢
Is there a variable to plain text function? Thanks
推荐答案
要查看变量中的内容(可能是数组,对象或其他内容),请使用print_r($ slide_media);或var_dump($ slide_media);
To see what is within a variable (maybe it is in array, an object or something else) use print_r($slide_media); or var_dump($slide_media);
这篇关于将HTML变量的内容打印为HTML中的文本字符串的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文