reference-entry-enclosures.rst 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. .. _reference.entry.enclosures:
  2. :py:attr:`entries[i].enclosures`
  3. ================================
  4. A list of links to external files associated with this entry.
  5. Some aggregators automatically download enclosures (although this technique has
  6. `known problems <http://gonze.com/weblog/story/5-17-4>`_). Some aggregators
  7. render each enclosure as a link. Most aggregators ignore them.
  8. The :abbr:`RSS (Rich Site Summary)` specification states that there can be at
  9. most one enclosure per item. However, because some feeds break this rule,
  10. :program:`Universal Feed Parser` captures all of them and makes them available
  11. as a list.
  12. .. rubric:: Comes from
  13. - /atom10:feed/atom10:entry/atom10:link[@rel="enclosure"]
  14. - /rss/channel/item/enclosure
  15. .. _reference.entry.enclosures.href:
  16. :py:attr:`entries[i].enclosures[j].href`
  17. ----------------------------------------
  18. The :abbr:`URL (Uniform Resource Locator)` of the linked file.
  19. If this is a relative :abbr:`URI (Uniform Resource Identifier)`, it is
  20. :ref:`resolved according to a set of rules <advanced.base>`.
  21. .. _reference.entry.enclosures.length:
  22. :py:attr:`entries[i].enclosures[j].length`
  23. ------------------------------------------
  24. The length of the linked file.
  25. .. _reference.entry.enclosures.type:
  26. :py:attr:`entries[i].enclosures[j].type`
  27. ----------------------------------------
  28. The content type of the linked file.