问题
Almost every time you save a web page from a web browser to your local computer a PAGENAME.html(htm) file is created and a folder named 'PAGENAME_files' that contains resources specific to that page.
If you copy/move/delete either the folder or the .html file windows automatically does the same operation the other file as well.
This behaviour also happens if you create a file named 1.html and a folder called 1_files.
How does this link happen? And Why it works only with web files?
Edit: For those who are downvoting please explain the reason. I did searches on google and came up with nothing. The same thing on Stackoverflow.
回答1:
This is a shell feature, not a file system feature. The shell copy engine just looks for a folder with the same name (plus a localized suffix) when copying/moving .htm[l] files.
This feature is called Connected Files and is documented here.
回答2:
It's a built-in linkage in Windows.
Open up Explorer (not IE, Windows), Tools, Options, View, then in Advanced Settings there'll be a "Managing pairs of Web pages and folders" section.
回答3:
If people are stuck and ended up here to find how to unlink, here's an easy trick : on Windows 10, I couldn't find how to unlink a .html file from its associated media folder, so I deleted both of them, and in the bin I restored only the .html file and it was then restored and unlinked from its folder.
来源:https://stackoverflow.com/questions/45614929/how-does-windows-link-html-files-to-folders