【发布时间】:2015-12-23 08:42:32
【问题描述】:
如何分别解析下面代码中每个标头的内容。
$str="<html>
<body>
<h1>Java</h1>
<p>Java is a platform independent object oriented programming language</p>
<h2>Html</h2>
<p>HTML is a markup language for describing web documents</p>
<h3>Php</h3>
<p>Php is simple</p>
</body>
</html>";
【问题讨论】:
-
你看过这个吗?
-
你到底想做什么?
-
我需要分别解析Java、Html、Php头的内容。这样我就可以将解析后的数据以topic为头添加到数据库中。