Surprisingly I got a end of document in prolog error from my trusted HTML validation service – the W3C validator located at validator.w3.org. Obviously, I had no idea what the error was… and as far as I was concerned, the document shouldn’t have had any. I checked the document thoroughly and ran the validation a second time – no luck. I got the error again.
HTML validation error from W3C Validator
Apparently, as per W3C HTML validator, this error may appear when the validator receives an empty document. OK! I uploaded it once again (sFTP) to the web server and opened it in a browser – it looked fine. Maybe there is something wrong with the server, I thought. It’s probably blocking the W3C validation service from accessing web pages and that’s why it’s getting an empty document. Web searches, by the way, did not help much.
So I used the direct upload feature of the W3C HTML validator and got the error yet again. I finally checked up a web page which I knew was 100% valid. Well, it wasn’t now. And this is when I understood that the problem wasn’t with the pages I was testing but the W3C validation service. I got up to make a nice cup of tea and when I came back, the problems had been ironed out.
Conclusions: Firstly, if something is giving an error or not working as its supposed to, there is no need to fret – check the alternative (direct input as opposed to validation by URI). Secondly, the web doesn’t provide a solution for everything. Thirdly, do not trust everything – even the best can fail sometimes. Fourthly, take a time-out – a cup of tea always helps.