metatag_opengraph.metatag.inc 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609
  1. <?php
  2. /**
  3. * @file
  4. * Metatag integration for the metatag_opengraph module.
  5. */
  6. /**
  7. * Implements hook_metatag_bundled_config_alter().
  8. */
  9. function metatag_opengraph_metatag_bundled_config_alter(array &$configs) {
  10. foreach ($configs as &$config) {
  11. switch ($config->instance) {
  12. case 'global':
  13. $config->config += array(
  14. 'og:site_name' => array('value' => '[site:name]'),
  15. 'og:title' => array('value' => '[current-page:title]'),
  16. 'og:type' => array('value' => 'article'),
  17. 'og:url' => array('value' => '[current-page:url:absolute]'),
  18. );
  19. break;
  20. case 'global:frontpage':
  21. $config->config += array(
  22. 'og:description' => array('value' => '[site:slogan]'),
  23. 'og:title' => array('value' => '[site:name]'),
  24. 'og:type' => array('value' => 'website'),
  25. 'og:url' => array('value' => '[site:url]'),
  26. );
  27. break;
  28. // On error pages point everything to the homepage.
  29. case 'global:403':
  30. case 'global:404':
  31. $config->config += array(
  32. 'og:title' => array('value' => '[site:name]'),
  33. 'og:type' => array('value' => 'website'),
  34. 'og:url' => array('value' => '[site:url]'),
  35. );
  36. break;
  37. case 'node':
  38. $config->config += array(
  39. 'article:modified_time' => array('value' => '[node:changed:custom:c]'),
  40. 'article:published_time' => array('value' => '[node:created:custom:c]'),
  41. 'og:description' => array('value' => '[node:summary]'),
  42. 'og:title' => array('value' => '[node:title]'),
  43. 'og:updated_time' => array('value' => '[node:changed:custom:c]'),
  44. );
  45. break;
  46. case 'taxonomy_term':
  47. $config->config += array(
  48. 'og:description' => array('value' => '[term:description]'),
  49. 'og:title' => array('value' => '[term:name]'),
  50. );
  51. break;
  52. case 'user':
  53. $config->config += array(
  54. 'og:title' => array('value' => '[user:name]'),
  55. 'og:type' => array('value' => 'profile'),
  56. 'profile:username' => array('value' => '[user:name]'),
  57. );
  58. if (variable_get('user_pictures')) {
  59. $config->config += array(
  60. 'og:image' => array('value' => '[user:picture:url]'),
  61. );
  62. }
  63. break;
  64. }
  65. }
  66. }
  67. /**
  68. * Implements hook_metatag_info().
  69. */
  70. function metatag_opengraph_metatag_info() {
  71. $info['groups']['open-graph'] = array(
  72. 'label' => t('Open Graph'),
  73. 'description' => t("The <a href=\"@ogp\">Open Graph meta tags</a> are used control how Facebook, LinkedIn an other social networking sites interpret the site's content.", array('@ogp' => 'http://ogp.me/')),
  74. 'form' => array(
  75. '#weight' => 50,
  76. ),
  77. );
  78. // Default values for each meta tag.
  79. $og_defaults = array(
  80. 'description' => '',
  81. 'class' => 'DrupalTextMetaTag',
  82. 'group' => 'open-graph',
  83. 'element' => array(
  84. '#theme' => 'metatag_property',
  85. ),
  86. );
  87. // Open Graph meta tags stack after the Facebook tags.
  88. $weight = 25;
  89. $info['tags']['og:site_name'] = array(
  90. 'label' => t('Site name'),
  91. 'description' => t('A human-readable name for the site, e.g., <em>IMDb</em>.'),
  92. 'context' => array('global'),
  93. 'weight' => ++$weight,
  94. ) + $og_defaults;
  95. $info['tags']['og:type'] = array(
  96. 'label' => t('Content type'),
  97. 'description' => t('The type of the content, e.g., <em>movie</em>.'),
  98. 'weight' => ++$weight,
  99. 'form' => array(
  100. '#type' => 'select',
  101. '#options' => _metatag_opengraph_type_options(),
  102. '#empty_option' => t('- None -'),
  103. ),
  104. 'devel_generate' => array(
  105. 'type' => 'select',
  106. ),
  107. ) + $og_defaults;
  108. $info['tags']['og:url'] = array(
  109. 'label' => t('Page URL'),
  110. 'description' => t('Preferred page location or URL to help eliminate duplicate content for search engines, e.g., <em>http://www.imdb.com/title/tt0117500/</em>.'),
  111. 'weight' => ++$weight,
  112. 'devel_generate' => array(
  113. 'type' => 'canonical',
  114. ),
  115. ) + $og_defaults;
  116. if (module_exists('select_or_other')) {
  117. // Enhance the og:type field to support custom types.
  118. $info['tags']['og:type']['form']['#type'] = 'select_or_other';
  119. $info['tags']['og:type']['form']['#other'] = t('Other (please type a value)');
  120. $info['tags']['og:type']['form']['#other_unknown_defaults'] = 'other';
  121. $info['tags']['og:type']['form']['#theme'] = 'select_or_other';
  122. $info['tags']['og:type']['form']['#element_validate'] = array('select_or_other_element_validate');
  123. }
  124. $info['tags']['og:title'] = array(
  125. 'label' => t('Content title'),
  126. 'description' => t('The title of the content, e.g., <em>The Rock</em>.'),
  127. 'weight' => ++$weight,
  128. ) + $og_defaults;
  129. $info['tags']['og:determiner'] = array(
  130. 'label' => t('Content title determiner'),
  131. 'description' => t("The word that appears before the content's title in a sentence. The default ignores this value, the 'Automatic' value should be sufficient if this is actually needed."),
  132. 'weight' => ++$weight,
  133. 'form' => array(
  134. '#type' => 'select',
  135. '#options' => array(
  136. 'auto' => 'Automatic',
  137. 'a' => 'A',
  138. 'an' => 'An',
  139. 'the' => 'The',
  140. ),
  141. '#empty_option' => t('- Ignore -'),
  142. ),
  143. 'devel_generate' => array(
  144. 'type' => 'select',
  145. ),
  146. ) + $og_defaults;
  147. $info['tags']['og:description'] = array(
  148. 'label' => t('Content description'),
  149. 'description' => t('A one to two sentence description of the content.'),
  150. 'weight' => ++$weight,
  151. ) + $og_defaults;
  152. // Basic tags.
  153. $info['tags']['og:updated_time'] = array(
  154. 'label' => t('Content modification date & time'),
  155. 'description' => t("The date this content was last modified, with an optional time value. Needs to be in <a href='http://en.wikipedia.org/wiki/ISO_8601'>ISO 8601</a> format. Can be the same as the 'Article modification date' tag."),
  156. 'weight' => ++$weight,
  157. ) + $og_defaults;
  158. $info['tags']['og:see_also'] = array(
  159. 'label' => t('See also'),
  160. 'description' => t('URLs to related content.'),
  161. 'multiple' => TRUE,
  162. 'weight' => ++$weight,
  163. ) + $og_defaults;
  164. $info['tags']['og:image'] = array(
  165. 'label' => t('Image URL'),
  166. 'description' => t('The URL of an image which should represent the content. For best results use an image that is at least 1200 x 630 pixels in size, but at least 600 x 316 pixels is a recommended minimum. Supports PNG, JPEG and GIF formats.'),
  167. 'multiple' => TRUE,
  168. 'weight' => ++$weight,
  169. 'devel_generate' => array(
  170. 'type' => 'image',
  171. ),
  172. ) + $og_defaults;
  173. $info['tags']['og:image:secure_url'] = array(
  174. 'label' => t('Secure image URL'),
  175. 'description' => t('The secure URL (HTTPS) of an image which should represent the content. The image must be at least 50px by 50px and have a maximum aspect ratio of 3:1. Supports PNG, JPEG and GIF formats. All "http://" URLs will automatically be converted to "https://".'),
  176. 'multiple' => TRUE,
  177. 'secure' => TRUE,
  178. 'weight' => ++$weight,
  179. 'devel_generate' => array(
  180. 'type' => 'image',
  181. ),
  182. ) + $og_defaults;
  183. $info['tags']['og:image:type'] = array(
  184. 'label' => t('Image type'),
  185. 'description' => t('The type of image referenced above. Should be either "image/gif" for a GIF image, "image/jpeg" for a JPG/JPEG image, or "image/png" for a PNG image.'),
  186. 'multiple' => TRUE,
  187. 'weight' => ++$weight,
  188. ) + $og_defaults;
  189. $info['tags']['og:image:width'] = array(
  190. 'label' => t('Image width'),
  191. 'description' => t('The width of the above image(s). Note: if both the unsecured and secured images are provided, they should both be the same size.'),
  192. 'multiple' => TRUE,
  193. 'weight' => ++$weight,
  194. 'devel_generate' => array(
  195. 'type' => 'image',
  196. ),
  197. ) + $og_defaults;
  198. $info['tags']['og:image:height'] = array(
  199. 'label' => t('Image height'),
  200. 'description' => t('The height of the above image(s). Note: if both the unsecured and secured images are provided, they should both be the same size.'),
  201. 'multiple' => TRUE,
  202. 'weight' => ++$weight,
  203. 'devel_generate' => array(
  204. 'type' => 'image',
  205. ),
  206. ) + $og_defaults;
  207. $info['tags']['og:latitude'] = array(
  208. 'label' => t('Latitude'),
  209. 'weight' => ++$weight,
  210. 'devel_generate' => array(
  211. 'type' => 'float',
  212. ),
  213. ) + $og_defaults;
  214. $info['tags']['og:longitude'] = array(
  215. 'label' => t('Longitude'),
  216. 'weight' => ++$weight,
  217. 'devel_generate' => array(
  218. 'type' => 'float',
  219. ),
  220. ) + $og_defaults;
  221. $info['tags']['og:street-address'] = array(
  222. 'label' => t('Street address'),
  223. 'weight' => ++$weight,
  224. ) + $og_defaults;
  225. $info['tags']['og:locality'] = array(
  226. 'label' => t('Locality'),
  227. 'weight' => ++$weight,
  228. ) + $og_defaults;
  229. $info['tags']['og:region'] = array(
  230. 'label' => t('Region'),
  231. 'weight' => ++$weight,
  232. ) + $og_defaults;
  233. $info['tags']['og:postal-code'] = array(
  234. 'label' => t('Postal/ZIP code'),
  235. 'weight' => ++$weight,
  236. ) + $og_defaults;
  237. $info['tags']['og:country-name'] = array(
  238. 'label' => t('Country name'),
  239. 'weight' => ++$weight,
  240. ) + $og_defaults;
  241. $info['tags']['og:email'] = array(
  242. 'label' => t('Email'),
  243. 'weight' => ++$weight,
  244. 'devel_generate' => array(
  245. 'type' => 'email',
  246. ),
  247. ) + $og_defaults;
  248. $info['tags']['og:phone_number'] = array(
  249. 'label' => t('Phone number'),
  250. 'weight' => ++$weight,
  251. 'devel_generate' => array(
  252. 'type' => 'phone',
  253. ),
  254. ) + $og_defaults;
  255. $info['tags']['og:fax_number'] = array(
  256. 'label' => t('Fax number'),
  257. 'weight' => ++$weight,
  258. 'devel_generate' => array(
  259. 'type' => 'phone',
  260. ),
  261. ) + $og_defaults;
  262. $info['tags']['og:locale'] = array(
  263. 'label' => t('Locale'),
  264. 'description' => 'The locale these tags are marked up in, must be in the format language_TERRITORY. Default is en_US.',
  265. 'weight' => ++$weight,
  266. 'devel_generate' => array(
  267. 'maxlength' => 1,
  268. ),
  269. ) + $og_defaults;
  270. $info['tags']['og:locale:alternate'] = array(
  271. 'label' => t('Alternative locales'),
  272. 'description' => 'Other locales this content is available in, must be in the format language_TERRITORY, e.g. "fr_FR".',
  273. 'weight' => ++$weight,
  274. 'multiple' => TRUE,
  275. 'devel_generate' => array(
  276. 'maxlength' => 1,
  277. ),
  278. ) + $og_defaults;
  279. // For the "article" og:type.
  280. $article_defaults = array(
  281. 'dependencies' => array(
  282. array(
  283. 'dependency' => 'og:type',
  284. 'attribute' => 'value',
  285. 'condition' => 'value',
  286. 'value' => 'article',
  287. ),
  288. ),
  289. );
  290. $info['tags']['article:author'] = array(
  291. 'label' => t('Article author'),
  292. 'description' => t("Links an article to an author's Facebook profile, should be either URLs to the author's profile page or their Facebook profile IDs."),
  293. 'multiple' => TRUE,
  294. 'weight' => ++$weight,
  295. ) + $og_defaults + $article_defaults;
  296. $info['tags']['article:publisher'] = array(
  297. 'label' => t('Article publisher'),
  298. 'description' => t("Links an article to a publisher's Facebook page."),
  299. 'weight' => ++$weight,
  300. ) + $og_defaults + $article_defaults;
  301. $info['tags']['article:section'] = array(
  302. 'label' => t('Article section'),
  303. 'description' => t('The primary section of this website the content belongs to.'),
  304. 'weight' => ++$weight,
  305. ) + $og_defaults + $article_defaults;
  306. $info['tags']['article:tag'] = array(
  307. 'label' => t('Article tag(s)'),
  308. 'description' => t('Appropriate keywords for this content.'),
  309. 'multiple' => TRUE,
  310. 'weight' => ++$weight,
  311. ) + $og_defaults + $article_defaults;
  312. $info['tags']['article:published_time'] = array(
  313. 'label' => t('Article publication date & time'),
  314. 'description' => t("The date this content was published on, with an optional time value. Needs to be in <a href='http://en.wikipedia.org/wiki/ISO_8601'>ISO 8601</a> format."),
  315. 'weight' => ++$weight,
  316. ) + $og_defaults + $article_defaults;
  317. $info['tags']['article:modified_time'] = array(
  318. 'label' => t('Article modification date & time'),
  319. 'description' => t("The date this content was last modified, with an optional time value. Needs to be in <a href='http://en.wikipedia.org/wiki/ISO_8601'>ISO 8601</a> format."),
  320. 'weight' => ++$weight,
  321. ) + $og_defaults + $article_defaults;
  322. $info['tags']['article:expiration_time'] = array(
  323. 'label' => t('Article expiration date & time'),
  324. 'description' => t("The date this content will expire, with an optional time value. Needs to be in <a href='http://en.wikipedia.org/wiki/ISO_8601'>ISO 8601</a> format."),
  325. 'weight' => ++$weight,
  326. ) + $og_defaults + $article_defaults;
  327. // For the "profile" og:type.
  328. $profile_defaults = array(
  329. 'dependencies' => array(
  330. array(
  331. 'dependency' => 'og:type',
  332. 'attribute' => 'value',
  333. 'condition' => 'value',
  334. 'value' => 'profile',
  335. ),
  336. ),
  337. );
  338. $info['tags']['profile:first_name'] = array(
  339. 'label' => t('First name'),
  340. 'description' => t("The first name of the person who's Profile page this is."),
  341. 'weight' => ++$weight,
  342. ) + $og_defaults + $profile_defaults;
  343. $info['tags']['profile:last_name'] = array(
  344. 'label' => t('Last name'),
  345. 'description' => t("The person's last name."),
  346. 'weight' => ++$weight,
  347. ) + $og_defaults + $profile_defaults;
  348. $info['tags']['profile:username'] = array(
  349. 'label' => t('Username'),
  350. 'description' => t("A pseudonym / alias of this person."),
  351. 'weight' => ++$weight,
  352. ) + $og_defaults + $profile_defaults;
  353. $info['tags']['profile:gender'] = array(
  354. 'label' => t('Gender'),
  355. 'description' => t("Any of Facebook's gender values should be allowed, the initial two being 'male' and 'female'."),
  356. 'weight' => ++$weight,
  357. ) + $og_defaults + $profile_defaults;
  358. // Tags related to audio.
  359. $info['tags']['og:audio'] = array(
  360. 'label' => t('Audio URL'),
  361. 'description' => t('The URL to an audio file that complements this object.'),
  362. 'weight' => ++$weight,
  363. 'devel_generate' => array(
  364. 'type' => 'url',
  365. ),
  366. ) + $og_defaults;
  367. $info['tags']['og:audio:secure_url'] = array(
  368. 'label' => t('Audio secure URL'),
  369. 'description' => t('The secure URL to an audio file that complements this object. All "http://" URLs will automatically be converted to "https://".'),
  370. 'weight' => ++$weight,
  371. 'devel_generate' => array(
  372. 'type' => 'url',
  373. ),
  374. ) + $og_defaults;
  375. $info['tags']['og:audio:type'] = array(
  376. 'label' => t('Audio type'),
  377. 'description' => t('The MIME type of the audio file. Examples include "application/mp3" for an MP3 file.'),
  378. 'weight' => ++$weight,
  379. ) + $og_defaults;
  380. // For the "book" og:type.
  381. $book_defaults = array(
  382. 'dependencies' => array(
  383. array(
  384. 'dependency' => 'og:type',
  385. 'attribute' => 'value',
  386. 'condition' => 'value',
  387. 'value' => 'book',
  388. ),
  389. ),
  390. );
  391. $info['tags']['book:author'] = array(
  392. 'label' => t("Book's author"),
  393. 'description' => t("Links to the book's author's Facebook profile, should be either URLs to the author's profile page or their Facebook profile IDs."),
  394. 'multiple' => TRUE,
  395. 'weight' => ++$weight,
  396. ) + $og_defaults + $book_defaults;
  397. $info['tags']['book:isbn'] = array(
  398. 'label' => t("Book's ISBN"),
  399. 'description' => t("The book's <a href=\"http://en.wikipedia.org/wiki/International_Standard_Book_Number\">International Standard Book Number</a>, which may be in one of several formats."),
  400. 'weight' => ++$weight,
  401. ) + $og_defaults + $book_defaults;
  402. $info['tags']['book:release_date'] = array(
  403. 'label' => t('Book release date'),
  404. 'description' => t("The date this content will expire, with an optional time value. Needs to be in <a href='http://en.wikipedia.org/wiki/ISO_8601'>ISO 8601</a> format."),
  405. 'weight' => ++$weight,
  406. ) + $og_defaults + $book_defaults;
  407. $info['tags']['book:tag'] = array(
  408. 'label' => t('Book tags'),
  409. 'description' => t('Appropriate keywords for this book.'),
  410. 'multiple' => TRUE,
  411. 'weight' => ++$weight,
  412. ) + $og_defaults + $book_defaults;
  413. // For the "video" og:type.
  414. $video_defaults = array();
  415. // 'dependencies' => array(
  416. // array(
  417. // 'dependency' => 'og:type',
  418. // 'attribute' => 'value',
  419. // 'condition' => 'value',
  420. // 'value' => 'profile',
  421. // ),
  422. // ),
  423. // );
  424. $info['tags']['og:video'] = array(
  425. 'label' => t('Video URL'),
  426. 'description' => t('The URL to a video file that complements this object.'),
  427. 'weight' => ++$weight,
  428. 'devel_generate' => array(
  429. 'type' => 'url',
  430. ),
  431. ) + $og_defaults;
  432. $info['tags']['og:video:secure_url'] = array(
  433. 'label' => t('Video secure URL'),
  434. 'description' => t('A URL to a video file that complements this object using the HTTPS protocol. All "http://" URLs will automatically be converted to "https://".'),
  435. 'secure' => TRUE,
  436. 'weight' => ++$weight,
  437. 'devel_generate' => array(
  438. 'type' => 'url',
  439. ),
  440. ) + $og_defaults;
  441. $info['tags']['og:video:width'] = array(
  442. 'label' => t('Video width'),
  443. 'description' => t('The width of the video.'),
  444. 'weight' => ++$weight,
  445. 'devel_generate' => array(
  446. 'type' => 'integer',
  447. ),
  448. ) + $og_defaults;
  449. $info['tags']['og:video:height'] = array(
  450. 'label' => t('Video height'),
  451. 'description' => t('The height of the video.'),
  452. 'weight' => ++$weight,
  453. 'devel_generate' => array(
  454. 'type' => 'integer',
  455. ),
  456. ) + $og_defaults;
  457. $info['tags']['og:video:type'] = array(
  458. 'label' => t('Video type'),
  459. 'description' => t('The MIME type of the video file. Examples include "application/x-shockwave-flash" for a Flash video, or "text/html" if this is a standalone web page containing a video.'),
  460. 'weight' => ++$weight,
  461. ) + $og_defaults;
  462. $info['tags']['video:actor'] = array(
  463. 'label' => t('Actor(s)'),
  464. 'description' => t('Links to the Facebook profiles for actor(s) that appear in the video.'),
  465. 'multiple' => TRUE,
  466. 'weight' => ++$weight,
  467. ) + $og_defaults + $video_defaults;
  468. $info['tags']['video:actor:role'] = array(
  469. 'label' => t("Actors' role"),
  470. 'description' => t("The roles of the actor(s)."),
  471. 'multiple' => TRUE,
  472. 'weight' => ++$weight,
  473. ) + $og_defaults + $video_defaults;
  474. $info['tags']['video:director'] = array(
  475. 'label' => t('Director(s)'),
  476. 'description' => t('Links to the Facebook profiles for director(s) that worked on the video.'),
  477. 'weight' => ++$weight,
  478. ) + $og_defaults + $video_defaults;
  479. $info['tags']['video:writer'] = array(
  480. 'label' => t('Scriptwriter(s)'),
  481. 'description' => t('Links to the Facebook profiles for scriptwriter(s) for the video.'),
  482. 'description' => t("Scriptwriters from the video."),
  483. 'multiple' => TRUE,
  484. 'weight' => ++$weight,
  485. ) + $og_defaults + $video_defaults;
  486. $info['tags']['video:duration'] = array(
  487. 'label' => t('Video duration (seconds)'),
  488. 'description' => t('The length of the video in seconds'),
  489. 'weight' => ++$weight,
  490. ) + $og_defaults + $video_defaults;
  491. $info['tags']['video:release_date'] = array(
  492. 'label' => t('Release date'),
  493. 'description' => t('The date the video was released.'),
  494. 'weight' => ++$weight,
  495. ) + $og_defaults + $video_defaults;
  496. $info['tags']['video:tag'] = array(
  497. 'label' => t('Tag'),
  498. 'description' => t('Tag words associated with this video.'),
  499. 'multiple' => TRUE,
  500. 'weight' => ++$weight,
  501. ) + $og_defaults + $video_defaults;
  502. $info['tags']['video:series'] = array(
  503. 'label' => t('Series'),
  504. 'description' => t('The TV show this series belongs to.'),
  505. 'weight' => ++$weight,
  506. 'dependencies' => array(
  507. array(
  508. 'dependency' => 'og:type',
  509. 'attribute' => 'value',
  510. 'condition' => 'value',
  511. 'value' => 'video.episode',
  512. ),
  513. ),
  514. ) + $og_defaults + $video_defaults;
  515. return $info;
  516. }
  517. function _metatag_opengraph_type_options() {
  518. $options = array(
  519. t('Activities') => array(
  520. 'activity' => t('Activity'),
  521. 'sport' => t('Sport'),
  522. ),
  523. t('Businesses') => array(
  524. 'bar' => t('Bar', array('context' => 'an establishment')),
  525. 'company' => t('Company'),
  526. 'cafe' => t('Cafe'),
  527. 'hotel' => t('Hotel'),
  528. 'restaurant' => t('Restaurant'),
  529. ),
  530. t('Groups') => array(
  531. 'cause' => t('Cause'),
  532. 'sports_league' => t('Sports league'),
  533. 'sports_team' => t('Sports team'),
  534. ),
  535. t('Organizations') => array(
  536. 'band' => t('Band'),
  537. 'government' => t('Government'),
  538. 'non_profit' => t('Non-profit'),
  539. 'school' => t('School'),
  540. 'university' => t('University'),
  541. ),
  542. t('People') => array(
  543. 'actor' => t('Actor'),
  544. 'athlete' => t('Athlete'),
  545. 'author' => t('Author'),
  546. 'director' => t('Director'),
  547. 'musician' => t('Musician'),
  548. 'politician' => t('Politician'),
  549. 'profile' => t('Profile'),
  550. 'public_figure' => t('Public figure'),
  551. ),
  552. t('Places') => array(
  553. 'city' => t('City'),
  554. 'country' => t('Country'),
  555. 'landmark' => t('Landmark'),
  556. 'state_province' => t('State or province'),
  557. ),
  558. t('Products and Entertainment') => array(
  559. 'album' => t('Album'),
  560. 'book' => t('Book'),
  561. 'drink' => t('Drink'),
  562. 'food' => t('Food'),
  563. 'game' => t('Game'),
  564. 'product' => t('Product'),
  565. 'song' => t('Song'),
  566. 'video.movie' => t('Movie'),
  567. 'video.tv_show' => t('TV show'),
  568. 'video.episode' => t('TV show episode'),
  569. 'video.other' => t('Miscellaneous video'),
  570. ),
  571. t('Websites') => array(
  572. 'blog' => t('Blog'),
  573. 'website' => t('Website'),
  574. 'article' => t('Article'),
  575. ),
  576. );
  577. return $options;
  578. }