perl 正则 提取时间

perl 正则 提取时间

各位老大,我知道这还是老话题!
小弟实在没办法。上头催的紧,只好向各位高人求助啦! 如下:

这是一段HTML源码
   <a href="/showtime/China_Beijing_Chaoyang/1474/44706/3348991.html" target="_blank"><span class="m_s57">2</span>10<span class="m_s32">6</span>:0<span class="m_s49">5</span><span class="m_s38">9</span><span class="m_s28">0</span></a><span>|</span><a href="/showtime/China_Beijing_Chaoyang/1474/44706/3348992.html" target="_blank"><span class="m_s34">1</span>12<span class="m_s7">1</span>:<span class="m_s34">:</span>0<span class="m_s47">9</span><span class="m_s40">0</span></a><span>|</span><a href="/showtime/China_Beijing_Chaoyang/1474/44706/3348993.html" target="_blank"><span class="m_s44">8</span>14<span class="m_s48"> </span>:0<span class="m_s53"> </span>0<span class="m_s43">9</span></a><span>|</span><a href="/showtime/China_Beijing_Chaoyang/1474/44706/3348994.html" target="_blank">1<span class="m_s47">4</span><span class="m_s58">6</span>:0<span class="m_s18">0</span>0</a><span>|</span><a href="/showtime/China_Beijing_Chaoyang/1474/44706/3348995.html" target="_blank"><span class="m_s42"> </span><span class="m_s51">1</span>8:<span class="m_s41">7</span>0<span class="m_s62">9</span>0</a><span>|</span><a href="/showtime/China_Beijing_Chaoyang/1474/44706/3348996.html" target="_blank"><span class="m_s38">8</span><span class="m_s30">2</span>0:<span class="m_s33">:</span><span class="m_s39">0</span><span class="m_s28">0</span></a><span>|</span><a href="/showtime/China_Beijing_Chaoyang/1474/44706/3348997.html" target="_blank"><span class="m_s52">5</span><span class="m_s9">2</span>2<span class="m_s31">7</span>:<span class="m_s57">:</span><span class="m_s40">1</span><span class="m_s23">0</span></a>



需要的结果如下:


10:00|12::00|14:00|16:00|18:00|20:00|22:10

我要把时间提取出来! 这段码我觉得很乱,中间加入了别的效果,不知道能不能用perl的正则解决!清各位老大明示.
$str =~ s/<.*?>//g;
谢谢 楼上的老大!

您可能没有看清楚源码 呵呵

$str =~ s/<.*?>//g 的结果

2106:0590|1121::090|814 :0 09|146:000| 18:7090|820::00|5227::10
我试了一下 好像只能提出2106:0590|1121::090|814 :0 09|146:000| 18:7090|820::00|5227::10 这个
这会是最终结果吗?
thanks for guijia8427!
说实话没看出来你源文件里的时间在哪儿...
呵呵! 可是页面上显示的时间确实是这样的
10:00|12::00|14:00|16:00|18:00|20:00|22:10

源文件的代码里应该是加了某些东西,因为他要让显示的时间小于系统时间后抛弃链接地址
@arr=($str=~/(?:<\/span>|<span>)(.*?)</g);
试试这个 看行不行

还是不行阿  老大
我发现代码里面个别数字好像是用来计时的 随时变化的


QUOTE:
原帖由 changejun 于 2008-7-31 10:13 发表
还是不行阿  老大
我发现代码里面个别数字好像是用来计时的 随时变化的

那你得找出来啊 不然我们怎么能从这么小段代码中看出来啊 没法帮你弄啊 我们只能按照这段源码解析啊