[英]Edit multiple HTML Files
I have 90 html files where an audio file is played (wrong link), I need to change the src of the audio file in each one of these files. 我有90个html文件,其中播放了一个音频文件(错误的链接),我需要在每个这些文件中更改音频文件的src。
from 从
<embed src="../audio/" autostart=false width=0 height=0 id="sound1" enablejavascript="true">
to: 至:
file 1: 文件1:
<embed src="../audio/1.mp3" autostart=false width=0 height=0 id="sound1" enablejavascript="true">
file 2: 文件2:
<embed src="../audio/2.mp3" autostart=false width=0 height=0 id="sound1" enablejavascript="true">
... ...
Any suggestions for an automated approach? 对自动化方法有何建议? Thanks
谢谢
Later edit: 以后编辑:
The new src is different for each file... any possibilities to fill this automated for each file? 每个文件的新src不同...是否有可能自动为每个文件填充此文件? for file1 -> src1, file2 -> src2 ...
对于file1-> src1,file2-> src2 ...
Notepad ++具有一些不错的搜索和替换功能,您可以在此处使用它们。
GNU sed is what you need: http://www.gnu.org/software/sed/ 您需要的是GNU sed: http : //www.gnu.org/software/sed/
Or eventually gawk: http://www.gnu.org/software/gawk/ 或最终gawk: http ://www.gnu.org/software/gawk/
您使用Dreamweaver软件查找用新的音频名称替换所有文件
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.