@echo off
rem 使用了第三方命令工具sed.exe(4.1.4)
set "htmlDir=C:\test\a"
echo Please wait for minutes...
for /r "%htmlDir%" %%a in (*.html) do (
sed -i "s/<img src=\"images\/default\/logo\.gif\" alt=\"Board logo\" border=\"0\">//g" "%%a"
)
for /r "C:\Test\批处理室经典帖子合集初步整理结果2008A\" %%a in (*.txt) do (
for /f "usebackq tokens=2-3 delims={}" %%h in ("%%a") do (
ren "%htmlDir%\%%h".html "%%i.html"
)
)