Board logo

标题: [求助]BAT提取问题 [打印本页]

作者: 3dnowex     时间: 2010-7-7 19:07    标题: [求助]BAT提取问题

原文件:

<div id="_mcePaste" style="position: absolute; left: -10000px; top: 95px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;"><li id="1694898" class="__tora_bbcode  ext_7z"><input type="hidden" class="size" value="448955" /><a href="javascript:BlogUtil.download('1694898')" class="file_name">ClannadFV.7z</a><var class="size">438.43 M</var></li></div>
<p><div class="filequote jsbox jsbox_lblge"><div class="jsbox_inner"><span class="box_t"><span></span></span><div class="box_content"><div class="quote_title">引用的资源</div><ul><li id="1694898" class="__tora_bbcode  ext_7z"><input type="hidden" class="size" value="448955" /><a href="javascript:BlogUtil.download('1694898')" class="file_name">ClannadFV.7z</a><var class="size">438.43 M</var></li></ul></div><span class="box_b"><span></span></span></div></div></p>
<p><div class="filequote jsbox jsbox_lblge"><div class="jsbox_inner"><span class="box_t"><span></span></span><div class="box_content"><div class="quote_title">引用的资源</div><ul><li id="1694896" class="__tora_bbcode  ext_7z"><input type="hidden" class="size" value="133583" /><a href="javascript:BlogUtil.download('1694896')" class="file_name">TomoyoAfter.7z</a><var class="size">130.45 M</var></li></ul></div><span class="box_b"><span></span></span></div></div></p>
<p><div class="filequote jsbox jsbox_lblge"><div class="jsbox_inner"><span class="box_t"><span></span></span><div class="box_content"><div class="quote_title">引用的资源</div><ul><li id="1694899" class="__tora_bbcode  ext_7z"><input type="hidden" class="size" value="461750" /><a href="javascript:BlogUtil.download('1694899')" class="file_name">LBEX.7z</a><var class="size">450.93 M</var></li></ul></div><span class="box_b"><span></span></span></div></div></p>
<p><div class="filequote jsbox jsbox_lblge"><div class="jsbox_inner"><span class="box_t"><span></span></span><div class="box_content"><div class="quote_title">引用的资源</div><ul><li id="1694897" class="__tora_bbcode  ext_7z"><input type="hidden" class="size" value="287393" /><a href="javascript:BlogUtil.download('1694897')" class="file_name">ef_first.7z</a><var class="size">280.66 M</var></li></ul></div><span class="box_b"><span></span></span></div></div></p>

请问如何将<a href="javascript:BlogUtil.download('1694897')" class="file_name">中间1694897这段数字提取出来?
作者: qinchun36     时间: 2010-7-8 18:16
@echo off
for /f "tokens=2 delims='" %%a in ('type aaaaa.txt') do echo %%a
pause>nul
作者: 3dnowex     时间: 2010-7-8 20:13
请问、、如果是双引号的话如何解决??
可以用SED读取特定标签内的内容吗??
作者: 3dnowex     时间: 2010-7-8 23:06
比如说、搜索id="1694899"类似的东西。。我使用CODE
findstr "id=".......""显示出的是其所在行而不是”id="1694899"“
请问如何显示出”id="1694899"“?而不是整行?