试图搜集攀岩馆的数据。我用的是美肌。 我想存储健身房名称、位置、电话号码、链接和描述的数组
以下是示例html:
div class="city">Alberta</div>
<p><b>Camp He Ho Ha Climbing Gym</b><br>
Seba Beach, Alberta, TOE 2BO Canada<br>
(780) 429-3277<br>
<a rel='nofollow' target='_blank' href='http://camphehoha.com/summer-camp/camp-life/'>Camp He Ho Ha Climbing Gym</a><br>
<span class='rt'></span> The Summit is Camp He Ho Ha's 40' climbing gym and ropes course. Facility is available for rent, with safety equipment, orientation to the course and staffing provided.</p>
<div class="city">Calgary</div>
<p><b>Bolder Climbing Community</b><br>
5508 1st Street SE, Calgary, Alberta, Canada<br>
403 988-8140<br>
<a rel='nofollow' target='_blank' href='http://www.bolderclimbing.com/'>Bolder Climbing Community</a><br>
<span class='rt'></span> Calgary's first bouldering specific climbing centre.</p>
我可以很容易地在每个攀岩馆之间移动,因为它们被<p>
隔开,但是我感兴趣的单个项目被<br>
隔开。如何将这些项存储到单独的数组中
你可以这样做。基本上,找到
<br>
标记,然后找到它前面的内容输出:
相关问题 更多 >
编程相关推荐