我有一个名为index.php的页面,其上有一些内容,但标题是从另一个生成名为cache_currentsongcallapi.txt的文本文件的服务器设置的 'cache_currentsongapi.txt'的内容:
<tracks>
<radioname>Mick's Music Station</radioname>
<rank>0</rank>
<isradionomy>1</isradionomy>
<radurl>http://www.radionomy.com/mick-smusicstation</radurl>
<track>
<uniqueid>2722440231</uniqueid>
<title>Hello</title>
<artists>Adele</artists>
<starttime>2015-11-23 21:05:02.35</starttime>
<playduration>293023</playduration>
<current>1</current>
<callmeback>217256</callmeback>
</track>
</tracks>
有没有办法只能从文本文件中获取标题并将其显示在索引页面中?
注:
此方法不能包括编辑文本文件,因为它被服务器覆盖。
此代码将继续使用的网站:http://mickyd.net/radio