W3C validator says 'feed does not validate' 'url must be a full URL'… whats wrong with it?

给你一囗甜甜゛ 提交于 2019-12-03 16:54:09

问题


Validating my feed, it has an enclosure with a URL of

https://archive.org/download/NigelFarageAPersonalMessageToNorthernIrelandVoters./Nigel%20Farage,%20a%20personal%20message%20to%20Northern%20Ireland%20voters..mp3

I know it is a bit convoluted... but what is wrong with it? The stop in the directory name? the double dot in the file name? the comma? all of em?

I have looked at the RFC on URL's but cant make it out(!).

This feed does not validate.
line 441, column 2: url must be a full URL: https://archive.org/download/NigelFarageAPersonalMessageToNorthernIrelandVoters./Nigel%20Farage,%20a%20personal%20message%20to%20Northern%20Ireland%20voters..mp3 (4 occurrences) [help]
  <enclosure type="audio/mpeg" url="https://archive.org/download/NigelFarage ...
  ^

** edit **

A useful (even if incorrect) answer was added (and removed...) showing the result from the w3c URL validator - https://validator.w3.org/checklink

This Link Checker looks for issues in links, anchors and referenced objects in a Web page, CSS style sheet, or recursively on a whole Web site. For best results, it is recommended to first ensure that the documents checked use Valid (X)HTML Markup and CSS. The Link Checker is part of the W3C's validators and Quality Web tools.

If you find this question, you may find the link checker a useful resource!


回答1:


The problem seems to be that it’s a HTTPS URL instead of a HTTP URL.

The linked error documentation, foo attribute of bar must be a full URL, says:

If this is a link to a web page, you must include the "http://" at the beginning and immediately follow it with a valid domain name.

The RSS 2.0 spec says about <enclosure>:

The url must be an http url.

If you change https://archive.org/download/… to http://archive.org/download/…, it validates.




回答2:


And if you don't have httpS then your SSL says your page isn't secure. #feedvalidator step up. There are a ton of feedback/complaints about this on the support forum here https://groups.google.com/forum/#!forum/feedvalidator-users

More specifically here: https://github.com/rubys/feedvalidator/issues/16



来源:https://stackoverflow.com/questions/29985571/w3c-validator-says-feed-does-not-validate-url-must-be-a-full-url-whats-wr

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!