I'm saving many text files. Filenames are urls. File has whole html of webpage from url. All text files are saved in one folder.
My problem: I need to compare two files of same url, but how?
- filenames of same webpage 开发者_JAVA百科are the same, I cant save 2 files with the same name.
- add version of url is stupid because I cant add it into my webapplication.
Please help me how can I save two files of same webpage and compare their content.
Are you checking this URL at two different times? I would imagine so, because if you checked it twice in a row then there would be no changes. So if you are checking at different times, why not place each one into a subfolder named after the date:
/etc/2011-01-02 2255/web-page-url.text
/etc/2011-02-02 2255/web-page-url.text
Then you don't have top worry about the two files having the same name.
精彩评论