You are here

API.txt in Nodewords: D6 Meta Tags 6

Same filename and directory in other branches
  1. 6.3 API.txt
  2. 6.2 API.txt
; This file contains a log of changes to the API.

API version 1.1

* The module uses hook_nodewords_tags_info(), and hook_nodewords_api().
* Functions that before were private are now public.

API version 1.3

* The module uses also hook_nodewords_type_id().
* The function nodewords_output_tags() has been changed from
  nodewords_output_tags($tags) to
  nodewords_output_tags($tags, $output_type = 'head').
* The function nodewords_unique() has been changed from
  nodewords_unique($text, $max_items = 0, $separator = ',') to
  nodewords_unique($text, $separator = ',', $max_items = -1).

API version 1.4

* The function nodewords_metatag_from_teaser() has been changed from
  nodewords_metatag_from_teaser($text, $format, $alt_attribute, $size = 0) to
  nodewords_metatag_from_teaser($text, $format, $options = array()).

API version 1.5

* Changed the name of the constants from NODEWORDS_MT_TYPE_* to
  NODEWORDS_TYPE_*.

API version 1.6

* Changed the function nodewords_get_tags() from
  nodewords_get_tags($type, $ids = array(''), $filtered = TRUE) to
  nodewords_get_tags($type, $ids = array(''), $options = array()).

API version 1.7

* The module uses also hook_nodewords_tags_output_alter().
* The identifier passed to <meta_tag_hander>_settings_form() for the meta tags
  settings form is now the form identifier as used by Drupal
  (nodewords_settings_form).

API version 1.8

* The module uses also hook_nodewords_tags_alter().
* The function nodewords_mass_delete_tags() cannot be used to delete meta tags
  associated with custom pages anymore.

API version 1.9

* The function nodewords_metatag_from_teaser($text, $format, $options = array())
  has been replaced by nodewords_metatag_from_node_content($node, $content, $options = array()).

API version 1.10

* The function nodewords_delete_tags($ids, $type) has been replaced from
  nodewords_mass_update($ids, $type, $options = array()).

API version 1.11

* All the functions nodewords_pages_*() have been renamed nodewords_custom_pages_*().
* A new constant has been introduced (NODEWORDS_TYPE_OFFLINE).
* The function nodewords_get_tags() has been removed.
* The function nodewords_output_tags() is now a private function.
* The function nodewords_unique() has been renamed nodewords_unique_values().
* The parameters for the function nodewords_get_term() have been changed from
  nodewords_get_term($tid) to nodewords_get_term($tid, $account = NULL).
* Added the function nodewords_url($path, $options = array()).

API version 1.12

* The value expected from hook_nodewords_tags_info() has been changed.

Note: the original API 1.12, 1.13 and 1.14 changes from the 6.x-1.12-x codebase
  have been scrapped, all modules that integrate with it must be updated to
  the current API.

API version 1.13

* Support for meta properties via the new NODEWORDS_META_PROPERTY constant, as
  required by the new OpenGraph support. Note that the XHTML specifications do
  not support this attribute so additional steps must be taken to tailor the
  page output as necessary, see the Open Graph section of the README.txt file
  for further details.

API version 1.14

* The page title tag may be controlled via the ['page_title'] tag, though it
  receives special handling in nodewords_preprocess_page() due to Drupal's
  special handling of the TITLE tag vs other HTML head tags.
* New constant NODEWORDS_TYPE_FORUM for custom handling of the core forum
  module's main page.
* For usability purposes, the meta tags have been grouped into related
  categories via their weights (see below). This will allow any other unsorted
  meta tags added by other modules to appear at the end of the list. Other tags
  should keep these in mind and be adjusted as necessary.
* The canonical, short_url and og:url tags are all set to work on all pages
  except:
    * NODEWORDS_TYPE_DEFAULT
    * NODEWORDS_TYPE_ERRORPAGE
    * NODEWORDS_TYPE_OFFLINE
    * NODEWORDS_TYPE_TRACKER
* The page_title, dcterms.title and og:title tags work on all pages except:
    * NODEWORDS_TYPE_DEFAULT
* Meta tags may define a boolean attribute 'multiple' as TRUE; meta tags with
  this setting can have multiple values, each on a separate line, which are
  then output with a separate HTML tag for each one.
* All paths passed through nodewords_url() will now be checked for an alias if
  the "Use path aliases" global setting is enabled (enabled by default).
* By default all non-empty tags will be output, if this does not fit your
  site's needs use hook_nodewords_tags_output_alter() to modify them.
* Added the internal function _nodewords_prepare_path() for simplifying the
  generation of a URL for the current page.
* Added the internal function _nodewords_prepare_description() for simplifying
  the generation of a description field for the current page.
* New constant NODEWORDS_TYPE_BLOG for custom handling of the core blog
  module's main page.
* Changed nodewords_og_form_default() so it also passes in the $options array.


Current meta tag weights, grouped by topic:
  Site information: -209 to -200
    -209: og:site_name
    -208: fb:app_id
    -207: fb:admins
    -206: logo
  Page / document title: -199 to -190
    -199: page title
    -198: dcterms.title
    -197: og.title
  Description: -189 to -180
    -189: description
    -188: dcterms.description
    -187: og.description
    -186: abstract
    -185: keywords
    -184: og:image
    -183: dcterms.date
  Author: -179 to -170
    -179: author
    -178: dcterms.creator
    -177: dcterms.contributor
  Legal: -169 to -160
    -169: rights
  Location: -159 to -150
    -159: location
    -158: og:latitude
    -157: og:longitude
    -156: og:street-address
    -155: og:locality
    -154: og:region
    -153: og:postal-code
    -152: og:country-name
    -151: og:locale
    -151: geo.position
    -150: geo.region
  Media: -149 to -140
    -149: og:type
    -147: og:video
    -146: og:video:width
    -145: og:video:height
    -144: og:video:type
  URL: -139 to 130
    -139: canonical URL
    -138: short URL
    -137: og:url
    -136: revist-after
    -135: standout
    -134: original-source
  Robots: -129 to -120
    -129: robots

File

API.txt
View source
  1. ; This file contains a log of changes to the API.
  2. API version 1.1
  3. * The module uses hook_nodewords_tags_info(), and hook_nodewords_api().
  4. * Functions that before were private are now public.
  5. API version 1.3
  6. * The module uses also hook_nodewords_type_id().
  7. * The function nodewords_output_tags() has been changed from
  8. nodewords_output_tags($tags) to
  9. nodewords_output_tags($tags, $output_type = 'head').
  10. * The function nodewords_unique() has been changed from
  11. nodewords_unique($text, $max_items = 0, $separator = ',') to
  12. nodewords_unique($text, $separator = ',', $max_items = -1).
  13. API version 1.4
  14. * The function nodewords_metatag_from_teaser() has been changed from
  15. nodewords_metatag_from_teaser($text, $format, $alt_attribute, $size = 0) to
  16. nodewords_metatag_from_teaser($text, $format, $options = array()).
  17. API version 1.5
  18. * Changed the name of the constants from NODEWORDS_MT_TYPE_* to
  19. NODEWORDS_TYPE_*.
  20. API version 1.6
  21. * Changed the function nodewords_get_tags() from
  22. nodewords_get_tags($type, $ids = array(''), $filtered = TRUE) to
  23. nodewords_get_tags($type, $ids = array(''), $options = array()).
  24. API version 1.7
  25. * The module uses also hook_nodewords_tags_output_alter().
  26. * The identifier passed to _settings_form() for the meta tags
  27. settings form is now the form identifier as used by Drupal
  28. (nodewords_settings_form).
  29. API version 1.8
  30. * The module uses also hook_nodewords_tags_alter().
  31. * The function nodewords_mass_delete_tags() cannot be used to delete meta tags
  32. associated with custom pages anymore.
  33. API version 1.9
  34. * The function nodewords_metatag_from_teaser($text, $format, $options = array())
  35. has been replaced by nodewords_metatag_from_node_content($node, $content, $options = array()).
  36. API version 1.10
  37. * The function nodewords_delete_tags($ids, $type) has been replaced from
  38. nodewords_mass_update($ids, $type, $options = array()).
  39. API version 1.11
  40. * All the functions nodewords_pages_*() have been renamed nodewords_custom_pages_*().
  41. * A new constant has been introduced (NODEWORDS_TYPE_OFFLINE).
  42. * The function nodewords_get_tags() has been removed.
  43. * The function nodewords_output_tags() is now a private function.
  44. * The function nodewords_unique() has been renamed nodewords_unique_values().
  45. * The parameters for the function nodewords_get_term() have been changed from
  46. nodewords_get_term($tid) to nodewords_get_term($tid, $account = NULL).
  47. * Added the function nodewords_url($path, $options = array()).
  48. API version 1.12
  49. * The value expected from hook_nodewords_tags_info() has been changed.
  50. Note: the original API 1.12, 1.13 and 1.14 changes from the 6.x-1.12-x codebase
  51. have been scrapped, all modules that integrate with it must be updated to
  52. the current API.
  53. API version 1.13
  54. * Support for meta properties via the new NODEWORDS_META_PROPERTY constant, as
  55. required by the new OpenGraph support. Note that the XHTML specifications do
  56. not support this attribute so additional steps must be taken to tailor the
  57. page output as necessary, see the Open Graph section of the README.txt file
  58. for further details.
  59. API version 1.14
  60. * The page title tag may be controlled via the ['page_title'] tag, though it
  61. receives special handling in nodewords_preprocess_page() due to Drupal's
  62. special handling of the TITLE tag vs other HTML head tags.
  63. * New constant NODEWORDS_TYPE_FORUM for custom handling of the core forum
  64. module's main page.
  65. * For usability purposes, the meta tags have been grouped into related
  66. categories via their weights (see below). This will allow any other unsorted
  67. meta tags added by other modules to appear at the end of the list. Other tags
  68. should keep these in mind and be adjusted as necessary.
  69. * The canonical, short_url and og:url tags are all set to work on all pages
  70. except:
  71. * NODEWORDS_TYPE_DEFAULT
  72. * NODEWORDS_TYPE_ERRORPAGE
  73. * NODEWORDS_TYPE_OFFLINE
  74. * NODEWORDS_TYPE_TRACKER
  75. * The page_title, dcterms.title and og:title tags work on all pages except:
  76. * NODEWORDS_TYPE_DEFAULT
  77. * Meta tags may define a boolean attribute 'multiple' as TRUE; meta tags with
  78. this setting can have multiple values, each on a separate line, which are
  79. then output with a separate HTML tag for each one.
  80. * All paths passed through nodewords_url() will now be checked for an alias if
  81. the "Use path aliases" global setting is enabled (enabled by default).
  82. * By default all non-empty tags will be output, if this does not fit your
  83. site's needs use hook_nodewords_tags_output_alter() to modify them.
  84. * Added the internal function _nodewords_prepare_path() for simplifying the
  85. generation of a URL for the current page.
  86. * Added the internal function _nodewords_prepare_description() for simplifying
  87. the generation of a description field for the current page.
  88. * New constant NODEWORDS_TYPE_BLOG for custom handling of the core blog
  89. module's main page.
  90. * Changed nodewords_og_form_default() so it also passes in the $options array.
  91. Current meta tag weights, grouped by topic:
  92. Site information: -209 to -200
  93. -209: og:site_name
  94. -208: fb:app_id
  95. -207: fb:admins
  96. -206: logo
  97. Page / document title: -199 to -190
  98. -199: page title
  99. -198: dcterms.title
  100. -197: og.title
  101. Description: -189 to -180
  102. -189: description
  103. -188: dcterms.description
  104. -187: og.description
  105. -186: abstract
  106. -185: keywords
  107. -184: og:image
  108. -183: dcterms.date
  109. Author: -179 to -170
  110. -179: author
  111. -178: dcterms.creator
  112. -177: dcterms.contributor
  113. Legal: -169 to -160
  114. -169: rights
  115. Location: -159 to -150
  116. -159: location
  117. -158: og:latitude
  118. -157: og:longitude
  119. -156: og:street-address
  120. -155: og:locality
  121. -154: og:region
  122. -153: og:postal-code
  123. -152: og:country-name
  124. -151: og:locale
  125. -151: geo.position
  126. -150: geo.region
  127. Media: -149 to -140
  128. -149: og:type
  129. -147: og:video
  130. -146: og:video:width
  131. -145: og:video:height
  132. -144: og:video:type
  133. URL: -139 to 130
  134. -139: canonical URL
  135. -138: short URL
  136. -137: og:url
  137. -136: revist-after
  138. -135: standout
  139. -134: original-source
  140. Robots: -129 to -120
  141. -129: robots