Find/Replace but Increment Value

后端 未结 7 721
庸人自扰
庸人自扰 2020-12-31 18:35

I have an .HTML file that has many photos attached to it for displaying a photo gallery. I\'m replacing old photos with new ones, and I\'m thinking there must be a more inte

7条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-31 19:15

    There is. Create your list of photos using a python script that looks at whatever directory you want, and renames or just lists all the file names. Then go from that to a python script that generates the HTML you need (should be very easy at this point). Then copy & paste that.

    Python is very easy to use, you will be able to download it in 5 minutes & find a tutorial for reading / changing file names in another 10 minutes.

提交回复
热议问题